Multiple Machine Workflow

If I want to work on a site from more than one machine, what should my .gitignore look like? Or should I just check the whole shebang in?

@KevDog I think this depends on the other tools you are using as well. One of the best features of Hugo is that it installs as a single binary. If you’re using other build tools for Assets (eg, gulp or grunt), I’d imagine you would do a typical node_modules in your gitignore and just manage dependencies via package.json like you would any other project to prevent too much bloat in your repo.

You would almost always also have public/ in ignore.

Ah good point, or whatever you choose for your publishdir in your config file.

My .gitignore looks like:

While adding themes use git submodule add like below instead of just cloning the repo in the right right directory.

git submodule add themes/base16
1 Like

Thanks all, great help here. Much appreciated.