tangled
alpha
login
or
join now
pyrox.dev
/
nixpkgs
lol
0
fork
atom
overview
issues
pulls
pipelines
Use the same logic to retreive the commit date
Valentin Brandl
2 years ago
42361fd8
432b6949
+3
-6
1 changed file
expand all
collapse all
unified
split
pkgs
applications
audio
psst
update.sh
+3
-6
pkgs/applications/audio/psst/update.sh
···
21
21
set -euo pipefail
22
22
23
23
if [ -z "$rev" ]; then
24
24
-
response="$(wget -O- "${TOKEN_ARGS[@]}" "https://api.github.com/repos/jpochyla/psst/commits?per_page=1")"
25
25
-
rev="$(jq -r '.[0].sha' <<< "$response")"
26
26
-
date="$(jq -r '.[0].commit.author.date' <<< "$response" | cut -dT -f1)"
27
27
-
else
28
28
-
response="$(wget -O- "${TOKEN_ARGS[@]}" "https://api.github.com/repos/jpochyla/psst/commits/$rev")"
29
29
-
date="$(jq -r '.commit.author.date' <<< "$response" | cut -dT -f1)"
24
24
+
rev="$(wget -O- "${TOKEN_ARGS[@]}" "https://api.github.com/repos/jpochyla/psst/commits?per_page=1" | jq -r '.[0].sha')"
30
25
fi
26
26
+
27
27
+
date="$(wget -O- "${TOKEN_ARGS[@]}" "https://api.github.com/repos/jpochyla/psst/commits/$rev" | jq -r '.commit.author.date' | cut -dT -f1)"
31
28
32
29
version="unstable-$date"
33
30