composer update returned with error code 1 - installation

on composer update i got this error
Script [ ! -f vendor/autoload.php ] || $PHP_BINARY bin/console system:update:prepare handling the pre-update-cmd event returned with error code 1
It says me, that the command $PHP_BINARY written wrong or couldnt find.
this scripts are added:
scripts:
pre-install-cmd
pre-update-cmd
post-install-cmd
post-update-c
My php-version
8.1.13
System:
shopware 6
if i use --no-scripts , then the composer update is succesfully. But
I don't know what the consequences are.

Related

How to remove ckeditor package (error: Class 'Ckeditor\CkeditorServiceProvider' not found)?

I followed the steps mentioned here:
How to remove a package from Laravel using composer?
including the step: Remove Service Provider from "app/config/app.php" (reference in "providers" array)
However, since I got an error:
In ProviderRepository.php line 208:
Class 'Ckeditor\CkeditorServiceProvider' not found
Script #php artisan package:discover handling the post-autoload-dump event returned with error code 1
The app is down and I cannot do any operation in terminal. How to get rid of the reference to this class?
Then run these commands.
php artisan cache:clear
composer dump-autoload -o
If an error occurs while clearing cache, then delete cache files under bootstrap/cache manually.

anyone got an error i get while installing teepluss/theme in laravel

I wanted to install teepluss/theme so I added it to my composer.json
but now I get this error:
[Symfony\Component\Debug\Exception\FatalThrowableError]
Class 'SuperClosure\Serializer' not found
I was capable to solve the first error by adding >"jeremeamia/superclosure": "^2.0"
but now when I add >Teepluss\Theme\ThemeServiceProvider::class, in app.php providers I get a new error :
> [ErrorException] Illegal offset type in unset
here's what i got in the script in composer.json
If you already run composer update, you can try run this script
php artisan config:cache
and
php artisan cache:clear.It can help you resolve that problem

Script php artisan optimize handling the post-install-cmd event returned with error code 255

After clone the git repo, install composer and Laravel , this error will come out. Anyone can solve this error?
When I run laravel new, I get this error:
Crafting application...
Loading composer repositories with package information
Installing dependencies (including require-dev) from lock file
Nothing to install or update
Generating autoload files
> php -r "file_exists('.env') || copy('.env.example', '.env');"
> Illuminate\Foundation\ComposerScripts::postInstall
> php artisan optimize
Script php artisan optimize handling the post-install-cmd event returned with error code 255
Application ready! Build something amazing.
Which repo you cloned? if you want create a new laravel project, just try run laravel new projectName,
check the doc here

Fresh CentOS 7, first Laravel Installation.Composer install breaks

I am fallowing this tutorial:
http://linoxide.com/linux-how-to/install-laravel-php-centos-7-ubuntu-15-04/
And on step 5) when running composer install in the project directory it starts to do staff, as expected, until this happened:
Illuminate\Foundation\ComposerScripts::postInstall
> php artisan optimize
PHP Fatal error: Undefined constant 'Illuminate\Session\TokenMismatchException' in /var/www/laravel-develop/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 779
PHP Fatal error: Undefined constant 'Illuminate\Session\TokenMismatchException' in /var/www/laravel-develop/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 779
Script php artisan optimize handling the post-install-cmd event returned with error code 255
What is the problem?
Thanks, Aleks
start creating a project (after updating composer) instead of downloading the referenced file do the following
from your terminal type in cd /var/www/
then type composer create-project laravel/laravel laravel-develop
your composer should download the latest version of Laravel
try it this way feel free to ask any questions.
Good Luck

laravel 4 install issue when using composer install

When I run
composer.phar install
I get this error almost at the end of the installation, any ideas?
Loading composer repositories with package information
Installing dependencies (including require-dev) from lock file
Nothing to install or update
Generating autoload files
Warning: Unexpected character in input: '\' (ASCII=92) state=1 in /home/belendez/public_html/laravel/artisan on line 46
Parse error: syntax error, unexpected T_STRING in /home/belendez/public_html/laravel/artisan on line 46
Script php artisan optimize handling the post-install-cmd event returned with an error
I look into the suggested link and it appears that somehow in the middle of the installation it changes from 5.3 to 5.2! If I try to start installation using 5.2 it returns right a way: class 'Phar' not found. Any ideas?
It seems that issuing only a php command will pick up another version of the interpreter. Try to change all the references to php in your composer.phar file to the one you want actually to be executed (in your case it seems /opt/php53/bin/php).
You can confirm that by simply launching a php -v directly from the command line to see what version your server will pick up

Resources