mirror of
https://github.com/kovidgoyal/kitty.git
synced 2026-10-21 04:32:05 +00:00
Fix #7741
This commit is contained in:
parent
9ba34941e5
commit
7c4977146f
1 changed files with 9 additions and 5 deletions
|
|
@ -126,20 +126,24 @@ download_installer() {
|
|||
}
|
||||
}
|
||||
|
||||
ensure_dest() {
|
||||
printf "%s\n" "Installing to $dest"
|
||||
command rm -rf "$dest" || die "Failed to delete $dest"
|
||||
command mkdir -p "$dest" || die "Failed to mkdir -p $dest"
|
||||
command rm -rf "$dest" || die "Failed to delete $dest"
|
||||
}
|
||||
|
||||
linux_install() {
|
||||
command mkdir "$tdir/mp"
|
||||
command tar -C "$tdir/mp" "-xJof" "$installer" || die "Failed to extract kitty tarball"
|
||||
printf "%s\n" "Installing to $dest"
|
||||
command rm -rf "$dest" || die "Failed to delete $dest"
|
||||
ensure_dest
|
||||
command mv "$tdir/mp" "$dest" || die "Failed to move kitty.app to $dest"
|
||||
}
|
||||
|
||||
macos_install() {
|
||||
command mkdir "$tdir/mp"
|
||||
command hdiutil attach "$installer" "-mountpoint" "$tdir/mp" || die "Failed to mount kitty.dmg"
|
||||
printf "%s\n" "Installing to $dest"
|
||||
command rm -rf "$dest"
|
||||
command mkdir -p "$dest" || die "Failed to create the directory: $dest"
|
||||
ensure_dest
|
||||
command ditto -v "$tdir/mp/kitty.app" "$dest"
|
||||
rc="$?"
|
||||
command hdiutil detach "$tdir/mp"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue