Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 15 additions & 1 deletion .github/workflows/publish-packages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -173,4 +173,18 @@ jobs:
SNAP_FILE="${snaps[0]}"

gh release upload "$TAG" "$SNAP_FILE" --clobber
snapcraft push "$SNAP_FILE" --release stable

# `upload`, not `push`. snapcraft 8 turned the old name into a hard
# error -- "The 'push' command was renamed to 'upload'", exit 64 --
# and the step above installs whatever `snap install snapcraft
# --classic` currently serves, so the command this line calls stopped
# existing without a commit here.
#
# It last worked on 2026-06-03: markpad 2.6.11, revision 15, which is
# still what the Snap Store serves. Every run after that died earlier,
# in the build, and the swallowing this workflow's header describes
# reported it as success. #561 removed that and #577/#579 fixed the
# build, so v2.7.4 was the first release to reach this line -- and it
# failed here, in run 31775835301, after packing
# markpad_2.7.4_amd64.snap green.
snapcraft upload "$SNAP_FILE" --release stable
14 changes: 11 additions & 3 deletions scripts/releaseWorkflow.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -273,10 +273,18 @@ test('a package manager is not published from inside the platform matrix', () =>
// Matched on the push commands rather than on step names, because the
// property is "the build matrix has no irreversible external effect", and a
// renamed step would still have one.
//
// `snapcraft upload` was `snapcraft push` here until snapcraft 8 removed
// that name. Worth being honest about what this assertion is: it pins the
// string the workflow uses, so it went on passing for the whole time the
// command it named did not exist. Nothing runnable from `npm test` can
// check the other half -- the tool is installed by the job, from the store,
// at release time. See publish-packages.yml.
assert.doesNotMatch(workflow, /snapcraft (pack|push|upload)/);
assert.doesNotMatch(workflow, /choco push/);
assert.doesNotMatch(workflow, /snapcraft (pack|push)/);
assert.match(publishWorkflow, /choco push/);
assert.match(publishWorkflow, /snapcraft push/);
assert.match(publishWorkflow, /snapcraft upload/);
assert.doesNotMatch(publishWorkflow, /snapcraft push/);
});

test('package managers are published from a release a human published', () => {
Expand Down Expand Up @@ -418,7 +426,7 @@ test('the package managers we recommend are the ones we publish to', () => {
const releaseBody = sliceBetween(workflow, "echo '## Download'", 'RELEASE_BODY');
for (const [name, install, push] of [
['Chocolatey', /choco install markpad-app/, /choco push/],
['Snap', /snap install markpad/, /snapcraft push/],
['Snap', /snap install markpad/, /snapcraft upload/],
] as const) {
const publishes = push.test(publishWorkflow);
assert.equal(
Expand Down
7 changes: 7 additions & 0 deletions snapcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ website: https://markpad.sftwr.dev
donation: https://github.com/sponsors/alecdotdev
source-code: https://github.com/sftwrdotdev/Markpad
issues: https://github.com/sftwrdotdev/Markpad/issues
contact: https://github.com/sftwrdotdev/Markpad/issues

confinement: strict
base: core24
Expand All @@ -44,6 +45,12 @@ apps:
- network-bind
- wayland
- home
# `home` reaches $HOME and nothing else, so a note kept on a USB stick or
# a second-drive mount is invisible to the app, with no way for the user
# to grant it. This does not auto-connect -- it takes one
# `sudo snap connect markpad:removable-media` -- but without the plug
# declared here there is nothing to connect. #562.
- removable-media

parts:
# The snap packages the .deb the release already shipped. It does not build
Expand Down
Loading