This repository is used like a template by dotfiles project. If you want to use this repository to extend your dotfiles
configuration you have two options:
- Using
dotfiles
command to initialize your plugin executing the following command replacing "<PLUGIN_NAME>" with the desired name:
dotfiles create-plugin <PLUGIN_NAME>
For example:
dotfiles create-plugin my-awesome-plugin
- Fork this repository to your GitHub profile and commit your changes.
The file's structure is important to handle the configuration, letting you separate each tool's configuration in different folders, allowing you to isolate each configuration.
The following structure is created by this template:
├─ bin # This folder contains custom binaries.
├─ git # This folder contains your git config.
├─ os # This folder contains your specific config for your Operating System.
├─ zsh # This folder contains your config scripts for your terminal.
Relax, you have an explanation file for each folder:
These folders are what we call topics. The structure of each topic is as follows:
- topic/bin/: Anything inside the bin directory will be added to the $PATH.
- topic/install.sh: Any file named
install.sh
will be executed automatically when plugins are being installed. - topic/<FILENAME | DIRNAME>.symlink: Any file that ends with
*.symlink
will be added as a symlink to your $HOME.
If you wanted to create a new topic you can create a directory <TOPIC>
in the root of the plugin. Inside you can do some or all of the following:
- Create an
install.sh
file that contains the installation process (only required for tools that are not present in Homebrew, if they are it's easier to install by updating theBrewfile
) - Create an
alias.zsh
file that contains the commands you want - Create a file
functions.zsh
to create utility functions for that topic - Create a directory ending with
.symlink
that will symlink all the files inside that directory to your home directory
If you have your plugin configured you would need to push it to your favorite repository manager. Then you can add it to dotfiles
in your computer executing:
dotfiles install-plugin <GIT_REPOSITORY_URL>
or
dotfiles install-plugin -- <GIT_REPOSITORY_URL>
For example:
dotfiles install-plugin git@github.com:autentia/my-awesome-plugin-template.git
Plugins are linked to git repository, so you can commit your changes to your plugin repository and then execute the following command to update it:
dotfiles update-plugin <PLUGIN_NAME>
For example:
dotfiles update-plugin my-awesome-plugin
If you have a plugin that you no longer want to use, you can remove it executing:
dotfiles uninstall-plugin <PLUGIN_NAME>
For example:
dotfiles uninstall-plugin my-awesome-plugin
- Change ctrl with mayusc