A few fixes and additions

cargo-binstall added - will use this for darwin-less rust based binaries
complete-alias script added to chezmoiexternal and loaded into shell
fixed arch detection chezmoi code
This commit is contained in:
Lockszmith (@VAST) 2025-04-09 16:23:45 -04:00
parent af318fe8c2
commit b40817b8b8
2 changed files with 20 additions and 3 deletions

View File

@ -14,8 +14,8 @@
{{- $sysVendor := "unknown" }}
{{- $clib_flavor := "" }}
{{- if eq .chezmoi.os "darwin" }}
{{- $arch_alt := "aarch64" }}
{{- $arch_alt_dash := $arch_alt }}
{{- $arch_alt = "aarch64" }}
{{- $arch_alt_dash = $arch_alt }}
{{- $sysType = "macos" }}
{{- $sysVendor = "apple" }}
{{- if contains "BatteryData" (output "ioreg" "-c" "AppleSmartBattery") }}

View File

@ -76,6 +76,18 @@
"refreshPeriod" $defaultRefresh
) -}}{{- end -}}{{- end -}}{{- end -}}
{{- with $app_name := "cargo-binstall" -}}
{{- with $repo := (printf "%s/%s" "cargo-bins" $app_name) -}}
{{- with $version := (gitHubLatestRelease $repo).GetTagName -}}
{{- with $archive_type := "zip" -}}
{{- $_ := set $externals (printf ".local/bin/%s" $app_name) (dict
"type" "archive-file"
"url" (printf "https://github.com/%s/releases/download/%s/%s-%s.full.%s" $repo $version $app_name $myArch $archive_type)
"path" $app_name
"executable" true
"refreshPeriod" $defaultRefresh
) -}}{{- end -}}{{- end -}}{{- end -}}{{- end -}}
{{- if (eq .chezmoi.os "linux") -}}
{{- with $app_name := "vivid" -}}
{{- with $repo := (printf "%s/%s" "sharkdp" $app_name) -}}
@ -212,7 +224,7 @@
# Windows_i386
# Windows_x86_64
*/}}
{{- $myArch = (printf "%s_%s" ( .chezmoi.os | title ) .sz.os.arch_alt) -}}
{{- $myArch = (printf "%s_%s" ( .chezmoi.os | title ) .chezmoi.arch) -}}
{{- with $app_name := "osc" -}}
{{- with $repo := (printf "%s/%s" "theimpostor" $app_name) -}}
@ -264,6 +276,11 @@
url: "https://raw.githubusercontent.com/rcaloras/bash-preexec/master/bash-preexec.sh"
refreshPeriod: "{{ $defaultRefresh }}"
".config/sz.env/lib/complete-alias":
type: "file"
url: "https://github.com/cykerway/complete-alias/raw/refs/heads/master/complete_alias"
refreshPeriod: "{{ $defaultRefresh }}"
{{ if (and ( eq .chezmoi.os "linux" ) ( ne .chezmoi.osRelease.id "centos" )) -}}
".local/bin/nvim.AppImage":
type: "file"