feat(scripts): global scripts and fetch all git

This commit is contained in:
Florian Schmitt 2025-03-01 18:45:27 +03:00
parent 8ae96ad1ca
commit f110fbfaf8
3 changed files with 15 additions and 0 deletions

View file

@ -139,6 +139,7 @@
EDITOR = "nvim"; EDITOR = "nvim";
}; };
home.sessionPath = [ home.sessionPath = [
"$HOME/Code/nixos-config/scripts"
"$HOME/.local/bin" "$HOME/.local/bin"
"$HOME/go/bin" "$HOME/go/bin"
]; ];

View file

@ -120,6 +120,7 @@ in
#LD_LIBRARY_PATH = "${pkgs.stdenv.cc.cc.lib}/lib"; #LD_LIBRARY_PATH = "${pkgs.stdenv.cc.cc.lib}/lib";
}; };
home.sessionPath = [ home.sessionPath = [
"$HOME/Code/nixos-config/scripts"
"$HOME/.local/bin" "$HOME/.local/bin"
"$HOME/go/bin" "$HOME/go/bin"
]; ];

View file

@ -0,0 +1,13 @@
#!/usr/bin/env bash
# inspired from https://madalinaeleonorag.medium.com/git-fetch-pull-for-all-repos-once-82a0abff828b
cd ~/Code/
for i in */.git; do (
echo 📂 ${i/\/.git/}; cd $i/..;
echo 🔄 Fetching;
git fetch --all;
echo 🔽 Pulling;
git pull;
echo ————————————————————————);
done
cd ~/Code/