diff options
author | lassulus <lassulus@lassul.us> | 2021-08-29 14:00:18 +0200 |
---|---|---|
committer | lassulus <lassulus@lassul.us> | 2021-08-29 14:00:18 +0200 |
commit | 3c35eca7e892a43c1d2874311c504afc3dc6146e (patch) | |
tree | aba03d762ae974fe36a08775cf5c74b424abadbd /krebs/5pkgs/simple/cyberlocker-tools/default.nix | |
parent | 1c0af4687cc3499b7cb8ce0799a662e1ce00ae22 (diff) |
cyberlocker-tools: init
Diffstat (limited to 'krebs/5pkgs/simple/cyberlocker-tools/default.nix')
-rw-r--r-- | krebs/5pkgs/simple/cyberlocker-tools/default.nix | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/krebs/5pkgs/simple/cyberlocker-tools/default.nix b/krebs/5pkgs/simple/cyberlocker-tools/default.nix new file mode 100644 index 000000000..420acb192 --- /dev/null +++ b/krebs/5pkgs/simple/cyberlocker-tools/default.nix @@ -0,0 +1,19 @@ +{ pkgs }: +pkgs.symlinkJoin { + name = "cyberlocker-tools"; + paths = [ + (pkgs.writers.writeDashBin "cput" '' + set -efu + path=$1 + + ${pkgs.curl}/bin/curl -Ss --data-binary @- "http://c.r/$path" + echo "http://c.r/$path" + '') + (pkgs.writers.writeDashBin "cdel" '' + set -efu + path=$1 + + ${pkgs.curl}/bin/curl -X DELETE "http://c.r/$path" + '') + ]; +} |