Skip to content

Instantly share code, notes, and snippets.

@stormsson
Created November 10, 2015 16:36
Show Gist options
  • Save stormsson/5b854ee36a615dfa0570 to your computer and use it in GitHub Desktop.
Save stormsson/5b854ee36a615dfa0570 to your computer and use it in GitHub Desktop.
protract folder
#!/bin/bash
function createStructure {
if [ -f default_conf.js ]; then
echo -ne 'Structure already found, aborting'
else
echo 'Structure not found, creating...'
wget https://github.com/stormsson/protractor_scaffolding/archive/master.zip &&
unzip master &&
rm master.zip &&
mv protractor_scaffolding-master/* . &&
rm -rf protractor_scaffolding-master
# get chromedriver http://chromedriver.storage.googleapis.com/index.html?path=2.20/
wget http://chromedriver.storage.googleapis.com/2.20/chromedriver_mac32.zip &&
unzip chromedriver_mac32.zip &&
rm chromedriver_mac32.zip
# get selenium standalone http://www.seleniumhq.org/download/
wget http://selenium-release.storage.googleapis.com/2.48/selenium-server-standalone-2.48.2.jar
fi
}
# protract the directory
function protract {
if [ $1 ]; then
createStructure
git clone $1 src
else
createStructure
fi
}
# fire protract with parameters
protract $@
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment