Getting Started - AamAadmiParty/india-standalone-drupal GitHub Wiki
Assumptions
This document assumes that you are okay with the prerequisites listed below that and you work on using a *nix (linux) based system or a mac. (If you use windows, most of the instructions remain same, but you would be using your widows specific tools. Feel free to create a new wiki page for details windows based instructions and link it here.)
Prerequisites
- Familiarity with drupal development - http://drupal.org/
- Familiarity with git and github
- Drupal development environment setup on your local machine (lamp, drush, saas/compass etc)
Get the site setup on your local machine
- Fork this repository to create a copy in your github account - https://github.com/AamAadmiParty/india-standalone-drupal
git clone https://github.com/YOUR-GITHUB-ACCOUNT/india-standalone-drupalinside your webserver document root- make sure you are on the develop branch -
git branch -a>git checkout develop - create a new empty database on your local machine
- create settings.php file inside the sites/default folder of your drupal clone and add in the details to connect to the database
- Early contributors - Download the latest database dump from here ( with, user / password = congress / bjp ) and source it into your empty local database (hint: you can use
drush slq-clifor this. - Trusted contributors - You probably already have access to the development server as per the notes here so you can just do a
drush sql-syncbetween the development and the local machine. For this you would need to setup and aliases file as per the post here. Here is a sample file
- Early contributors - Download the latest database dump from here ( with, user / password = congress / bjp ) and source it into your empty local database (hint: you can use
- create a sites/default/files folder inside your local drupal clone, give it permissions such that your web server user can write to it, and get it populated with all the content
- Early contributors - Download the latest file dump from here ( with, user / password = congress / bjp )
- Trusted contributors - You can use the above method -- or -- use
drush rsync @remote_dev_alias:%files @local_alias:%files(but with the correct alias names)
drush cc all- Optional: Create a new virtualhost within your server for the site you have just setup. You might also create an entry in
/etc/hostsrecords. - update the admin user password to anything easy for you to use -
drush upwd admin --password=SOMETHING - Test that the site is working now on your local machine.
Making changes and releasing them to dev or prod
- create a new git branch from the tip of develop branch
git checkout develop+git pull+git checkout -b SOME_BRANCH - make the changes (adding new modules, theme, css, whatever)
- export as many changes from the drupal admin UI as you can using the features module
- commit all your changes often
- send in a pull request against this original repository - https://github.com/AamAadmiParty/india-standalone-drupal . Read more about it here - https://help.github.com/articles/creating-a-pull-request
- create a new issue or update an existing issue with details about your work **especially mentioning any changes in step 3 above that you could not export to features (since they need to be manually repeated on the dev and prod server)