mirror of
https://github.com/keanuplayz/dotfiles.git
synced 2024-08-15 02:33:12 +00:00
Compare commits
No commits in common. "e5d942e860c653ee44b473b4cd9552e7802b83c1" and "5e7350f793268064161f74a1ecbb4cb686e148e6" have entirely different histories.
e5d942e860
...
5e7350f793
3 changed files with 54 additions and 18 deletions
20
README.md
20
README.md
|
@ -1,19 +1,3 @@
|
||||||
# dotfiles
|
# .dotfiles
|
||||||
|
|
||||||
My dotfiles (configurations and settings) for shells, text editors and other terminal programs, plus a collection of scripts. Written for and work on various UNIX-like OSes, primarily for:
|
My dotfiles for macOS, Arch Linux, Raspbian and Android (Termux).
|
||||||
|
|
||||||
- Arch Linux,
|
|
||||||
- Linux Mint,
|
|
||||||
- server Ubuntu,
|
|
||||||
- macOS with GNU coreutils (i.e. BSDs are not supported),
|
|
||||||
- Android with Termux.
|
|
||||||
|
|
||||||
And also a legendary project that has survived for thousands of years of development.
|
|
||||||
|
|
||||||
## Disclaimer
|
|
||||||
|
|
||||||
### **This is my personal project! No warranty is provided for running these as a superuser, I am in no way responsible for deletion of `/` with `rm -rf`, and _absolutely no support is provided_ whatsoever unless I explicitly say so personally!**
|
|
||||||
|
|
||||||
**It is also recommended for users of this repository to read the scripts they are running. I didn't write the comments just for myself!**
|
|
||||||
|
|
||||||
**Automatic installers are deliberately not provided.**
|
|
||||||
|
|
38
install.zsh
Executable file
38
install.zsh
Executable file
|
@ -0,0 +1,38 @@
|
||||||
|
#!/usr/bin/env zsh
|
||||||
|
|
||||||
|
DOTFILES_PATH="${0:a:h}"
|
||||||
|
|
||||||
|
install_dotfile() {
|
||||||
|
local dest="$1"
|
||||||
|
local contents="$2"
|
||||||
|
|
||||||
|
if [[ -f "$dest" ]]; then
|
||||||
|
mv -vi "$dest" "$dest.dmitmel-dotfiles-backup"
|
||||||
|
fi
|
||||||
|
|
||||||
|
mkdir -pv "${dest:h}"
|
||||||
|
print -r -- "installing dotfile '$dest'"
|
||||||
|
print -r -- "$contents" > "$dest"
|
||||||
|
}
|
||||||
|
|
||||||
|
# ZSH
|
||||||
|
for file_name in zshrc; do
|
||||||
|
file_path="$DOTFILES_PATH/zsh/$file_name"
|
||||||
|
install_dotfile "$HOME/.$file_name" "source ${(q)file_path}"
|
||||||
|
done
|
||||||
|
|
||||||
|
# Neovim
|
||||||
|
for file_name in {init,ginit}.vim; do
|
||||||
|
file_path="$DOTFILES_PATH/nvim/$file_name"
|
||||||
|
install_dotfile "$HOME/.config/nvim/$file_name" "source ${(q)file_path}"
|
||||||
|
done
|
||||||
|
|
||||||
|
# Kitty
|
||||||
|
file_name=kitty.conf
|
||||||
|
file_path="$DOTFILES_PATH/kitty/$file_name"
|
||||||
|
install_dotfile "$HOME/.config/kitty/$file_name" "include ${(q)file_path}"
|
||||||
|
|
||||||
|
# tmux
|
||||||
|
file_name=tmux.conf
|
||||||
|
file_path="$DOTFILES_PATH/tmux/$file_name"
|
||||||
|
install_dotfile "$HOME/.$file_name" "source-file ${(q)file_path}"
|
14
upgrade.zsh
Executable file
14
upgrade.zsh
Executable file
|
@ -0,0 +1,14 @@
|
||||||
|
#!/usr/bin/env zsh
|
||||||
|
|
||||||
|
DOTFILES_PATH="${0:a:h}"
|
||||||
|
cd "$DOTFILES_PATH" || exit 1
|
||||||
|
ZSH_DOTFILES="$DOTFILES_PATH/zsh"
|
||||||
|
|
||||||
|
source "$ZSH_DOTFILES/functions.zsh"
|
||||||
|
|
||||||
|
git pull --rebase --stat origin master
|
||||||
|
git submodule update --init --recursive --remote --progress
|
||||||
|
|
||||||
|
ZPLG_SKIP_LOADING=1
|
||||||
|
source "$ZSH_DOTFILES/plugins.zsh"
|
||||||
|
zplg-upgrade
|
Loading…
Add table
Add a link
Reference in a new issue