config | ||
metadata | ||
scripts | ||
LICENSE | ||
manage.sh | ||
README.md |
jstm's dotfiles
This repository contains jeremystartm's dotfiles (except KDE Plasma configuration files).
Index
Installing
Installing these dotfiles is easy. You just need to execute these commands:
git clone https://git.staropensource.de/JeremyStarTM/dotfiles.git "${HOME}/.dotfiles"
${HOME}/.dotfiles/manage.sh link
That should do it. Please note though, that you may get errors such as:
ln: failed to create symbolic link '<your home>/.bashrc': File exists
These indicate that some files could not be automatically linked, most likely because you've created them yourself. To fix this and remove the conflicting files, execute:
${HOME}/.dotfiles/manage.sh unlink
${HOME}/.dotfiles/manage.sh link
Updating
To update all dotfiles, invoke:
${HOME}/.dotfiles/manage.sh update
The update process is in most cases fully automatic and usually does not require any input.
Uninstalling
Execute these commands to uninstall this dotfiles repository:
${HOME}/.dotfiles/manage.sh unlink
rm -rf "${HOME}/.dotfiles"
You may need to recreate some dotfiles yourself however due to them being automatically removed by the management script.
Forking / Contributing
In case you want to contribute to or fork this repository, here are some things you may need to know:
How to properly version
This repository contains a file located at
metadata/version
, which contains the current
dotfiles version.
It helps the manage.sh
script during the
update process and allows it to potentially
migrate files or perform other changes.
Do not increase the version number on every commit you make. Instead, only bump it if you've made incompatible changes and need to update external files or perform/handle other shenanigans.
In case you've bumped the version and want
to slot in commands during the post-upgrade
process, append this to the if checks in the
post-update
function in manage.sh
:
# ... other version checks
# Replace 41 with your old version
if (( "${OLD_VERSION}" < 41 )); then
echo ":: Updating to version 41"
# Your migration code here
fi
# ... other version checks
Adding files to link
To tell the manage.sh
script to link
something, you need to add an entry to
the metadata/links
file.
To do this, append this to the file:
${DOTFILES_HOME}/<source path> -> ${HOME}/<destination path>
Now, replace <source path>
with the
relative path of the file you want to
link in the repository. After that,
replace <destination path>
with the
relative path where the link should be
created at in the user's home directory.
After that, run this to relink all files:
${HOME}/.dotfiles/manage.sh unlink
${HOME}/.dotfiles/manage.sh link