broke out scripts folder

This commit is contained in:
John Lancaster
2024-12-29 10:16:04 -06:00
parent 30fcca3624
commit 1bad54c7a2
3 changed files with 58 additions and 13 deletions

16
scripts/link-nix.sh Normal file
View File

@@ -0,0 +1,16 @@
#!/usr/bin/env bash
set -e
if [ "$#" -eq 0 ]; then
echo "Error: No arguments provided."
echo "Usage: $0 <path>"
exit 1
fi
CURRENT=$(readlink -f /etc/nixos)
sudo rm /etc/nixos
echo "Unlinked $CURRENT"
sudo ln -s $1 /etc/nixos
echo "Linked $(readlink -f /etc/nixos)"