Skip to content

Migrate from another tool

Moving to dotsync always takes the same three steps: make sure the real files are in place on one machine, dotsync add them there, then dotsync init every other machine. Use a new, empty repository for dotsync: its layout (manifest.json plus files/) is its own.

Your dotfiles are symlinks into a directory like ~/dotfiles. dotsync follows a symlinked target as long as the file it points to is inside your home directory, so you can start straight away. For a clean result that no longer depends on the old directory, replace the links with real files first:

  1. Turn each link into a regular file:

    Terminal window
    # Linux (GNU coreutils)
    for f in ~/.gitconfig ~/.zshrc; do cp --remove-destination "$(readlink -f "$f")" "$f"; done
    # macOS
    for f in ~/.gitconfig ~/.zshrc; do src=$(readlink "$f"); rm "$f"; cp "$src" "$f"; done

    For a linked directory, stow -D <package> removes the links; then copy the package’s files into place.

  2. dotsync init <new-url>, and dotsync add the real paths.

  3. On every other machine, run stow -D for the migrated packages, then dotsync init <new-url>.

After migrating, run dotsync status on each machine: every entry should be ok.