Cigtrack Day #1: Setting up Camp

Starting a new software project in somewhat professional ways is not hard nowadays. Before you write all your cool code, you should probably think of some structure or software architecture you want to use. Very popular and in the past very useful to me has been: MVC.

Actually I have been cheating a little, because I’ve been cooking my idea in my head for a while already. If I had not done that, I would need to do some research towards target group, monetization strategies and also if any laws would require a certain security standard or just plainly prevent me from doing what I do.

Setting up Your Git Repository

After creating the first couple of files and making sure things work, I generally like to set up a git repository, so my code is safe on my remote server, even if the city I live in gets nuked or something.

Also I can precisely view what I’ve written each day, which makes estimating how long things might take much easier, having this in retrospect.

It probably doesn’t come as a surprise that I’m using my own installation of the GitLab server to handle my repositories and sort them into groups. This is especially useful if you have multiple repositories per project.

Setting up Dependency Management with bower and npm

For creating my App I will need two types of dependency management. One for the frontend/app part and one for the server side. Npm is an obvious choice for node.js projects and for the frontend I chose bower, because it basically works the same way, just with another default registry.

This comes in very handy when you work on multiple physical machines, let’s say one at work and another one at home, because you don’t have to move in your dependencies manually or pollute your git repository with for example a large third party file like jQuery.

With bower you store your dependencies inside the small bower.json and you can install the required libraries with bower install.

Planning your Tasks

To start your development, you basically line up a list of features your have to implement and pick one that doesn’t have any dependencies to be fulfilled before itself.

Let’s say you have the following things you need to get done:

  1. frontend API-caching (requires 2.)
  2. write API

Obviously you would want to start writing your API, since it’s going go be your API that you need to cache data from. Congratulations, you’ve found your first task!

Writing READMEs

I’ve made it a habit to add a in every Git repository I start, with something like the following headlines:

  • Usage
  • Dependencies
  • File Structure

This makes sure everyone knows how to install and use it and if they want to contribute, where to stick their files.

Leave a Reply

Your email address will not be published. Required fields are marked *