[HN Gopher] Sparkle: A software update framework for macOS
___________________________________________________________________
Sparkle: A software update framework for macOS
Author : nateb2022
Score : 179 points
Date : 2024-02-13 12:31 UTC (10 hours ago)
(HTM) web link (github.com)
(TXT) w3m dump (github.com)
| ThePowerOfFuet wrote:
| The one and only. Everything else is garbage in comparison.
| dewey wrote:
| Maybe I'm weird, but for some reason seeing a Sparkle ,,Update
| available" modal popping up fils me with joy (The software I'm
| using is getting better) and I enjoy reading the changelog. If
| there's some weird custom updater in another software it always
| fills me with dread because I have to navigate a different UI,
| and probably have to restart it immediately.
| wingerlang wrote:
| I don't think that's weird, I enjoy those as well. So much so
| that I have a newsletter where I post changelogs of various
| apps that had updates in the past week
| (https://buttondown.email/appsandupdates). Adding apps is a
| slow process but I'm starting to see quite a bit of repeated
| apps so I'll have to speed it up.
| adamomada wrote:
| The modal popup is the single thing I can't stand about sparkle
| updates. Why oh why can't they use the regular notification
| system and respect DND. It always seems so random as well, it's
| not when the application starts or quits, just some rando timer
| polling for updates to surprise me with an interruption I can't
| ignore
| watk wrote:
| This looks great. What would be the equivalent of this on
| Windows? It feels like everyone just invents their own.
| jhfdbkofdchk wrote:
| Well, someone made something inspired by Sparkle for Windows,
| https://winsparkle.org
| usrusr wrote:
| On Windows, chances are that once you have a working installer
| you will be so deeply stockholmed that the idea that updates
| might go any other way than through a future incarnation of
| that installer is completely alien to you.
|
| That being said, I think the way sparkle (and winsparkle, see
| sibling) present themselves looks delightfully NSIS (the good
| parts)
| marcellus23 wrote:
| There's a version of Sparkle for Windows. I have no idea why
| apps don't adopt it.
|
| I am constantly amazed and frustrated at how many apps I use on
| Windows have the following update process:
|
| 1. Pops up an alert telling me an update is available
|
| 2. I click a link in the alert opening my browser, taking me to
| a webpage full of links for different OSes and different
| architectures, which I have to search through to find Windows
| Intel x64
|
| 3. Wait to download the new version and then open it up
|
| 4. Spend 30 seconds clicking through a Windows Installer
|
| Absolutely bonkers, especially considering some of these apps
| seem to release on an agile biweekly schedule. I usually
| procrastinate downloading updates because it's such a pain in
| the ass -- and that's not what you want your users to be doing.
| daveoc64 wrote:
| I tried looking for something like Sparkle on Windows a few
| weeks ago.
|
| Now I know it exists - thanks!
| accoil wrote:
| I sometimes see Squirrel[^1] used in Windows apps. Looks like
| it's used by Electron[^2], so maybe that's why.
|
| [1]:
| https://github.com/Squirrel/Squirrel.Windows/tree/develop/do...
|
| [2]:
| https://github.com/electron/electron/blob/main/docs/api/auto...
| marwis wrote:
| MSIX + scheduled task is the way
|
| https://learn.microsoft.com/en-us/windows/msix/non-store-dev...
|
| Or just publish to MS Store and/or winget.
| Deadpikle wrote:
| Along with some of the other comments, there is NetSparkle for
| C#-based apps that is cross platform:
| https://github.com/NetSparkleUpdater/NetSparkle (disclaimer: I
| am the primary maintainer of this repository).
| prmoustache wrote:
| Are you telling me macOS doesn't have a package manager already?
| pantulis wrote:
| In terms of apps no, it doesn't or basically it is the Mac App
| Store. You basically publish your app with all the dependencies
| and target a specific OS version which guarantees certain
| baseline frameworks. Apart from that, any update means
| publishing a new version to the App Store (if you are there).
| If you are self hosting the app, you need something like
| Sparkle to trigger app updates.
|
| In terms of proper package management a la yum or apt, there is
| homebrew of course.
| prmoustache wrote:
| OK so basically the point is to avoid Mac App Store fees and
| independence to third party project like homebrew.
|
| Doesn't that leads to the situation on windows where every
| single app is phoning home at startup?
| masklinn wrote:
| Well the original point is that sparkle predates MAS by
| more than a decade, and the MAS limitations are a bigger
| issue than the fees.
|
| > Doesn't that leads to the situation on windows where
| every single app is phoning home at startup?
|
| Sparkle has a very clear and regular behaviour, its
| predictability and widespread use made it easy to manage.
| madeofpalk wrote:
| As a more technical user who is aware of Sparkle, I
| recognise the Sparkle updater and I appreciate it. In
| fact, I miss this on Windows, where each app updates
| differently, and most will just throw you annoyingly to
| the install wizard all over again.
| steve1977 wrote:
| To be fair, Windows Installer can also handle updates
| (and patches). And proper uninstallation, which is
| something that's missing on macOS.
| prmoustache wrote:
| Thanks for the history lesson.
| Hamuko wrote:
| Sparkle automatically limits update checking to once per 24
| hours if that makes you feel any better.
| lapcat wrote:
| > Doesn't that leads to the situation on windows where
| every single app is phoning home at startup?
|
| 1) It's a setting/preference. The polite/respectful app
| developers will ask users whether they want to
| automatically check for updates.
|
| 2) It's periodic. Developers can set the default to
| whatever they prefer -- daily, weekly, monthly, etc. -- and
| again the polite developers may give the user an option
| here too.
| alkonaut wrote:
| Usually the point of "software update frameworks" is to
| make the app phone home and check if there is an update
| isn't it?
|
| I mean you can have an option to not make it check for
| updates if you want to provide a privacy option for people,
| but that just makes it a manual click-to-check-for-updates.
| Most people would probably leave the "check for updates on
| start" checked.
|
| Can't see how that's a difference based on what OS you are
| on? I use Squirrel/Velopack (the equivalent for Windows I
| guess) and the usual way of managing updates is to have an
| update check at startup, or an interval (e.g. every hour).
| destitude wrote:
| It's just downloading an xml file to see if there is an
| update available.
| masklinn wrote:
| And talking about "XML file" is obscuring it, an
| "appcast" feed is an RSS feed with a few extensions.
| prmoustache wrote:
| >Can't see how that's a difference based on what OS you
| are on?
|
| I have been a linux and openbsd user for the most part of
| the last 3 decades with only short stints on windows in a
| professionnal setting or when fixing up my partner's
| issues and nearly 0 experience of macOS apart from
| launching it in a VM out of curiosity 3 times so I was
| genuinely surprised and not aware of potential
| restrictions of app store. I know on windows there is the
| microsoft store + chocolatey that can handle apps updates
| (and possibly other projects?).
|
| I have had the occasionnal java app installed in /opt
| from a tarball or an appimage but for me apps
| individually phoning home is more the exception than the
| norm. I usually have one process connecting to n repos, n
| being less than 5 usually and usually only when I am
| querying it manually. In recent years on Fedora I've let
| gnome software app connecring automatically and I guess
| with some flatpaks installed I am querying 2 flatpak
| repos (fedora +flathub) more but that's about it and most
| of our distro packages have telemetry and users counts
| disabled.
| j16sdiz wrote:
| macOS app store mandates apps sandbox. If your app, for
| some reason, don't run in sandbox, you need to distribute
| it outside app store.
| pantulis wrote:
| You are correct. That's why Sparkle is still relevant these
| days and of course it requires the app to phone home.
|
| Interesting things could happen with third party App Stores
| if they ever see the light in macOS.
| madeofpalk wrote:
| What do you mean? There's already third party app stores
| on macOS. Steam and all the other gaming ones. Setapp is
| a more non-gaming one.
| bluish29 wrote:
| Many open source (and even proprietary apps) apps get
| published using homebrew casks [1]. Although they usually use
| that as supplementary method. And sometimes it is done by
| volunteers.
|
| [1] https://formulae.brew.sh/cask/
| haykuro wrote:
| I switched to MacPorts after becoming tired of Brew tainting
| my filesystem.
|
| MacPorts keeps things clean in /opt/.
|
| https://www.macports.org/
|
| https://saagarjha.com/blog/2019/04/26/thoughts-on-macos-
| pack...
| stadeschuldt wrote:
| Nowadays Homebrew keeps its stuff under /opt/homebrew/
| Hamuko wrote:
| Only if you have an ARM64 Mac. x86 still use the old
| path.
| jwells89 wrote:
| I used MacPorts back in the 00s and early 10s but switched
| to Homebrew when it came out because it was less hassle.
|
| Wanted to give it another shot with my latest clean OS
| install, but wound up installing Homebrew again due to
| broken packages on MacPorts. Probably should've tried to
| contribute by fixing those packages but didn't have the
| time or mental energy available at that point in time.
| TheAceOfHearts wrote:
| You can use homebrew to install regular apps as well, thanks
| to the casks feature. There's probably some apps that aren't
| available as casks, but usually everything I need is
| available already.
| zitterbewegung wrote:
| Mac classic had full compiled applications that you would drag
| to your applications folder. This is the same when it's
| distributed by dmg and told you are to drag to the Applications
| folder and using Sparkle on this is a common method to update
| or to just give another dmg. Another way you can distribute
| your app is to use a dmg to with a pkg file in it and this
| launches an installation wizard very similar to what you would
| see on windows. Then there is homebrew that has a series of
| ruby formulas that can do nearly all of the above. Obviously
| there is the Mac App Store.
| bni wrote:
| Thankfully, it doesn't
| anbotero wrote:
| Not officially, but these days first things I setup in
| Onboarding documents (if they don't have it already) is how to
| setup Homebrew.
|
| I install pretty much everything I need on macOS through
| Homebrew these days.
| api wrote:
| It has Homebrew, which many people use and is great. It also
| has its App Store but nobody uses it for anything non-trivial
| because it's so jailed.
| favorited wrote:
| > nobody uses it for anything non-trivial
|
| I guess the Microsoft Office suite, LibreOffice, Adobe
| Lightroom, Pixelmator, Sketch, OmniGraffle, etc. are trivial?
| Hamuko wrote:
| I've had to implement Sparkle once in a macOS app and it was
| actually quite simple. It also doesn't really take much more than
| an S3 bucket to facilitate updates. And as a user, it's a great
| user experience that updates are handled in a similar manner in
| almost all of the apps that I install.
|
| Great piece of software.
| Y-bar wrote:
| As a consumer of Mac OS software thank you! Seeing a Sparkle
| dialogue is such a nicety and it makes me feel good.
| fifafu wrote:
| I have been using Sparkle in my apps for almost 15 years now (for
| millions of updates). It has always worked perfectly well for me.
| Really great project and still very active.
| systemz wrote:
| I instantly recognized screenshot in README.md Thanks to this
| thread I now know name of software that helps bring updates to a
| lot of apps I use daily.
|
| Big kudos to all contributors of Sparkle, you all make our lives
| easier!
| sgottit wrote:
| huge fan and user of Sparkle. a while back I wrote a wrapper
| around it for automatically creating a changelog, signing
| software etc and its worked perfectly for years
| https://replay.software/bump
| TheAceOfHearts wrote:
| Nowadays I just run `brew update; brew upgrade` and everything
| gets updated, including casks.
| Brajeshwar wrote:
| You might want to cleanup and call the doctor just in case. :-)
| brew update; brew upgrade; brew cleanup; brew doctor
| jshier wrote:
| And no need for `brew update` unless you've turned automatic
| updates off.
| anbotero wrote:
| It has a timeframe, though, so while it does automatically
| update every so often, it's not every time you run
| `upgrade` or `install`, so running the `brew update` makes
| sure your OCD matches your needs.
| anbotero wrote:
| Similar, just without the `doctor`. That one I only run it
| like once a month. For the other one, I got my alias, haha:
| buuc
| bartekpacia wrote:
| I always do:
|
| brew update && brew upgrade && brew cleanup && brew
| autoremove
| belthesar wrote:
| For us technology slinging types, homebrew is indeed great.
| Sparkle updates are indeed fantastic for the average user
| however. I think I'd be interested in learning how many average
| users install software outside of the Mac App Store these days.
| hbn wrote:
| > I'd be interested in learning how many average users
| install software outside of the Mac App Store these days.
|
| I'd hazard a guess that Chrome alone would put that figure
| near 100%
| _joel wrote:
| I think you underestimate how many people use Safari.
| bandergirl wrote:
| Nowhere near as how many people use Chrome obviously,
| even on Mac.
| gzer0 wrote:
| Data from analytics.usa.gov [1] reveals that Chrome leads
| browser usage at 48%, closely followed by Safari at
| 35.7%, highlighting the competitive proximity of Safari
| to Chrome. Definitely much higher share than I thought.
|
| [1] https://analytics.usa.gov/
| hbn wrote:
| Those would almost entirely be from iPhones where all
| browsers are technically Safari
| philistine wrote:
| Homebrew has statistics. They're high for the usual suspects,
| very low for everything else.
| ehutch79 wrote:
| Real question; do you expect most, half, or even a quarter of
| MacOS users are going to be installing things through brew?
| cqqxo4zV46cp wrote:
| Even 1%
| Amorymeltzer wrote:
| Notably, many cask formulae use Sparkle as the livecheck
| mechanism that is used to find updates to casks.
| snorremd wrote:
| Exactly. It is so simple to do `brew install figma` or whatever
| App you want. Most bigger apps have ready casks to install.
| Then I have a startup job that does `brew bundle dump --file=-
| > $ICLOUD/Brewfile`. That way I get a backup list of all
| software installed with brew so it is simple to install again
| if I migrate to a new machine (without restoring a Time Machine
| backup).
|
| Edit: Obviously for users not familiar with command line
| programs brew isn't that "easy". But for command line people
| this setup is quite nice.
| zacte wrote:
| Raycast has an excellent extension to manage brew installs
| and upgrades without any cli on macs
| longnguyen wrote:
| Sparkles is a godsend. I use it on all my indie apps and it saves
| so much time. The best part is I could release with confidence
| knowing that I don't have to ask for AppStore Review for each
| release.
|
| The new version with delta updates and flags for critical updates
| is amazing. 10/10
| graemep wrote:
| Thanks for that. As someone who is not a Mac user, let alone a
| developer, was wondering why it is useful given app stores
| exist.
| daniel_sim wrote:
| as a user, I have always loved when apps use sparkle.
| stevoski wrote:
| This makes me somewhat nostalgic for the days when I would
| regularly encounter software that used Sparkle for updates.
|
| The days when I'd mostly use downloadable native software for my
| Mac.
|
| The days when most of the software I regularly used had a
| somewhat consistent UX.
| whalesalad wrote:
| I miss Adium.
| kergonath wrote:
| Indeed. That thing was a gem.
| Angostura wrote:
| I miss the world in which software like Adium was possible
| eddieroger wrote:
| So do I, so often. I made an Adiumy animation pack for my
| university that actually got mildly popular, and it was
| amazing. Such a quality app, and so nice when communication
| systems were standards not apps.
| malermeister wrote:
| Well, they weren't really standards by design either,
| people just reverse engineered their protocols. One could
| still do that, it's just that... nobody does anymore?
| mrweasel wrote:
| Looking at the git repo, seeing the last commit being three
| years old is a bit sad. Someone sat down one day created a
| patch and committed it, and then they went away, to work on
| other things, leaving the git repository in a digital limbo.
| incanus77 wrote:
| I used to author two indie Mac apps ~15 years ago, right around
| when Sparkle came out. It was a joy to add to my projects, a
| model to learn about great Cocoa framework programming, and still
| is always pleasant for me as a user. Huge independent success
| story on the Mac.
| brainzap wrote:
| I once made a fork of it that used github releases for updates, I
| wonder if I still have it.
| tomovo wrote:
| That would be interesting. I wonder if it could be used with an
| internal Gitea instance too?
| hermitcrab wrote:
| I write software for Mac and Windows (in C++/Qt). I put each new
| release out as a separate application for the user to install. Is
| there some equivalent to Sparkle that runs on both Mac AND
| Windows, so I don't have to integrate a separate system on each
| OS?
|
| Also I worry about update frameworks as way for bad guys to do
| bad things via my software. Should I be worried?
| hermitcrab wrote:
| Ah, I see https://winsparkle.org/ is a thing.
| gwbas1c wrote:
| Windows installation system is so fundamentally different that
| it's hard to have a 1-size-fits-all update mechanism. When I
| shipped a cross-platform application, we used Sparkle on Mac,
| and a simple utility that downloaded and ran an MSI file for
| Windows.
|
| In general, I wouldn't worry too much about Sparkle being a
| vulnerability. It requires that your download servers are
| hacked: https://9to5mac.com/2017/05/08/handbrake-trojan-mac-
| malware-...
| hermitcrab wrote:
| Currently I used Inno Setup to create a .exe installer on
| Windows and DropDMG to create a .dmg image on Mac.
|
| Presumably Sparkle and Winsparkle both use a similar update
| mechanism and that doesn't involve full Windows or Mac
| installers (otherwise, what would be the point?).
| gwbas1c wrote:
| Sparkle works with a .dmg file, so you'd probably continue
| using DropDMG.
|
| I can't speak much for Winsparkle; I remember looking at it
| and immediately concluding that it wouldn't work for us.
|
| (FWIW: I ended up slipping in a few hacks so we could pop
| open browser windows on specific versions and commits, and
| even remotely kill them if needed.)
| Deadpikle wrote:
| There is one that is .NET and cross platform (incl. Linux)
| here: https://github.com/NetSparkleUpdater/NetSparkle
| (disclaimer: I am the primary maintainer of this repository).
|
| For C++, WinSparkle works too:
| https://github.com/vslavik/winsparkle/
| leovander wrote:
| Here's someone's write up on setting it up in their application.
| I think I found this in a previous thread about Sparkle.
|
| https://troz.net/post/2023/sparkle/
| apple4ever wrote:
| Love Sparkle! Both as a user and a developer of apps (I'd never
| sell in the Mac App Store due to Apple's consumer unfriendly
| policies). It works so well and is so easy to setup.
| markx2 wrote:
| Caused me to remember Growl
|
| https://growl.github.io/growl/
___________________________________________________________________
(page generated 2024-02-13 23:01 UTC)