feat: install script for tmux
This commit is contained in:
parent
f1f5b03ddf
commit
754b07df67
21
install.sh
21
install.sh
@ -1,10 +1,11 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
# ~/dotfiles/install.sh
|
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
|
# Create config directories
|
||||||
mkdir -p "$HOME/.config"
|
mkdir -p "$HOME/.config"
|
||||||
|
|
||||||
|
# Handle .config directory symlinks first
|
||||||
cd "$HOME/dotfiles/config" || exit 1
|
cd "$HOME/dotfiles/config" || exit 1
|
||||||
for dir in *; do
|
for dir in *; do
|
||||||
[ -d "$dir" ] || continue
|
[ -d "$dir" ] || continue
|
||||||
@ -21,3 +22,21 @@ for dir in *; do
|
|||||||
ln -sf "$PWD/$dir" "$target"
|
ln -sf "$PWD/$dir" "$target"
|
||||||
echo "Linked $dir"
|
echo "Linked $dir"
|
||||||
done
|
done
|
||||||
|
|
||||||
|
# Handle root directory dotfiles
|
||||||
|
cd "$HOME/dotfiles/root" || exit 1
|
||||||
|
for file in *; do
|
||||||
|
[ -f "$file" ] || continue
|
||||||
|
|
||||||
|
target="$HOME/.$file"
|
||||||
|
if [ -L "$target" ]; then
|
||||||
|
echo "Skipping .$file (symlink already exists)"
|
||||||
|
continue
|
||||||
|
elif [ -e "$target" ]; then
|
||||||
|
echo "Skipping .$file (target exists and is not a symlink)"
|
||||||
|
continue
|
||||||
|
fi
|
||||||
|
|
||||||
|
ln -sf "$PWD/$file" "$target"
|
||||||
|
echo "Linked .$file"
|
||||||
|
done
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
# Use C-a as prefix because reaching for C-b is inefficient
|
# Use C-a as prefix because reaching for C-b is inefficient
|
||||||
|
set-option -g default-shell "/usr/bin/fish"
|
||||||
set -g prefix C-a
|
set -g prefix C-a
|
||||||
unbind C-b
|
unbind C-b
|
||||||
|
|
||||||
@ -42,3 +43,6 @@ set-option -g history-limit 50000
|
|||||||
|
|
||||||
# Status bar that doesn't look like it's from 1970
|
# Status bar that doesn't look like it's from 1970
|
||||||
set -g status-style 'bg=#333333 fg=#5eacd3'
|
set -g status-style 'bg=#333333 fg=#5eacd3'
|
||||||
|
|
||||||
|
# the fish shell
|
||||||
|
set-option -g default-shell "/usr/bin/fish"
|
||||||
|
Loading…
Reference in New Issue
Block a user