Closed itsdarrylnorris closed 9 years ago
What is your probleem here? maybe we can help out
@horvan thank you to jumping it. The reason I open this issue was because someone was complaining the Drush was not installed properly.
So, during the installation process we would like to used some of the new packages that have been install. If there is an error we would know that is not been installed properly. I do not know if that makes sense. So write a script that used some of the packages just to make sure is installed properly.
If you like to speed up development just get in touch with me I have a similar project that's far more advanced than yours here on GitHub perhaps we should share some Ideas and code.
If you like to make absolutely sure to install the latest version form GitHub for the current user use this:
#!/bin/bash
#before you are able to install composer php has to be installed so place this code after your lamp installation
# file has to be run with sudo
#functions to install composer and it's dependencies globaly.
getcomposer(){
# installing prerequirements
apt-get -y -qq install git git-core curl
# Composer Global installation
curl -sS https://getcomposer.org/installer | php > /dev/null 2>&1
mv composer.phar /usr/local/bin/composer > /dev/null 2>&1
sed -i '1i export PATH="~/.composer/vendor/bin:$PATH"' ~/.bashrc > /dev/null 2>&1
source "$HOME"/.bashrc
}
#get drush via composer
getdrush(){
composer global require drush/drush:dev-master
#create symlink to make drush work when entering drush in terminal
if [ -f /usr/bin/drush ]; then
rm "/usr/bin/drush";
cd ~/.composer/vendor/drush/drush
ln -s $PWD/drush /usr/bin/drush
else
cd ~/.composer/vendor/drush/drush
ln -s $PWD/drush /usr/bin/drush
fi
}
#execute functions from above
getcomposer
getdrush
The result that is expected is
$ Drush Version : 7.0-dev
We already have Drush working (I forgot to mention). For this reason I'm going to close this issue.
Problem:
Installation problems with composer and other packages.
Solution
We need to created a script that will validate some of the packages install.