Skip to content
Permalink
Browse files
Merge branch 'master' into iss005/prevent-merging-to-master-branch
  • Loading branch information
aa7401 committed Nov 24, 2019
2 parents 85ed47f + 3e6c77a commit f1e2743bd80701762d36b7d59f55e3a9f14a06fb
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 5 deletions.
@@ -4,4 +4,4 @@ set -e # using the options command to abort script at first error
echo
echo "POST-COMMIT"
# ./node_modules/.bin/markdownlint --ignore node_modules .
echo
echo
@@ -5,7 +5,6 @@ echo
echo "PRE-COMMIT"

EMAIL=$(git config user.email)
echo $EMAIL

# make sure the user has registered a valid university email address
if [[ $EMAIL != *"@coventry.ac.uk" ]]; then
@@ -57,3 +56,5 @@ fi
# fi

./node_modules/.bin/eslint .

echo " commit successful..."
@@ -37,13 +37,16 @@ Start working on the assignment. Remember to install all the dependencies listed

You should not be committing directly to the **master** branch, instead each task or activity you complete should be in its own _feature branch_. You should following the following steps:

1. Log onto GitHub and add an issue to the _issue tracker_, this is your _todo_list.
1. Log onto GitHub and add an issue to the _issue tracker_, this is your _todo_ list.
2. Create a local feature branch making sure that the name of the branch includes both the issue _number_ and _title_ (in lower case).
1. For example: `git checkout -b iss023/fix-login-bug`.
2. You can see a list of all the local branches using `git branch`.
3. When the task is complete and all the tests pass, push the feature branch to GitHub.
3. As you work on the issue make your local commits by:
1. staging the files with `git add --all`.
2. committing with the `no-ff` flag, eg. `git commit --no-ff -m 'detailed commit message here'`.
4. When the task is complete and all the tests pass, push the feature branch to GitHub.
1. For example `git push origin iss023/fix-login-bug` would push the branch named above.
2. Switch back to the _master_ branch with `git checkout master`.
4. Back on GitHub raise a **Pull Request** that merges this feature branch to the _master_ branch.
5. Back on GitHub raise a **Pull Request** that merges this feature branch to the _master_ branch.
5. If there are no issues you can then merge the branch using the button in the _Pull Request_ interface.
6. Pull the latest version of the master branch code using `git pull origin master`.

0 comments on commit f1e2743

Please sign in to comment.