Added boatswain and copy script
This commit is contained in:
parent
59888fba83
commit
a6b5e522b9
2 changed files with 25 additions and 0 deletions
1
apps.nix
1
apps.nix
|
@ -15,6 +15,7 @@
|
||||||
libreoffice-qt
|
libreoffice-qt
|
||||||
hunspell
|
hunspell
|
||||||
hunspellDicts.en_US
|
hunspellDicts.en_US
|
||||||
|
pkgs.boatswain
|
||||||
];
|
];
|
||||||
|
|
||||||
programs.steam = {
|
programs.steam = {
|
||||||
|
|
24
nixcp.sh
Executable file
24
nixcp.sh
Executable file
|
@ -0,0 +1,24 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# Get the directory where the script is located
|
||||||
|
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
|
||||||
|
|
||||||
|
# Define the target directory
|
||||||
|
TARGET_DIR="/etc/nixos"
|
||||||
|
|
||||||
|
# Check if the script is being run with sudo privileges (since /etc/nixos requires elevated permissions)
|
||||||
|
if [ "$(id -u)" -ne 0 ]; then
|
||||||
|
echo "This script must be run with sudo or as root."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Copy all .nix files from the script's directory to the /etc/nixos directory
|
||||||
|
for file in "$SCRIPT_DIR"/*.nix; do
|
||||||
|
if [ -f "$file" ]; then
|
||||||
|
# Copy the file, replacing the existing one
|
||||||
|
cp -f "$file" "$TARGET_DIR/"
|
||||||
|
echo "Copied $file to $TARGET_DIR/"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
|
echo "All .nix files have been copied to $TARGET_DIR."
|
Loading…
Add table
Reference in a new issue