From 49ebf1155e7e40e50c7b5fc44278906f3ba06400 Mon Sep 17 00:00:00 2001 From: caem Date: Thu, 25 Jul 2024 21:35:41 +0200 Subject: [PATCH] Remove support for non-nixos installations --- README.md | 6 ----- non-nixos-install.sh | 28 ----------------------- users/i/README.md | 4 ---- users/i/home-manager/home-manager | 1 - users/i/home-manager/home.nix | 28 ----------------------- users/i/home-manager/packages/neovim.nix | 16 ------------- users/i/home-manager/shared_packages/nvim | 1 - users/i/home-manager/shared_packages/zsh | 1 - users/i/nix/nix | 1 - users/i/nix/nix.conf | 1 - users/i/nixpkgs/config.nix | 4 ---- users/i/nixpkgs/nixpkgs | 1 - 12 files changed, 92 deletions(-) delete mode 100755 non-nixos-install.sh delete mode 100644 users/i/README.md delete mode 120000 users/i/home-manager/home-manager delete mode 100644 users/i/home-manager/home.nix delete mode 100644 users/i/home-manager/packages/neovim.nix delete mode 120000 users/i/home-manager/shared_packages/nvim delete mode 120000 users/i/home-manager/shared_packages/zsh delete mode 120000 users/i/nix/nix delete mode 100644 users/i/nix/nix.conf delete mode 100644 users/i/nixpkgs/config.nix delete mode 120000 users/i/nixpkgs/nixpkgs diff --git a/README.md b/README.md index 2e56bb2..3582a03 100644 --- a/README.md +++ b/README.md @@ -47,7 +47,6 @@ modify and share this configuration to your heart's content, no attribution requ ``` ## Installing -### NixOS This configuration uses impermanence with btrfs snapshots so you'll have to partition your system in a certain way. @@ -76,8 +75,3 @@ in the `secrets/{user}` directory as `pass`. Finally, in the config directory run `nixos-install --flake '.#'`, reboot and you're done. -### Non-NixOS -Run the `non-nixos-install.sh` script. It will install both home-manager and nix. -Your user is assumed to be called "i". You need to replace every instance of it -in case you want to use a different username. - diff --git a/non-nixos-install.sh b/non-nixos-install.sh deleted file mode 100755 index c267a45..0000000 --- a/non-nixos-install.sh +++ /dev/null @@ -1,28 +0,0 @@ -#!/usr/bin/env bash - -# This script sets up nix and home-manager for distributions that are not NixOS. - -set -e -BASE_PATH="$(dirname "$(realpath "$0")")" - -if [ ! -d "/nix" ]; then - # Do multi-user installation - sh <(curl -L https://nixos.org/nix/install) --daemon - exec bash -e "$(realpath "$0")" -fi - -if [ -z "$(nix-channel --list | grep nixpkgs)" ]; then - nix-channel --add https://nixos.org/channels/nixpkgs-unstable nixpkgs - nix-channel --update -fi - -if [ ! -x "$HOME/.nix-profile/bin/home-manager" ]; then - ln -svf "$BASE_PATH/users/i/home-manager" "$HOME/.config/home-manager" - ln -svf "$BASE_PATH/users/i/nixpkgs" "$HOME/.config/nixpkgs" - ln -svf "$BASE_PATH/users/i/nix" "$HOME/.config/nix" - - nix-channel --add https://github.com/nix-community/home-manager/archive/master.tar.gz home-manager - nix-channel --update - nix-shell '' -A install -fi - diff --git a/users/i/README.md b/users/i/README.md deleted file mode 100644 index 334c220..0000000 --- a/users/i/README.md +++ /dev/null @@ -1,4 +0,0 @@ -This user is a standalone home-manager user which I use for -systems that are not NixOS but still make use of home-manager. -You should not import this user when running NixOS. - diff --git a/users/i/home-manager/home-manager b/users/i/home-manager/home-manager deleted file mode 120000 index 95e61c2..0000000 --- a/users/i/home-manager/home-manager +++ /dev/null @@ -1 +0,0 @@ -/home/i/Projects/nixos-system-config/users/i/home-manager \ No newline at end of file diff --git a/users/i/home-manager/home.nix b/users/i/home-manager/home.nix deleted file mode 100644 index 0f38dfd..0000000 --- a/users/i/home-manager/home.nix +++ /dev/null @@ -1,28 +0,0 @@ -{ pkgs, ... }: - -{ - home.username = "i"; - home.homeDirectory = "/home/i"; - home.stateVersion = "24.05"; - - home.file.".zshenv" = { - text = "source ~/.nix-profile/etc/profile.d/hm-session-vars.sh"; - }; - - home.sessionVariables = { - EDITOR = "nvim"; - }; - - imports = [ - ./shared_packages/nvim/neovim.nix - ./shared_packages/zsh/zsh-home.nix - ./packages/neovim.nix - ]; - - home.packages = with pkgs; [ - act - ]; - - programs.home-manager.enable = true; -} - diff --git a/users/i/home-manager/packages/neovim.nix b/users/i/home-manager/packages/neovim.nix deleted file mode 100644 index 21e392d..0000000 --- a/users/i/home-manager/packages/neovim.nix +++ /dev/null @@ -1,16 +0,0 @@ -{ pkgs, ... }: - -{ - /* Because programs.neovim.extraPackages doesn't work */ - home.packages = with pkgs; [ - lua-language-server - nodePackages.intelephense - nodePackages.typescript-language-server - clang-tools - ripgrep - nil - gcc - basedpyright - ]; -} - diff --git a/users/i/home-manager/shared_packages/nvim b/users/i/home-manager/shared_packages/nvim deleted file mode 120000 index 9817178..0000000 --- a/users/i/home-manager/shared_packages/nvim +++ /dev/null @@ -1 +0,0 @@ -../../../hu/packages/nvim \ No newline at end of file diff --git a/users/i/home-manager/shared_packages/zsh b/users/i/home-manager/shared_packages/zsh deleted file mode 120000 index 5e6198f..0000000 --- a/users/i/home-manager/shared_packages/zsh +++ /dev/null @@ -1 +0,0 @@ -../../../hu/packages/zsh \ No newline at end of file diff --git a/users/i/nix/nix b/users/i/nix/nix deleted file mode 120000 index 5539dcc..0000000 --- a/users/i/nix/nix +++ /dev/null @@ -1 +0,0 @@ -/home/i/Projects/nixos-system-config/users/i/nix \ No newline at end of file diff --git a/users/i/nix/nix.conf b/users/i/nix/nix.conf deleted file mode 100644 index c7d7291..0000000 --- a/users/i/nix/nix.conf +++ /dev/null @@ -1 +0,0 @@ -experimental-features = nix-command flakes diff --git a/users/i/nixpkgs/config.nix b/users/i/nixpkgs/config.nix deleted file mode 100644 index 0ad4e95..0000000 --- a/users/i/nixpkgs/config.nix +++ /dev/null @@ -1,4 +0,0 @@ -{ - allowUnfree = true; -} - diff --git a/users/i/nixpkgs/nixpkgs b/users/i/nixpkgs/nixpkgs deleted file mode 120000 index d7c5f99..0000000 --- a/users/i/nixpkgs/nixpkgs +++ /dev/null @@ -1 +0,0 @@ -/home/i/Projects/nixos-system-config/users/i/nixpkgs \ No newline at end of file