← Home

Code

The lifeblood of development

There are many bad and good ways to write code. We aim for the latter.

Your Editor

Use whatever you want, as long as it can follow these guidelines and linting rules, it’s fine. You may be gently teased if you use something too esoteric though.

Git

This should come as no surprise, but git is vital to our workflow. On occasion we’ll use other SCMs, but git is used in 99% of the projects. Most of the time this is managed through services such as GitHub, GitLab, or Bitbucket.

Depending on the needs of the project, repositories may be “owned” by us or the client. For certain engagements, such as project-based work, it makes sense for the repos to be in our organization, with changes pushed over to a client at specific intervals. Others, such as retainer-based work, benefit more from working in the cleint’s organization.

GitHub & GitLab

GitHub has the best combination of features and usability, and is our primary git platform, though there are caveats.

GitHub changed their business model a little while ago. Organizations used to pay by the repository used, and the new model is to pay by the user, regardless of if that user is a full-fledged member or an “outside collaborator” on a single repo. If you create a lot of repositories in your organization and have only a few members, this plan is attractive, but that’s usually the opposite of how our teams are set up. This means the cost of GitHub can quickly cross over $100/month, which is a little silly for a startup. It also introduces friction when deciding to add a Project Manager, Account Manager, or Beta Tester to the repository. $9/month is not a lot of money, but it still requires those conversations to take place, which though small, is still an interruption in work. We don’t want to be in a place where someone even thinks of sharing their account with another person.

GitLab is a common suggestion when considering Git providers. It isn’t quite as user-friendly as GitHub, but for many use cases is free. In fact, we keep archived projects in there already. GitLab does have some features that GitHub does not as well, such as Continuous Integration pipelines that are worth digging into.

However, GitHub has been focusing on improving their own tools. The Project boards in particular are incredibly effective at tracking how work gets done. GitLab’s offering in this space isn’t quite as compelling.

These days we have a luxury of choices when picking a git provider. The team is empowered to pick whichever one they feel is best for the project. GitHub is still the preferred provider, but others may be considered as well.

Git Workflow

For reading through how to properly work in git as a team, read this document.

Other Git Philosophies

Code Review

Code reviews are necessary for quality. Each Pull Request should be reviewed by someone. A proper code review can take time, and therefore work best when the PR in question isn’t too long.

The reviewer should go through the code and ask the following questions:

In text the subtleties of spoken language can be misinterpreted, especially if the messages are terse. Let’s be careful about what we say when talking about code because it is easy to fall into a trap and take critical feedback personally.

As a reviewer:

As a reviewee:

Everyone:

Above all, remember that the goal should always be to ship quality code.

It should be noted that in a codebase where things like PCI or HIPAA compliance are necessary, additional requirements must be met, but that can be discussed elsewhere.