about summary refs log tree commit diff stats
path: root/sys/nixpkgs
diff options
context:
space:
mode:
Diffstat (limited to 'sys/nixpkgs')
-rwxr-xr-xsys/nixpkgs/pkgs/plgs-pkgs/update.sh (renamed from sys/nixpkgs/pkgs/plgs-pkgs/update_neovim_plugins)0
-rwxr-xr-xsys/nixpkgs/pkgs/update_pkgs28
-rw-r--r--sys/nixpkgs/pkgs/update_vim_plugins/.envrc1
-rw-r--r--sys/nixpkgs/pkgs/update_vim_plugins/flake.lock61
-rw-r--r--sys/nixpkgs/pkgs/update_vim_plugins/flake.nix25
-rwxr-xr-xsys/nixpkgs/pkgs/update_vim_plugins/update.sh5
-rwxr-xr-xsys/nixpkgs/pkgs/yt/update.sh6
7 files changed, 126 insertions, 0 deletions
diff --git a/sys/nixpkgs/pkgs/plgs-pkgs/update_neovim_plugins b/sys/nixpkgs/pkgs/plgs-pkgs/update.sh
index ea71c6fa..ea71c6fa 100755
--- a/sys/nixpkgs/pkgs/plgs-pkgs/update_neovim_plugins
+++ b/sys/nixpkgs/pkgs/plgs-pkgs/update.sh
diff --git a/sys/nixpkgs/pkgs/update_pkgs b/sys/nixpkgs/pkgs/update_pkgs
new file mode 100755
index 00000000..df26784b
--- /dev/null
+++ b/sys/nixpkgs/pkgs/update_pkgs
@@ -0,0 +1,28 @@
+#!/usr/bin/env sh
+
+die() {
+    printf "\033[31;1mError: \033[0m%s" "$1";
+    exit 1
+}
+
+cd "$(dirname "$0")" || die "Bug: run with false dirname ('$0')!"
+
+
+fd . --type directory --max-depth 1 | while read -r dir; do
+    cd "$dir" || die "Dir '$dir' does not exist"
+
+    if [ -f update.sh ]; then
+        printf "\033[34;1m> \033[0m%s" "\033[32;1mRunning '${dir}update.sh'\033[0m";
+
+        nix flake update
+
+        direnv allow
+        eval "$(direnv export bash)"
+
+        ./update.sh
+    fi
+    cd - > /dev/null || die "Bug: Last dir does not exist"
+done
+
+
+# vim: ft=sh
diff --git a/sys/nixpkgs/pkgs/update_vim_plugins/.envrc b/sys/nixpkgs/pkgs/update_vim_plugins/.envrc
new file mode 100644
index 00000000..3550a30f
--- /dev/null
+++ b/sys/nixpkgs/pkgs/update_vim_plugins/.envrc
@@ -0,0 +1 @@
+use flake
diff --git a/sys/nixpkgs/pkgs/update_vim_plugins/flake.lock b/sys/nixpkgs/pkgs/update_vim_plugins/flake.lock
new file mode 100644
index 00000000..8e5a9529
--- /dev/null
+++ b/sys/nixpkgs/pkgs/update_vim_plugins/flake.lock
@@ -0,0 +1,61 @@
+{
+  "nodes": {
+    "flake-utils": {
+      "inputs": {
+        "systems": "systems"
+      },
+      "locked": {
+        "lastModified": 1705309234,
+        "narHash": "sha256-uNRRNRKmJyCRC/8y1RqBkqWBLM034y4qN7EprSdmgyA=",
+        "owner": "numtide",
+        "repo": "flake-utils",
+        "rev": "1ef2e671c3b0c19053962c07dbda38332dcebf26",
+        "type": "github"
+      },
+      "original": {
+        "owner": "numtide",
+        "repo": "flake-utils",
+        "type": "github"
+      }
+    },
+    "nixpkgs": {
+      "locked": {
+        "lastModified": 1705856552,
+        "narHash": "sha256-JXfnuEf5Yd6bhMs/uvM67/joxYKoysyE3M2k6T3eWbg=",
+        "owner": "NixOS",
+        "repo": "nixpkgs",
+        "rev": "612f97239e2cc474c13c9dafa0df378058c5ad8d",
+        "type": "github"
+      },
+      "original": {
+        "owner": "NixOS",
+        "ref": "nixos-unstable",
+        "repo": "nixpkgs",
+        "type": "github"
+      }
+    },
+    "root": {
+      "inputs": {
+        "flake-utils": "flake-utils",
+        "nixpkgs": "nixpkgs"
+      }
+    },
+    "systems": {
+      "locked": {
+        "lastModified": 1681028828,
+        "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
+        "owner": "nix-systems",
+        "repo": "default",
+        "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
+        "type": "github"
+      },
+      "original": {
+        "owner": "nix-systems",
+        "repo": "default",
+        "type": "github"
+      }
+    }
+  },
+  "root": "root",
+  "version": 7
+}
diff --git a/sys/nixpkgs/pkgs/update_vim_plugins/flake.nix b/sys/nixpkgs/pkgs/update_vim_plugins/flake.nix
new file mode 100644
index 00000000..736b7804
--- /dev/null
+++ b/sys/nixpkgs/pkgs/update_vim_plugins/flake.nix
@@ -0,0 +1,25 @@
+{
+  description = "update_vim_plugins";
+
+  inputs = {
+    nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
+
+    flake-utils.url = "github:numtide/flake-utils";
+  };
+
+  outputs = {
+    self,
+    nixpkgs,
+    flake-utils,
+  }: (flake-utils.lib.eachDefaultSystem (system: let
+    pkgs = nixpkgs.legacyPackages.${system};
+  in {
+    devShells.default = pkgs.mkShell {
+      packages = [
+        pkgs.python3
+        pkgs.poetry
+
+      ];
+    };
+  }));
+}
diff --git a/sys/nixpkgs/pkgs/update_vim_plugins/update.sh b/sys/nixpkgs/pkgs/update_vim_plugins/update.sh
new file mode 100755
index 00000000..1bad12a9
--- /dev/null
+++ b/sys/nixpkgs/pkgs/update_vim_plugins/update.sh
@@ -0,0 +1,5 @@
+#!/usr/bin/env sh
+
+poetry update --lock
+
+# vim: ft=sh
diff --git a/sys/nixpkgs/pkgs/yt/update.sh b/sys/nixpkgs/pkgs/yt/update.sh
new file mode 100755
index 00000000..2529167c
--- /dev/null
+++ b/sys/nixpkgs/pkgs/yt/update.sh
@@ -0,0 +1,6 @@
+#!/usr/bin/env sh
+
+cargo update && cargo upgrade
+
+
+# vim: ft=sh