Skip to content
This repository has been archived by the owner on Dec 25, 2024. It is now read-only.

Commit

Permalink
feat: add zap appimage package manager for studio-manager
Browse files Browse the repository at this point in the history
  • Loading branch information
tulilirockz committed Apr 25, 2024
1 parent 02b58f6 commit 82dc12a
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion config/scripts/extra-packages.nu
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,18 @@ use lib/std.nu [get_arch, fetch_generic]

const BREW_TARGET = "/usr/libexec/brew-install"
let ARCH = (get_arch)
let ARCH_ZAP = "amd64"

http get "https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh" | save -f "$BREW_TARGET"
run-external chmod '+x' "$BREW_TARGET"
run-external chmod '+x' $BREW_TARGET

let GUM_LATEST = (http get https://api.github.com/repos/charmbracelet/gum/releases/latest | get assets | where {|e| $e.name | str ends-with $"($ARCH).rpm" } | get browser_download_url).0
let GUM_RPM = (fetch_generic $GUM_LATEST ".rpm")
run-external rpm-ostree install $GUM_RPM
rm -f $GUM_RPM

let ZAP_TARGET = "/usr/bin/zap"
let ZAP_LATEST = (http get https://api.github.com/repos/srevinsaju/zap/releases/latest | get assets | where {|e| $e.name | str ends-with $"($ARCH_ZAP)" } | get browser_download_url).0
let ZAP_BIN = (fetch_generic $ZAP_LATEST "")
mv $ZAP_BIN $ZAP_TARGET
run-external chmod '+x' $ZAP_TARGET

0 comments on commit 82dc12a

Please sign in to comment.