This repository has been archived by the owner on Aug 18, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add phpcs & setup Drupal sniff file (#24)
* Add phpcs & setup Drupal sniff file * Resolves Islandora/documentation#563 * oof. * Actually get it to work for ubuntu user
- Loading branch information
Showing
3 changed files
with
18 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,21 @@ | ||
#!/bin/bash | ||
echo "Installing Composer" | ||
|
||
HOME_DIR=$1 | ||
|
||
if [ -f "$HOME_DIR/islandora/configs/variables" ]; then | ||
. "$HOME_DIR"/islandora/configs/variables | ||
fi | ||
|
||
cd /tmp | ||
curl -sS https://getcomposer.org/installer | php | ||
php composer.phar install --no-progress | ||
mv composer.phar /usr/local/bin/composer | ||
sudo mv composer.phar /usr/local/bin/composer | ||
|
||
echo "Installing phpcs" | ||
cd $HOME | ||
composer global require drupal/coder | ||
composer global update drupal/coder --prefer-source | ||
export PATH="$PATH:$HOME/.config/composer/vendor/bin" | ||
echo 'export PATH="$PATH:$HOME/.config/composer/vendor/bin"' >> .bashrc | ||
phpcs --config-set installed_paths $HOME/.config/composer/vendor/drupal/coder/coder_sniffer |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters