mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-26 08:53:21 +00:00
clash-geoip: add update script
This commit is contained in:
parent
f4ef149e9c
commit
b32d7053fa
@ -18,6 +18,8 @@ stdenvNoCC.mkDerivation rec {
|
||||
runHook postInstall
|
||||
'';
|
||||
|
||||
passthru.updateScript = ./update.sh;
|
||||
|
||||
meta = with lib; {
|
||||
description = "A GeoLite2 data created by MaxMind";
|
||||
homepage = "https://github.com/Dreamacro/maxmind-geoip";
|
||||
|
6
pkgs/data/misc/clash-geoip/update.sh
Executable file
6
pkgs/data/misc/clash-geoip/update.sh
Executable file
@ -0,0 +1,6 @@
|
||||
#! /usr/bin/env nix-shell
|
||||
#! nix-shell -i bash -p common-updater-scripts curl jq
|
||||
set -euo pipefail
|
||||
|
||||
RELEASE=$(curl "https://api.github.com/repos/Dreamacro/maxmind-geoip/releases/latest")
|
||||
update-source-version clash-geoip "$(echo $RELEASE | jq -r .tag_name)"
|
Loading…
Reference in New Issue
Block a user