Convert jq to templates

main
Buddy Sandidge 2 years ago
parent 0203957b9e
commit 0c402d3754

@ -1,3 +1,4 @@
{{ if lookPath "jq" -}}
def reset: "\u001b[0m"; def reset: "\u001b[0m";
def black: "\u001b[30m"; def black: "\u001b[30m";
def white: "\u001b[97m"; def white: "\u001b[97m";
@ -7,3 +8,4 @@ def green: "\u001b[32m";
def yellow: "\u001b[33m"; def yellow: "\u001b[33m";
def red: "\u001b[31m"; def red: "\u001b[31m";
def magenta: "\u001b[35m"; def magenta: "\u001b[35m";
{{- end }}

@ -1,3 +1,4 @@
{{ if lookPath "jq" -}}
def browser: env.BROWSER; def browser: env.BROWSER;
def editor: env.EDITOR; def editor: env.EDITOR;
def home: env.HOME; def home: env.HOME;
@ -12,3 +13,4 @@ def config: env.XDG_CONFIG_HOME;
def data: env.XDG_DATA_HOME; def data: env.XDG_DATA_HOME;
def runtime: env.XDG_RUNTIME_DIR; def runtime: env.XDG_RUNTIME_DIR;
def state: env.XDG_STATE_HOME; def state: env.XDG_STATE_HOME;
{{- end }}

@ -1,3 +1,4 @@
{{ if lookPath "jq" -}}
def by_time: sort_by(.created_at) | reverse; def by_time: sort_by(.created_at) | reverse;
def asset($os; $arch): def asset($os; $arch):
@ -25,4 +26,4 @@ assets
] | join("\n") ] | join("\n")
) )
"; ";
{{- end }}
Loading…
Cancel
Save