WeRKD
Where creative folks come to shmooze
-
Install git http://git-scm.com/download/mac
-
Install ruby manager
-
Create ssh keys
ssh-keygen -
add ssh key to bitbucket
cd ~/wsgit clone git@bitbucket.org:katzmopolitan/werkd.git` -
Install command line tools
-
Install ruby
rvm install ruby 2.0.0or
rbenv install 2.0.0 -
Install homebrew
-
Add this to /etc/hosts
127.0.0.1 localhost -
(optional) Git GUI http://www.sourcetreeapp.com/download/
-
Set up heroku environment
-
Set up postgres
brew install postgrescreateuser werkd_dev --createdbcreateuser werkd_test --createdb -
Install redis
brew install redis -
Migrate databases
rake db:migrateRAILS_ENV=test rake db:migrate
https://www.codeship.io/projects/4271
-
Install spring
gem install spring -
Install bundler
gem install bundler -
Install gems
bundle install -
Install phontom.js (for JS testing)
brew install phantomjs -
Run tests
spring cucumber featuresspring rspec specbundle exec guard-jasmine --server-timeout=90 -t 30000
You can access your server from the outside world:
- gem install proxylocal
- Add heroku remote repostory
git remote add heroku git@heroku.com:werkd.git
- proxylocal 5000 --host `scutil --get LocalHostName | perl -ne 'print $_ if s/(.*)/\L$1/'`
-
Open terminal.app
-
cd ws/werkd
-
Pull the latest code from git repository
git pull -
Make sure that all libraries are installed
bundle install -
Migrate database changes
rake db:migrate -
Stop server if already running
open window where foreman is runningCntrl-C -
Start server
foreman start -
Open local version
http://localhost:5000 -
Write your code and do your magic!
-
Push your changes back to the repository
git add .git commit -m "brief message about what changes your made"git push- If you get a message
! [rejected] HEAD -> master (non-fast-forward)That means that someone already made changes upstream (bitbucket) and you need to pull then withgit pull - If there are no conflicts, do
git pushagain
- If you get a message
-
Follow instructions to bring up the server
-
Go to
http://localhost:5000/email_preview
git rm [path to file]
git checkout [path to file]
Install sublime
- If you have sublime, createa link
ln -s /Applications/Sublime\ Text\ 2.app/Contents/SharedSupport/bin/subl /usr/local/bin/sublime
- Open ~/.bash_profile and add this line
export EDITOR=/usr/local/bin/sublime
- Close terminal window and restart it