hin

Dotfile manager.

hin [OPTIONS] COMMAND [ARGS]...

Options

-h, --help

Show this message and exit.

-v, --version

Show the version and exit.

add

Add new FILE to version control.

If the file is a symlink not related to the dotfile repo then the source of the symlink will be added. The original path will be symlinked to the versioned file.

If the source file is a child of an already added directory it will be added as part of the directory. If the source file is a child of a directory that has not been added it will be installed individually, with the parents recreated, if they do not already exist.

If the source file is a directory then only the directory will be added, unless there are child files that have already been added, in which case they will be unlinked and added to version control under the source.

Changes will be committed.

param config:

Config object.

param out:

Console object.

param file:

Dotfile to add.

return:

Git commit message.

hin add [OPTIONS] FILE

Options

-h, --help

Show this message and exit.

Arguments

FILE

Required argument

clone

Clone a dotfile repository from a URL.

param out:

Console object.

param url:

Remote URL.

param branch:

Branch to clone.

hin clone [OPTIONS] URL

Options

-b, --branch <branch>

Branch to clone (default: master).

-h, --help

Show this message and exit.

Arguments

URL

Required argument

commit

Commit changes to FILE.

Restore item chosen to commit as repository decorator stashes, and then commits changes, made within wrapped function before popping the stash.

param config:

Dotfiles ini.

param out:

Console object.

param file:

Path to check status of.

param repo:

Git repository type.

return:

Git commit message.

hin commit [OPTIONS] FILE

Options

-h, --help

Show this message and exit.

Arguments

FILE

Required argument

install

Install a dotfile repository.

Repository needs to contain a dotfiles.ini file consisting of symlink to dotfile key-value pairs. The config will be parsed and all checked in files symlinked, relative to the home directory.

Any files that share a name with a versioned file will be backed up and timestamped with the time of the installation.

Any dangling symlinks that exist are removed if they share a name with a versioned dotfile.

hin install [OPTIONS]

Options

-h, --help

Show this message and exit.

Create a new LINK from TARGET.

Create a symlink to an existing linked dotfile, reproducible with a dotfile installation. This is useful for shared configs.

This will fail if the target is not a dotfile symlink or a child of a dotfile symlink.

The target needs to be a link to a checked in file or dir, or a versioned descendant of a linked dir. Any other files or dirs cannot be installed, and the state reproduced, on a clean system.

Changes will be committed.

param config:

Dotfiles config.

param out:

Console object.

param link:

Source of symlink.

param target:

Destination of symlink.

return:

Git commit message.

hin link [OPTIONS] LINK TARGET

Options

Show this message and exit.

Arguments

Required argument

Required argument

list

List all versioned dotfiles.

param config:

Dotfiles config.

param out:

Console object.

hin list [OPTIONS]

Options

-h, --help

Show this message and exit.

push

Push changes to remote.

param out:

Console object.

param remote:

Remote URL.

param repo:

Git repository type.

hin push [OPTIONS]

Options

-h, --help

Show this message and exit.

-r, --remote <remote>

set remote upstream

remove

Remove FILE from version control.

All links that point to the file, and any links to those links, will be removed.

If the dotfile is not a link to another dotfile then the checked in file or directory will be moved back to its original location in its place.

Changes will be committed.

param config:

Dotfiles ini.

param out:

Console object.

param file:

Path to dotfile.

return:

Git commit message.

hin remove [OPTIONS] FILE

Options

-h, --help

Show this message and exit.

Arguments

FILE

Required argument

status

Check version status.

Restore item chosen to check status for as repository decorator isolates user made changes from dotfile manager changes.

param config:

Dotfiles ini.

param out:

Console object.

param file:

Path to check status of.

param repo:

Git repository type.

hin status [OPTIONS]

Options

-h, --help

Show this message and exit.

-f, --file <file>

specific dotfile to check

undo

Revert previous commit and actions.

param config:

Config object.

param hist:

Hist json.

param out:

Console object.

param repo:

Git repository type.

return:

Git commit message.

hin undo [OPTIONS]

Options

-h, --help

Show this message and exit.

uninstall

Uninstall a dotfile repository.

This will remove all symlinks pointing to the dotfile repository.

hin uninstall [OPTIONS]

Options

-h, --help

Show this message and exit.