update all plugins with script

This commit is contained in:
Robin Appelman 2026-07-09 19:33:45 +02:00
commit efc66e4155
2 changed files with 17 additions and 1 deletions

View file

@ -1,7 +1,7 @@
#! /usr/bin/env nu
def main [] {
update_all_depots
# update_all_depots
# nix-update --flake --use-update-script ambuild
# nix build .#ambuild
@ -20,6 +20,8 @@ def main [] {
# nix-update --flake --use-update-script sourcemod-include-steamworks
# nix-update --flake --use-update-script sourcemod-includes
list_plugins | each {|plugin| nix-update --flake --use-update-script $"sourcemod-plugin-($plugin)"}
nix fmt
}
@ -93,3 +95,7 @@ def get_manifest_hash [manifest: record] {
def extract_hash [] {
parse -r "got: (?P<hash>sha256-[A-Za-z0-9+\/=]+)" | first | get 'hash'
}
def list_plugins [] {
ls -s nix/sourcemod/plugins/ | where type == file and ($it.name | str ends-with '.nix') and ($it.name != 'overlay.nix') | get name | str substring 0..-5
}