/.dotfiles

My dotfiles

Primary LanguageVim ScriptMIT LicenseMIT

.dotfiles

Just some of my dotfiles. restore.sh is a script to create symbolic links saving time from moving files from here to where they belong. These dotfiles include:

Obligatory screenshot:

screenshot

Install

Clone the repository and distribute the files using restore.sh:

git clone https://github.com/z5210220/.dotfiles ~/.dotfiles
cd ~/.dotfiles
sh restore.sh

restore.sh usage

restore.sh is used to create symbolic links from files around the system to the backed up files. This can be used by running the following commands:

cd ~/.dotfiles
sh restore.sh

restore.sh will restore each file in the dotfiles.json file.

dotfiles.json

This is a data base of all files. Each file needs three fields:

  • The name (this is the key in the dictionary).
  • The file (the file to store)
  • The path (directory containing this file)

Inside of files/ is a directory for each name which contains the respective file.

Example

If dotfiles.json looked like:

{
    "bashrc" : {
        "file" : ".bashrc",
        "path" : "~"
    }
}

The file is stored in files/bashrc/.bashrc and the symbolic link will be created in ~/.bashrc.