You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
local timestamp="$(date +%Y%m%d --date="${timespan}")"
746
-
local url="http://snapshot.debian.org/mr/timestamp/?archive=debian&after=${timestamp}"
747
-
python3 -c 'import sys,urllib.request,json;[print(x) for x in json.loads(urllib.request.urlopen(sys.argv[1]).read())["result"]["debian"]]' "$url" 2>/dev/null || :
748
-
}
741
+
_apt_snapshot_dates() {
742
+
local -a expl snapshotdates
749
743
snapshotdates=(
750
-
${(u)$(getdates)%T*}
744
+
${(u)$(
745
+
(( $+commands[python3] )) || return 0
746
+
local timestamp="$(date +%Y%m%d --date=-6month)"
747
+
local url="http://snapshot.debian.org/mr/timestamp/?archive=debian&after=${timestamp}"
748
+
python3 -c 'import sys,urllib.request,json;[print(x) for x in json.loads(urllib.request.urlopen(sys.argv[1]).read())["result"]["debian"]]' "$url" 2>/dev/null || :
749
+
)%T*}
751
750
)
752
-
_wanted list expl 'wayback date(s)' compadd ${expl} -- ${snapshotdates}
751
+
_wanted list expl 'wayback date' compadd -- ${snapshotdates}
0 commit comments