Merge pull request #154680 from dev-alnasl/hhkb-keymap-tool

Add HHKB Keymap Tool v1.3.0
This commit is contained in:
Miccal Matthews 2023-09-09 14:01:36 +08:00 committed by GitHub
commit 152e496593
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 38 additions and 0 deletions

38
Casks/h/hhkb.rb Normal file
View File

@ -0,0 +1,38 @@
cask "hhkb" do
version "1.3.0"
sha256 "ad9bad341ebf6a189b907b0dd5ee68627d508664335ea75e0109964a25d268f9"
url "https://origin.pfultd.com/downloads/hhkb/mac/HHKBkeymapTool_#{version.no_dots}ma.dmg",
verified: "origin.pfultd.com/downloads/hhkb/mac/"
name "Happy Hacking Keyboard Keymap Tool"
desc "Allows keymap customization on HHKB HYBRID Type-S and HYBRID models"
homepage "https://happyhackingkb.com/"
livecheck do
url "https://happyhackingkb.com/download/"
regex(/macOS\s+:\s+Version\s+(\d+(?:\.\d+)+)/i)
end
depends_on macos: ">= :mojave"
pkg "HHKBkeymapTool_#{version.no_dots}ma.pkg"
uninstall pkgutil: "jp.co.pfu.hhkb-keymap-tool.pkg.V#{version}",
quit: "jp.co.pfu.hhkb-keymap-tool",
delete: [
"#{appdir}/hhkb-keymap-tool*",
"#{appdir}/HHKB/EULA_*.rtf",
"#{appdir}/HHKB/OSS_License.txt",
],
rmdir: "#{appdir}/HHKB"
zap trash: [
"~/Library/Application Support/hhkb-keymap-tool/*.log",
"~/Library/Preferences/jp.co.pfu.hhkb-keymap-tool.plist",
],
rmdir: "~/Library/Application Support/hhkb-keymap-tool"
caveats do
requires_rosetta
end
end