Skip to content

Instantly share code, notes, and snippets.

@ansermino
Last active June 19, 2018 03:29
Show Gist options
  • Save ansermino/3d83e49a4adf9c74b6653f65ae9716c3 to your computer and use it in GitHub Desktop.
Save ansermino/3d83e49a4adf9c74b6653f65ae9716c3 to your computer and use it in GitHub Desktop.

Use Linux (preferably Ubuntu 16.04 LTS) or Mac for Development

Github

Security

SSH

In order for your connection to be secure with any Git client you must use the SSH protocol.

2FA required

Two factor authentication allows you to use your mobile device as a secondary source of validation to ensure your account is kept secure.

Ensure gitignore contains node_modules, .idea, .vscode & other temp directories

Build files, IDE configurations and other user specific files should be kept out of Git repositories. You can ensure this by properly configuing a .gitignore file.

Branches

  • Fork the repo and create your own branch for public repos
  • Use descriptive branch names (Example: name/route-bug-fix)
  • Use a new branch per feature/issue
  • git push at the end of every working day regardless of completion level
  • Report issues in github
  • Make a PR when you finish a task

Commits

  • Use appropriate commit messages.
# Good. Describes what you accomplished 
git commit -m ‘Added user auth test & route test’

# Meh. Git should demonstrate specific changes for you, rather aim for something that broadly defines what you did
git commit -m 'Changed line 1 to print('Hello, world')'

# Bad. Too broad, required a fellow dev to dig in to understand what changes were made
git commit -m ‘added 2 tests working’
  • If the commit closes an issue reference it.
# Example 
git commit -m ‘Closes #4, Fix loading screen bug’

Code comments

Write code comments where necessary:

  • Complicated math
  • Above complicated functions
  • TODO’s; example: //TODO: fix buffer overflow issue
  • Above every function identifying input, output and a brief description containing any complex implementation details

Pull Requests

  • Small PR’s are good PR’s.
  • Add a description to your PR that explains what the PR does.
  • An approval will be needed, if there are issues continue to commit the fixes to the branch, they will be added to the PR automatically.
  • A closed PR should close the branch as well, please use a new branch for every new feature/issue.

When in doubt, ask those around you or reach out on Slack =D

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment