From 0ebc537fe3b0774cd9df9bf5bdb6ae770a4a0e3b Mon Sep 17 00:00:00 2001 From: Jordan Orelli Date: Mon, 27 May 2024 10:03:55 -0500 Subject: [PATCH] setting up a new mac laptop --- .bash_profile | 1 + .bashrc | 8 +++++++- .gitconfig | 3 +++ config.ini | 20 ++++++++++++++++---- kitty/kitty.conf | 2 +- 5 files changed, 28 insertions(+), 6 deletions(-) create mode 100644 .gitconfig diff --git a/.bash_profile b/.bash_profile index 2b53824..1dd0f38 100644 --- a/.bash_profile +++ b/.bash_profile @@ -5,3 +5,4 @@ fi if [ -e "$HOME/.nix-profile/etc/profile.d/nix.sh" ]; then source "$HOME/.nix-profile/etc/profile.d/nix.sh" fi # added by Nix installer +. "$HOME/.cargo/env" diff --git a/.bashrc b/.bashrc index fc6f992..893d16f 100644 --- a/.bashrc +++ b/.bashrc @@ -67,7 +67,13 @@ fi # if kitty is installed, register its completions if command -v kitty &> /dev/null then - source <(kitty + complete setup bash) + # This is a little annoying but the version of Bash on MacOS is so old that + # it doesn't have process substitution + KITTY_COMPLETION_FILE=$(mktemp) + kitty + complete setup bash > "$KITTY_COMPLETION_FILE" + source "$KITTY_COMPLETION_FILE" + rm "$KITTY_COMPLETION_FILE" + unset KITTY_COMPLETION_FILE fi # sometimes I just put binary files in a bin dir in my home directory. Is this diff --git a/.gitconfig b/.gitconfig new file mode 100644 index 0000000..3ce587f --- /dev/null +++ b/.gitconfig @@ -0,0 +1,3 @@ +[user] + name = Jordan Orelli + email = jordanorelli@gmail.com diff --git a/config.ini b/config.ini index e984f9d..f07518f 100644 --- a/config.ini +++ b/config.ini @@ -1,6 +1,12 @@ [run submodules] +when: host.has('git') cmd: git submodule init +[home git-prefs] +when: host.has('git') +files: + .gitconfig + [home bash-prefs] when: host.has('bash') files: @@ -19,6 +25,12 @@ files: when: host.has('kitty') files: kitty/kitty.conf > .config/kitty/kitty.conf + +# We only need the kitty.desktop config on linux, that's like a linux desktop +# manager thing +[home kitty-desktop] +when: host.has('kitty') and host.is_linux +files: desktop/kitty.desktop > .local/share/applications/kitty.desktop [link-files rofi] @@ -51,10 +63,10 @@ files: nvim/lua nvim/init.vim -# [git vundle] -# when: host.has('vim') or host.has('nvim') -# repo: https://github.com/VundleVim/Vundle.vim.git -# target: ~/.vim/bundle/Vundle.vim +[git vundle] +when: host.has('vim') or host.has('nvim') +repo: https://github.com/VundleVim/Vundle.vim.git +target: ~/.vim/bundle/Vundle.vim [git packer-posix] when: not host.is_windows diff --git a/kitty/kitty.conf b/kitty/kitty.conf index e154c2f..9c67e3e 100644 --- a/kitty/kitty.conf +++ b/kitty/kitty.conf @@ -2404,4 +2404,4 @@ # BEGIN_KITTY_THEME # Jellybeans include current-theme.conf -# END_KITTY_THEME \ No newline at end of file +# END_KITTY_THEME