yadm-bootstrap
Initialize yadm repository and deploy configuration
TLDR
Execute bootstrap executable
SYNOPSIS
yadm bootstrap [repository_url]
PARAMETERS
repository_url (optional)
Specifies the URL of an existing Git repository to clone. If omitted, `yadm` will create a new bare repository.
DESCRIPTION
The `yadm-bootstrap` command is a crucial step in setting up yadm (Yet Another Dotfile Manager). It automates the process of initializing a yadm repository and managing existing dotfiles. The command typically performs the following actions:
1. Creates a bare Git repository (or clones an existing one).
2. Moves or symlinks existing dotfiles into the yadm repository.
3. Sets up the necessary configurations for yadm to track and manage your dotfiles effectively.
Essentially, `yadm-bootstrap` prepares your system to use yadm for version control and synchronization of your configuration files across multiple machines. It simplifies the initial setup by handling the often tedious task of moving existing dotfiles and configuring the repository, making it easier to adopt yadm for dotfile management. Without bootstrap, you would need to manually create the repository and move files, which is significantly more work. The command attempts to preserve your current workflow by using either moving or symlinking based on configuration.
CAVEATS
Ensure no untracked changes exist in dotfiles before bootstrapping to prevent data loss.
Backup existing dotfiles before bootstrapping, especially if unsure about its effect.
Existing `.git` directories are not automatically handled.
BEHAVIOR
The exact behavior can be customized via configuration.
The `yadm-bootstrap` command aims to be non-destructive by default. It can copy dotfiles into the yadm repo or keep symlinks to the current locations. See documentation for configuring this behaviour.
EXIT CODES
`yadm-bootstrap` returns 0 on success, and a non-zero value on failure. Possible errors are invalid parameters, insufficient permissions or issues when creating or cloning a repository.