Access
- In your web browser visit https://git.dcs.ucl.ac.uk/ and log in using your LDAP credentials
- Please update your profile https://git.dcs.ucl.ac.uk/profile adding your name
- Contact web-support@ucl.ac.uk to request access access to the repository
- Fork https://git.dcs.ucl.ac.uk/UCL-WAMS/skins
- Following on from "Developing locally" you need to clone your repo in a suitable location for your webserver e.g. htdocs for XAMPP on Windows, OSX and UNIX see referenced resources for "Developing locally"
- git clone https://git.dcs.ucl.ac.uk/{your-ucl-user-name}/skins.git
- git remote add upstream https://git.dcs.ucl.ac.uk/UCL-WAMS/skins.git
- note: if you have set up an ssh key including adding this to your git.dcs profile then the above commands will be in the format https://git.dcs.ucl.ac.uk/UCL-WAMS/skins.git instead of https://git.dcs.ucl.ac.uk/UCL-WAMS/skins.git
New project
Fetch / Checkout master / Merge skins repo - sync your local skins repo to the upstream skins repo
- git fetch upstream
- git checkout master
- git merge upstream/master
- Create folder from example 'Skeleton' folder - either using bash script themebuilder.sh (located in skins/UCLIndigoSkin - UNIX only) or manually (search & replace).
- Navigate to your new folder
- Install grunt libraries - npm install
- run grunt - grunt
- you are ready to start developing
New developing session on existing project
Fetch / Checkout master / Merge skins repo - sync your local skins repo to the upstream skins repo
- git fetch upstream
- git checkout master
- git merge upstream/master
- run grunt in the folder you are working in - grunt (if grunt not installed in this folder npm install)
- run grunt in your project
- you are ready to start developing
When developing
- Please aim to commit your changes and resync you repos as often as possible to minimise conflicts.
- Finish edits - so after testing
- Check what you have updated - git status, git diff or use GUI
- Stop grunt
- commit your changes to your local repo with descriptive message - git commit -m "What I have changed" or use GUI
- Fetch / Checkout master / Merge skins repo - sync your local skins repo to the upstream skins repo
Fix conflicts - if no conflicts skip this step
- fix src file conflicts (scss /src)
- run grunt
- Add the files you have fixed - git add filename
- commit your fixes - git commit -m "Fixed conflicts"
- git status
- Fetch / Checkout master / Merge skins repo - check you are now in sync
- Push your local repo to your origin - push
When you are ready to publish to upstream
- follow the 'When developing' steps so your origin repo is in sync with your local
- Create pull request to upstream repo (UCL-WAMS)
- Pull is accepted
- WAMS will FTP updates to server
Conflict tips
- only need to fix conflicts in source files (.scss and /src), grunt will fix conflicts in compiled files (css, /lib) - so always run grunt after fixing the source files
Resources for Git
- Lynda.com - GitHub for Web Designers