dotfiles/_src.posix/.chezmoiexternal.yaml

189 lines
5.7 KiB
YAML
Raw Permalink Normal View History

# https://www.chezmoi.io/reference/special-files-and-directories/chezmoiexternal-format/
# The file will be empty (except for this comment) unless CZ_EXTR env variable exists.
#
# The externals are checked based on the refreshPeriod whenever an `apply` (or `update`) operations run
#
# The syntax to update all externals (and nothing else):
# ```sh
# CZ_EXTR=1 chezmoi apply --include externals
# ```
#
{{/*
#
# Variable Type Default Description
# type string none External type (file, archive, archive-file, or git-repo)
# url string none URL
# refreshPeriod duration 0 Refresh period (Examples: one day (24h), one week (168h), or four weeks (672h))
# executable bool false Add executable_ attribute to file
# path string none Path to file in archive
*/}}
{{- if (env "CZ_EXTR") -}}
{{/* Initialize template variables */}}
{{- $myArch := "" -}}
{{- $defaultRefresh := "168h" -}}
{{- $externals := dict -}}
{{/*
# valid arch strings:
# aarch64-apple-darwin
# x86_64-apple-darwin
# aarch64-unknown-linux-musl
# x86_64-unknown-linux-musl
*/}}
{{ $myArch = (printf "%s-%s" .sz.os.arch_alt .sz.os.rust_rel_target )}}
2024-11-25 22:47:26 +00:00
{{- with $repo := "zellij-org/zellij" -}}
{{- with $version := (gitHubLatestRelease $repo).GetTagName -}}
{{- $_ := set $externals ".cache/chezmoi/tmp/zellij" (dict
"type" "archive-file"
"url" (printf "https://github.com/%s/releases/download/%s/zellij-%s.tar.gz" $repo $version $myArch)
2024-11-25 22:47:26 +00:00
"path" "zellij"
"executable" true
"refreshPeriod" $defaultRefresh
) -}}
{{- end -}}
{{- end -}}
{{- with $repo := "dandavison/delta" -}}
{{- with $version := (gitHubLatestRelease $repo).GetTagName -}}
{{- $_ := set $externals ".local/bin/delta" (dict
"type" "archive-file"
"url" (printf "https://github.com/%s/releases/download/%s/delta-%s-%s.tar.gz" $repo $version $version $myArch)
"path" (printf "delta-%s-%s/delta" $version $myArch)
"refreshPeriod" $defaultRefresh
) -}}
{{- end -}}
{{- end -}}
{{/*
# valid arch strings:
# darwin_amd64
# darwin_arm64
# linux_386
# linux_amd64
# linux_arm64
# windows_386
# windows_amd64
# windows_arm64
*/}}
{{- $myArch = (printf "%s_%s" .chezmoi.os .chezmoi.arch) -}}
{{- with $repo := "hickford/git-credential-oauth" -}}
{{- with $version := trimPrefix "v" (gitHubLatestRelease $repo).GetTagName -}}
{{- $_ := set $externals ".local/bin/git-credential-oauth" (dict
"type" "archive-file"
"url" (printf "https://github.com/%s/releases/download/v%s/git-credential-oauth_%s_%s.tar.gz" $repo $version $version $myArch)
"path" "git-credential-oauth"
2024-11-25 22:44:57 +00:00
"executable" true
"refreshPeriod" $defaultRefresh
) -}}
{{- end -}}
{{- end -}}
{{/*
# valid arch strings:
# linux-aarch64
# linux-arm
# linux-armv7
# linux-x86_64
# mac-x86
# mac
# win
*/}}
{{- $myArch = .sz.os.short -}}
{{- if eq .chezmoi.os "linux" -}}
{{- $myArch = (printf "%s-%s" .chezmoi.os .sz.os.arch_alt) -}}
{{- end -}}
2024-11-25 22:47:26 +00:00
{{- with $repo := "extrawurst/gitui" -}}
{{- with $version := (gitHubLatestRelease $repo).GetTagName -}}
2024-11-25 22:47:26 +00:00
{{- $_ := set $externals ".local/bin/gitui" (dict
"type" "archive-file"
"url" (printf "https://github.com/%s/releases/download/%s/gitui-%s.tar.gz" $repo $version $myArch)
2024-11-25 22:47:26 +00:00
"path" "./gitui"
2024-11-25 22:44:57 +00:00
"executable" true
"refreshPeriod" $defaultRefresh
) -}}
{{- end -}}
{{- end -}}
{{/*
# valid arch strings:
# darwin-amd64
# darwin-arm64
# freebsd-amd64
# freebsd-arm64
# linux-amd64
# linux-arm64
# openbsd-amd64
# openbsd-arm64
# windows-amd64
# windows-arm64
*/}}
{{- $myArch = (print .chezmoi.os "-" .chezmoi.arch) -}}
{{- with $repo := "Lifailon/lazyjournal" -}}
{{- with $version := (gitHubLatestRelease $repo).GetTagName -}}
{{- $_ := set $externals ".local/bin/lazyjournal" (dict
"type" "file"
"url" (printf "https://github.com/%s/releases/download/%s/lazyjournal-%s-%s" $repo $version $version $myArch)
"executable" true
"refreshPeriod" $defaultRefresh
) -}}
{{- end -}}
{{- end -}}
{{/*
# valid arch strings:
# Darwin_arm64
# Darwin_x86_64
# Linux_arm64
# Linux_i386
# Linux_x86_64
# Windows_arm64
# Windows_i386
# Windows_x86_64
*/}}
{{- $myArch = (printf "%s_%s" ( .chezmoi.os | title ) .sz.os.arch_alt) -}}
{{- with $repo := "theimpostor/osc" -}}
2024-12-24 20:53:54 +00:00
{{- with $version := (gitHubLatestRelease $repo).GetTagName -}}
{{- $_ := set $externals ".local/bin/osc" (dict
"type" "archive-file"
"url" (printf "https://github.com/%s/releases/download/%s/osc_%s.tar.gz" $repo $version $myArch)
"path" "osc"
2024-12-24 20:53:54 +00:00
"executable" true
"refreshPeriod" $defaultRefresh
) -}}
{{- end -}}
{{- end -}}
2024-12-24 20:53:54 +00:00
{{- $externals | toYaml }}
2024-09-19 04:31:48 +00:00
".config/sz.env/lib/ble.sh.curl":
type: "archive"
url: "https://github.com/akinomyoga/ble.sh/releases/download/nightly/ble-nightly.tar.xz"
refreshPeriod: "{{ $defaultRefresh }}"
2024-09-19 04:31:48 +00:00
".config/sz.env/lib/delta.themes.gitconfig":
type: "file"
url: "https://raw.githubusercontent.com/dandavison/delta/refs/heads/main/themes.gitconfig"
refreshPeriod: "{{ $defaultRefresh }}"
".config/sz.env/lib/bash-preexec/bash-preexec.sh":
type: "file"
url: "https://raw.githubusercontent.com/rcaloras/bash-preexec/master/bash-preexec.sh"
refreshPeriod: "{{ $defaultRefresh }}"
2024-11-25 22:47:51 +00:00
".local/bin/nvim.AppImage":
type: "file"
url: "https://github.com/neovim/neovim/releases/download/stable/nvim-linux-x86_64.appimage"
2024-11-25 22:47:51 +00:00
executable: true
refreshPeriod: "{{ $defaultRefresh }}"
{{- else -}}
# .chezmoiexternal is disabled because CZ_EXTR env is undefined
{{- end -}}