-
Notifications
You must be signed in to change notification settings - Fork 158
Open
Description
The sample Github Actions workflow will clobber your existing Github Release far too easily if you let it. This means you'll publish a potentially broken version of your plugin to the latest release, which breaks for anyone who tries to install it.
The docs: https://www.flowlauncher.com/docs/#/py-setup-project?id=_1-add-github-workflow
Recommend using this workflow: https://github.com/Flow-Launcher/Flow.Launcher.Plugin.HelloWorldPython/blob/main/.github/workflows/Publish%20Release.yml
The problem is, it runs for every push to main
, including the commit immediately after you published a new version. Imagine this scenario:
- Change version number in
plugin.json
to1.0.0
- Commit,
git tag v1.0.0
, andgit push --tags
- Workflow runs, reads version from plugin.json, builds, uploads zip to newly-created Release 1.0.0
- Start working on new features for v2
git commit -m 'WIP new features, kinda works, breaks sometimes' && git push
- Workflow runs again! This is bad
- Workflow runs, reads version from plugin.json -- is still 1.0.0 -- builds, overwrites zip on Release 1.0.0!
Now, when someone tries to install 1.0.0 of the plugin, they will download a broken version with "WIP new feature" code.
Metadata
Metadata
Assignees
Labels
No labels