-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathupdate_repo.sh
executable file
·55 lines (48 loc) · 1.01 KB
/
update_repo.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
#!/usr/bin/env bash
# vim: ft=bash :
# neovim
if [ -e ~/.config/nvim/ ]; then
echo "Copying neovim config..."
rm -rf nvim/*
cp -r ~/.config/nvim/* nvim/
fi
# tmux
if [ -e ~/.config/tmux/ ]; then
echo "Copying tmux config..."
rm -rf tmux/*
cp -r ~/.config/tmux/* tmux/
cp ~/.config/tmux/.tmux.conf tmux/.tmux.conf 2&> /dev/null
fi
# fish
if [ -e ~/.config/fish/ ]; then
echo "Copying fish config..."
rm -rf fish/*
cp -r ~/.config/fish/* fish/
fi
# kitty
if [ -e ~/.config/kitty/ ]; then
echo "Copying kitty config..."
rm -rf kitty/*
cp -r ~/.config/kitty/* kitty/
fi
# system
if [ -e ~/.config/system/ ]; then
echo "Copying system config..."
rm -rf system/*
cp ~/.config/system/* system/
fi
# git config
cp ~/.gitconfig .gitconfig
uname=$(uname)
case "$uname" in
Darwin)
brew list --formula > system/brew_output.txt
brew list --cask > system/brew_cask_output.txt
;;
Linux)
dconf dump / > system/dconf-settings.ini
;;
*)
echo "Unsupported OS: $uname"
;;
esac