I did use below to install composer globally:
$ curl -sS https://getcomposer.org/installer | php
$ sudo mv composer.phar /usr/local/bin/composer
and it seems it is done. when I go under the folder where my composer.json is present to use:
$ composer update
or even if I want to do another action that has nothing to do with json like self-update I get:
[RuntimeException]
The HOME or COMPOSER_HOME environment variable must be set for composer to run correctly
Thanks. I use a ionCubed script and it denies auto_prepend_file. Is there any other trick to solve this? Otherwise I have to delete the global composer, how to delete it? Just deleting from /etc/lib/bin/composer is enough? Or do I need to clean something from elsewhere too as I installed it with sudo?
Instead of auto_prepend a file with putenv, can I set the environment in php.ini itself as I said the problem above? If yes how and if no how to delete it as I asked above?