-
-
Notifications
You must be signed in to change notification settings - Fork 10.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #196575 from Homebrew/add-ghostty@tip
- Loading branch information
Showing
1 changed file
with
49 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
cask "ghostty@tip" do | ||
version "8481,a8e5eef11cc67f87f445626f9ca2993373774bf8" | ||
sha256 "48b3d6f68c3b6f0774d91532efb5eca9f66ea4d75129ec89cff41bd246b7974f" | ||
|
||
url "https://tip.files.ghostty.org/#{version.csv.second}/Ghostty.dmg" | ||
name "Ghostty" | ||
desc "Terminal emulator that uses platform-native UI and GPU acceleration" | ||
homepage "https://ghostty.org/" | ||
|
||
livecheck do | ||
url "https://tip.files.ghostty.org/appcast.xml" | ||
regex(%r{/(\h+)/Ghostty\.dmg}i) | ||
strategy :sparkle do |item, regex| | ||
match = item.url&.match(regex) | ||
next if match.blank? | ||
|
||
"#{item.version},#{match[1]}" | ||
end | ||
end | ||
|
||
auto_updates true | ||
conflicts_with cask: "ghostty" | ||
depends_on macos: ">= :ventura" | ||
|
||
app "Ghostty.app" | ||
binary "#{appdir}/Ghostty.app/Contents/MacOS/ghostty" | ||
binary "#{appdir}/Ghostty.app/Contents/Resources/bash-completion/completions/ghostty.bash", | ||
target: "#{HOMEBREW_PREFIX}/etc/bash_completion.d/ghostty" | ||
binary "#{appdir}/Ghostty.app/Contents/Resources/fish/vendor_completions.d/ghostty.fish", | ||
target: "#{HOMEBREW_PREFIX}/share/fish/vendor_completions.d/ghostty.fish" | ||
binary "#{appdir}/Ghostty.app/Contents/Resources/zsh/site-functions/_ghostty", | ||
target: "#{HOMEBREW_PREFIX}/share/zsh/site-functions/_ghostty" | ||
binary "#{appdir}/Ghostty.app/Contents/Resources/terminfo/67/ghostty", | ||
target: "#{ENV.fetch("TERMINFO", "~/.terminfo")}/67/ghostty" | ||
binary "#{appdir}/Ghostty.app/Contents/Resources/terminfo/78/xterm-ghostty", | ||
target: "#{ENV.fetch("TERMINFO", "~/.terminfo")}/78/xterm-ghostty" | ||
manpage "#{appdir}/Ghostty.app/Contents/Resources/man/man1/ghostty.1" | ||
manpage "#{appdir}/Ghostty.app/Contents/Resources/man/man5/ghostty.5" | ||
|
||
zap trash: [ | ||
"~/.config/ghostty/", | ||
"~/Library/Application Support/com.mitchellh.ghostty", | ||
"~/Library/Caches/com.mitchellh.ghostty", | ||
"~/Library/HTTPStorages/com.mitchellh.ghostty", | ||
"~/Library/Preferences/com.mitchellh.ghostty.plist", | ||
"~/Library/Saved Application State/com.mitchellh.ghostty.savedState", | ||
"~/Library/WebKit/com.mitchellh.ghostty", | ||
] | ||
end |