You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

11 lines
254 B

  1. #!/usr/bin/env bash
  2. DEVICE=$1
  3. if [ -z $DEVICE ] ; then
  4. echo "missing 1st argument (DEVICE), ie. the name of the device where the backup is being done"
  5. exit 1
  6. fi
  7. cp /etc/nixos/* ./nixos/
  8. mv ./nixos/configuration.nix ./nixos/$DEVICE-configuration.nix