From ed8059f4c4d19bbfdb535757a4c85e8a16fa9c1b Mon Sep 17 00:00:00 2001 From: colin Date: Wed, 11 Jan 2023 10:49:56 +0000 Subject: [PATCH] feed init now also initializes the feed info --- pkgs/feeds/default.nix | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/pkgs/feeds/default.nix b/pkgs/feeds/default.nix index 5f9f3c4d..33400250 100644 --- a/pkgs/feeds/default.nix +++ b/pkgs/feeds/default.nix @@ -29,9 +29,13 @@ #!/usr/bin/env nix-shell #!nix-shell -i bash -p git name="$1" - mkdir modules/data/feeds/sources/"$name" - touch modules/data/feeds/sources/"$name"/default.json - git add modules/data/feeds/sources/"$name"/default.json + url="https://$name" + dir="modules/data/feeds/sources/$name" + json_path="$dir/default.json" + mkdir "$dir" + touch "$json_path" + git add "$json_path" + ${./update.sh} "$url" "$json_path" ''; } ))