From 57710f0abeb366c5a38f926899cb95d5047d7307 Mon Sep 17 00:00:00 2001 From: Will Eccles Date: Fri, 22 Oct 2021 11:08:10 -0400 Subject: [PATCH] remove nix support (#47) Nix is not supposed to be used on NixOS the way that cpm implements it, and it's (to the best of my knowledge) not the best way on other platforms as well. We also do not support non-platform-specific package managers, so the precedent says we should remove this one. --- README.md | 2 +- cpm | 18 ------------------ 2 files changed, 1 insertion(+), 19 deletions(-) diff --git a/README.md b/README.md index d71230a..4c69451 100644 --- a/README.md +++ b/README.md @@ -29,7 +29,6 @@ $ cpm [i|r|l|u|U|s|S|I|F|f|c|h] [pkg]... - dnf (Fedora) - lunar (Lunar Linux) - MacPorts (MacOS) -- nix (Global/NixOS) - guix (non-system-wide Guix) - pacman (Arch) - slackpkg (Slackware) @@ -43,6 +42,7 @@ $ cpm [i|r|l|u|U|s|S|I|F|f|c|h] [pkg]... - Cargo - Flatpak - Homebrew +- Nix - NPM - Pip - Snap diff --git a/cpm b/cpm index 448a4b0..5779b9a 100755 --- a/cpm +++ b/cpm @@ -400,21 +400,6 @@ _guix() { esac } -_nix() { - case "$OP" in - install) nix-env -iA "$@";; - remove) niv-env -e "$@";; - list) nix-env -q "$@";; - count) nix-env -q | tot;; - update) nix-channel --update;; - upgrade) nix-env -u;; - search) nix-env -qa "$@";; - show) nix-env -qa --description "$@";; - f*) pem "unsupported: this feature is functionally useless in this PM";; - clean) nix-collect-garbage -d;; - esac -} - # Use pm=PKG_MANAGER cpm COMMAND to force a specific cpm function # ie.: pm=portage cpm list if [ "$pm" ] && has "_$pm"; then @@ -455,9 +440,6 @@ elif has sorcery; then elif has lunar; then # lunar linux _lunar "$@" -elif has nix; then - # global/nixos - _nix "$@" elif has guix; then # local (non-system-wide) guix _guix "$@"