homeshick Command Examples in Mac

homeshick is a command line tool that allows you to synchronize your “dotfiles” (i.e. configuration files that are typically stored in your home directory and begin with a “.” like .bashrc) across multiple computers using Git. It’s a simple and powerful way to keep your personal configurations in version control and easily replicate them on other machines.

With homeshick, you can create a “castle” which is a collection of Git repositories that contain your dotfiles, and then clone those castles to different machines. Once you have your castles set up, you can use homeshick to easily make changes to your dotfiles on one machine, commit the changes, and then pull the changes down to all your other machines.

Here’s an example of how you might use homeshick:

  • Create a new castle: homeshick create dotfiles
  • Add your dotfiles to the castle: homeshick add ~/.bashrc ~/.vimrc
  • Commit and push the changes to the castle: homeshick commit -m “Initial commit”
  • Clone the castle on another machine: homeshick clone dotfiles
  • Make changes to your dotfiles on the first machine: vi ~/.bashrc
  • Commit and push the changes: homeshick commit -m “Added some cool new alias”
  • Pull the changes on the second machine: homeshick pull

homeshick also provides a set of commands to manage the castle, such as homeshick list to list all the castles, homeshick symlink to create symlinks to the dotfiles in the castles, homeshick cd to change directory into a castle and homeshick link to link a castle to the current home directory.

homeshick Command Examples

you may try installing the below package as per your choice of distribution:
1. Create a new castle:

# homeshick generate castle_name

2. Add a file to your castle:

# homeshick track castle_name path/to/file

3. Go to a castle:

# homeshick cd castle_name

4. Clone a castle:

# homeshick clone github_username/repository_name

5. Symlink all files from a castle:

# homeshick link castle_name
Related Post