mirror of
https://github.com/itme-brain/nixos.git
synced 2026-03-24 08:39:42 -04:00
working on the overlay
This commit is contained in:
parent
a62b9da1e3
commit
81be08ae7a
2 changed files with 24 additions and 4 deletions
12
justfile
12
justfile
|
|
@ -86,3 +86,15 @@ gh MESSAGE:
|
|||
git add -A
|
||||
git commit -m "{{MESSAGE}}"
|
||||
git push
|
||||
|
||||
#Fetch resources and compute sha256 hash
|
||||
hash URL:
|
||||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
if echo "{{URL}}" | grep -E '\.(tar\.gz|tgz|zip)$'; then
|
||||
CONTENTS=$(nix-prefetch-url --unpack "{{URL}}")
|
||||
else
|
||||
CONTENTS=$(nix-prefetch-url "{{URL}}")
|
||||
fi
|
||||
HASH=$(echo -n "$CONTENTS" | nix hash to-sri --type sha256)
|
||||
echo "$HASH"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue