#20137 closed defect (othersoftware)
brew cask produce corrupted josm binary
| Reported by: | andygol | Owned by: | andygol |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | Installer MacOS | Version: | tested |
| Keywords: | macos homebrew cask | Cc: |
Description
One more attempt to upgrade JOSM with brew cask produced a corrupted JOSM binary for me again. (see prev ticket #19659)
➜ brew cask upgrade josm Warning: Calling brew cask upgrade is deprecated! Use brew upgrade --cask instead. ==> Upgrading 1 outdated package: josm 17013 -> 17329 ==> Upgrading josm ==> Caveats josm requires Java 8+. You can install the latest version with: brew cask install adoptopenjdk ==> Downloading https://josm.openstreetmap.de/download/macosx/josm-macosx-17329. Already downloaded: /Users/andygol/Library/Caches/Homebrew/downloads/7096dc4a9b9aa28a98c397f22f852a584bd841b5cc8a13c46d7ad605213cd016--josm-macosx-17329.zip ==> Backing App 'JOSM.app' up to '/usr/local/Caskroom/josm/17013/JOSM.app'. ==> Removing App '/Applications/JOSM.app'. unzip -o /Users/andygol/Library/Caches/Homebrew/downloads/7096dc4a9b9aa28a98c397f22f852a584bd841b5cc8a13c46d7ad605213cd016--josm-macosx-17329.zip -d /var/folders/r4/wnxtr9qn677csvrqyh6z8fzw0000gn/T/d20201123-34188-6avi9h cp -pR /var/folders/r4/wnxtr9qn677csvrqyh6z8fzw0000gn/T/d20201123-34188-6avi9h/LICENSE /usr/local/Caskroom/josm/17329/LICENSE cp -pR /var/folders/r4/wnxtr9qn677csvrqyh6z8fzw0000gn/T/d20201123-34188-6avi9h/README /usr/local/Caskroom/josm/17329/README cp -pR /var/folders/r4/wnxtr9qn677csvrqyh6z8fzw0000gn/T/d20201123-34188-6avi9h/JOSM.app/. /usr/local/Caskroom/josm/17329/JOSM.app cp -pR /var/folders/r4/wnxtr9qn677csvrqyh6z8fzw0000gn/T/d20201123-34188-6avi9h/CONTRIBUTION /usr/local/Caskroom/josm/17329/CONTRIBUTION chmod -Rf +w /var/folders/r4/wnxtr9qn677csvrqyh6z8fzw0000gn/T/d20201123-34188-6avi9h ==> Moving App 'JOSM.app' to '/Applications/JOSM.app'. ==> Purging files for version 17013 of Cask josm 🍺 josm was successfully upgraded!
The steps mentioned in https://josm.openstreetmap.de/wiki/Download?version=163#Macoserrors do not solve the issue.
Possible solution is to provide *.dmg along with *.zip (see #19803) and use *.dmg package to upgrade josm using brew.
Attachments (0)
Change History (9)
comment:1 by , 5 years ago
| Owner: | changed from to |
|---|---|
| Status: | assigned → needinfo |
comment:2 by , 5 years ago
| Component: | Core → Installer MacOS |
|---|
comment:3 by , 5 years ago
The brew cask should grab https://github.com/grischard/josm/releases/download/17329-tested/JOSM-macOS-java15.zip for this release.
comment:4 by , 5 years ago
The plan, once I reliably get github action to build releases, is to automate the Homebrew pull request:
comment:5 by , 5 years ago
| Keywords: | macos homebrew cask added |
|---|---|
| Resolution: | → othersoftware |
| Status: | needinfo → closed |
comment:6 by , 5 years ago
Is the cask you're using https://github.com/Homebrew/homebrew-cask/blob/master/Casks/josm.rb ? It doesn't mention 17329.
comment:7 by , 5 years ago
https://github.com/Homebrew/homebrew-cask/pull/93393 fixed homebrew cask.
The next release will hopefully be on openstreetmap/josm instead of grischard/josm, so once more a simple version bump won't work. It should be smooth sailing after that.
comment:8 by , 5 years ago
I've checked this new package and it works. But its size 89.2 Mb instead of 14 Mb for just bare app. Is there an option to have less duplicated pieces in the system?
➜ brew cask reinstall josm Warning: Calling brew cask reinstall is deprecated! Use brew reinstall instead. ==> Downloading https://github.com/grischard/josm/releases/download/17329-tested Already downloaded: /Users/andygol/Library/Caches/Homebrew/downloads/11b34c149870bab30175266f8eeee788d5aefb26cacc0abe3e481257bb8a1fe9--JOSM-macOS-java15.zip ==> Uninstalling Cask josm ==> Backing App 'JOSM.app' up to '/usr/local/Caskroom/josm/17329/JOSM.app'. ==> Removing App '/Applications/JOSM.app'. ==> Purging files for version 17329 of Cask josm ==> Installing Cask josm ==> Moving App 'JOSM.app' to '/Applications/JOSM.app'. 🍺 josm was successfully installed!
comment:9 by , 5 years ago
Yeah, if you want, you can always grab the .jar and run it manually with java -jar josm.jar. Grab it from my github, it's even smaller.
Jpackage doesn't support other ways of distributing the app, and most people don't have a full java environment on their Mac these days. By including just a subset, it will save space for the majority of people.
If space on your Mac is tight, you can try compressing stuff with https://github.com/RJVB/afsctool. It works really well on the junk in my Downloads folder, for example.
Finally, to put things into perspective, Apple currently charges $0.80 per GB for SSD storage on new Macs. The space taken by the bundled JRE in JOSM.app costs a bit more than half a cent. JOSM.app takes less space than just the Electron framework in Javascript apps.



Please report this to the people who maintain brew cask, we don't.