I'm currently traveling and working off my other laptop. My main computer is now a desktop machine.
My question is: What do you do to share your development configuration between devices? Specifically both of my computers are macs. I'm interested in specific technology I can be using to help with this, in addition to general discussion around this topic.
Thanks!
Oldest comments (25)
In a way, this is a follow up to this post:
I'm planning to ditch my MacBook and move away from laptop computing
Ben Halpern
Things have been going well, but still have some things to work out, clearly.
Git is the answer. This allow you to store config/dotfiles in the cloud and version control it. I've follow this guide many moons ago and have been seamlessly transferring config back and forth. The downside is this isn't automatic.
my dotfiles
Was going to say the same. git is a pretty good solution.
Nice. Thanks Mac!
It may not be a shiny new fancy solution, but if you can access your other host directly,
rsyncis great for this. Ignore identical files, set things to specifically exclude, and it doesn't involve an intermediate stage, so you're not doing something like committing secrets into a repo.About using
rsyncI'm using VSCode with the Settings Sync extension. This allows you to create a private Gist to sync your settings. I have found this to work pretty well.
I recommend having an installable dotfiles repo (mine is github.com/markoa/dotfiles).
By linking your local files to the files in the repo, you almost completely eliminate the effort of keeping it up to date.
The first part is good. But it's the second that made me realize this is the best option!
This! And add a Cron that runs a script that updates everything from git, including itself and the Cron, so you get the changes with 0 effort
Great tip!
I use Sync on VSCode and for all products JetBrains, I export all configs and sync on my Cloud Jetbrains.
Check this out: github.com/technicalpickles/homesick
The other day I randomly ended up in this homesick tool and it reactivated my intention of having a dotfiles repository.
I am a huge fan of using Docker for any thing I need for development...
When I say anything I include text editors like Sublime or Visual Studio Code. I also have dockerized Browsers, Postman, MySQL workbench, Android Studio 3, just to name a few.
So my strategy is to build docker stacks for all the programming languages I work with and then I add and extend them in each project I work.
My computers are not MAC but others using vanilla Ubuntu installations where I install docker, docker compose, git and almost nothing else more, thus when I need to upgrade OS is dead simple. Maybe you can use more Docker in your MAC???
In each computer I need to work I just download a github repo that install all this in a bin folder to be accessible in my path, as any other linux tool... The repo is still a work in progress, but you can get an idea of it here and you can see all my current docker images here and here and finally the Elixir Docker Stack.
A dotfiles repo for sure! Many tools also let you export your configuration profile as JSON or some other format, conducive to being committed as well. Not sure if you can point to a version-controlled file or if you have to re-import when there are changes, but better than tweaking tens of checkboxes and values in a GUI! I haven't done this yet but I will be mad I didn't the next time I set up a new machine 😄
I haven't applied this in the context of sharing IDE config between devices, but...
I have 2 git repos that correspond to physical devices (my working laptop & my home server). I use each git repo as the source of truth for configs (typically via
ln -s) and scripts for both provision & maintenance.I did this primarily for disaster recovery but it's easily repurposed for sharing