Skip to content

Free, open-source 3D sculpting for Linux, macOS and Windows: dense meshes, remeshing, painting, built-in AI (image/text to 3D), Send to Unreal, game-ready LODs, Gaussian splats and OpenUSD.

Merge feat/one-click-update 12a89aee: one-click update (signed SHA256SUMS), member builds

islandmedffd35d07e254
diff --cc .github/workflows/release.yml
index acf54601,445d3d78..e740f6b8
--- a/.github/workflows/release.yml
+++ b/.github/workflows/release.yml
@@@ -273,75 -271,29 +273,83 @@@ jobs
run: python3 -m zipfile -c dist/sculptforge_maya.zip integrations/maya/sculptforge_maya.py integrations/maya/README.md
- name: Checksums
run: cd dist && sha256sum * > SHA256SUMS.txt && cat SHA256SUMS.txt
+ - name: Sign the checksums (one-click update checks SHA256SUMS.txt.sig, src/core/SelfUpdate.h)
+ env:
+ UPDATE_SIGNING_KEY: ${{ secrets.UPDATE_SIGNING_KEY }}
+ run: tools/release/sign_sums.sh dist
- name: Release notes from CHANGELOG
run: |
- section=${TAG#v}
- if [[ "$TAG" == *-* ]]; then # a beta: what has changed since the stable release
- section=Unreleased
- printf '%s\n\n' "**Beta for testers.** Please report problems in the Discord's #bug-reports (or a GitHub issue) with your OS, this version (Help > About) and your graphics card. Preferences > Updates > Update channel: Preview offers the next betas." > notes.md
- fi
- awk -v h="## [$section]" 'index($0, h) == 1 {flag=1;next} /^## \[/{flag=0} flag' CHANGELOG.md >> notes.md
+ awk -v h="## [${TAG#v}]" 'index($0, h) == 1 {flag=1;next} /^## \[/{flag=0} flag' CHANGELOG.md > notes.md
cat packaging/release-notes-footer.md >> notes.md
- name: Create or update the release
env:
GH_TOKEN: ${{ github.token }}
run: |
- if [[ "$TAG" == *-* ]]; then # v0.11.0-beta.1: "SculptForge 0.11.0 Beta 1", a pre-release, not latest
- pre=${TAG#*-}
- title="SculptForge ${TAG%%-*} $(sed -E 's/^rc/RC/; s/^./\U&/; s/\./ /g' <<<"$pre")"
- gh release view "$TAG" >/dev/null 2>&1 ||
- gh release create "$TAG" --title "${title/SculptForge v/SculptForge }" --notes-file notes.md --prerelease --latest=false
- else
- gh release view "$TAG" >/dev/null 2>&1 || gh release create "$TAG" --title "SculptForge ${TAG#v}" --notes-file notes.md
- fi
+ gh release view "$TAG" >/dev/null 2>&1 || gh release create "$TAG" --title "SculptForge ${TAG#v}" --notes-file notes.md
+ gh release upload "$TAG" dist/* --clobber
+
+ # A beta (a tag with a '-') is a member perk, published only in the private repository islandmed/sculptforge-insiders.
+ # INSIDERS_REPO_TOKEN lives only in the GitHub Environment "member-release" (deployment: tags v* only; the maintainer
+ # approves each run), so no other job, workflow or branch can read it. This job's GitHub token only reads; the
+ # insiders token reaches exactly one step, as an env var. Runs only for the tag push itself (the environment refuses
+ # a workflow_dispatch from a branch); scripts/release.sh check enforces the environment and pinned actions.
+ publish-members:
+ name: Publish members' beta
+ needs: [locate, build, smoke]
+ if: ${{ !cancelled() && needs.smoke.result == 'success' && inputs.dry_run != true && contains(needs.locate.outputs.tag, '-') }}
+ runs-on: ubuntu-24.04
+ environment: member-release
+ permissions:
+ contents: read
+ actions: read # the packages may be another run's artifacts
+ steps:
+ - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
+ with: { ref: '${{ env.TAG }}', persist-credentials: false }
+ - uses: actions/download-artifact@9000827ccba6bdab643e8b6fd33ac0654aef8333 # v8.0.2
+ with:
+ path: dist
+ merge-multiple: true
+ pattern: '{linux,flatpak,vfx,macos,windows}*'
+ run-id: ${{ needs.locate.outputs.run-id || github.run_id }}
+ github-token: ${{ github.token }}
+ - name: Blender add-on and Maya shelf script
+ run: |
+ V=${TAG#v}
+ V=${V%%-*} # a beta's packages carry its version without the prerelease (the app shows it)
+ python3 addons/blender/build_addon.py --check --version "$V" --out dist
+ python3 -m zipfile -c dist/sculptforge_maya.zip integrations/maya/sculptforge_maya.py integrations/maya/README.md
+ - name: Checksums
+ run: cd dist && sha256sum * > SHA256SUMS.txt && cat SHA256SUMS.txt
++ - name: Sign the checksums (one-click update checks SHA256SUMS.txt.sig, src/core/SelfUpdate.h)
++ env:
++ UPDATE_SIGNING_KEY: ${{ secrets.UPDATE_SIGNING_KEY }}
++ run: tools/release/sign_sums.sh dist
+ - name: Release notes (CHANGELOG's [Unreleased])
+ run: |
+ printf '%s\n\n' "**Members' beta.** Thank you for being a member! Please report problems in #members on Discord (or a GitHub issue) with your OS, this version (Help > About) and your graphics card." > notes.md
+ awk -v h="## [Unreleased]" 'index($0, h) == 1 {flag=1;next} /^## \[/{flag=0} flag' CHANGELOG.md >> notes.md
+ cat packaging/release-notes-footer.md >> notes.md
+ - name: Pre-release in islandmed/sculptforge-insiders
+ env:
+ GH_TOKEN: ${{ secrets.INSIDERS_REPO_TOKEN }}
+ GH_REPO: islandmed/sculptforge-insiders
+ run: |
+ [ -n "$GH_TOKEN" ] || { echo "::error::No INSIDERS_REPO_TOKEN in the member-release environment"; exit 1; }
+ pre=${TAG#*-}
+ title="SculptForge ${TAG%%-*} $(sed -E 's/^rc/RC/; s/^./\U&/; s/\./ /g' <<<"$pre")" # v0.11.0-beta.1: "SculptForge 0.11.0 Beta 1"
+ gh release view "$TAG" >/dev/null 2>&1 ||
+ gh release create "$TAG" --title "${title/SculptForge v/SculptForge }" --notes-file notes.md --prerelease --latest=false
gh release upload "$TAG" dist/* --clobber
+ - name: Post the beta in #members
+ env:
+ WEBHOOK: ${{ secrets.DISCORD_MEMBERS_WEBHOOK }}
+ run: |
+ if [ -z "$WEBHOOK" ]; then echo "::warning::No DISCORD_MEMBERS_WEBHOOK secret: post the beta in #members by hand"; exit 0; fi
+ pre=${TAG#*-}
+ label="${TAG%%-*} $(sed -E 's/^rc/RC/; s/^./\U&/; s/\./ /g' <<<"$pre")"
+ url="https://github.com/islandmed/sculptforge-insiders/releases/tag/$TAG"
+ jq -n --arg c "**SculptForge ${label#v} is up for members:** $url
+ Please report anything that goes wrong here, with your OS and graphics card. Not invited to the repository yet? Reply with your GitHub username." \
+ '{content: $c, allowed_mentions: {parse: []}, flags: 4}' |
+ curl -fsS -H 'Content-Type: application/json' -d @- "$WEBHOOK" >/dev/null
+ echo "Posted to #members"
diff --cc scripts/release.sh
index a64e013c,575d9b51..2c2b3370
--- a/scripts/release.sh
+++ b/scripts/release.sh
@@@ -100,9 -96,13 +100,13 @@@ push_main()
gitp push -q origin HEAD:main || die "push to main refused" "git pull --rebase origin main, check the result, run again"
}
release_ready() {
- gh release view "$T" -R "$REPO" --json assets -q '.assets[].name' > "$work/assets" 2>/dev/null ||
+ gh release view "$T" -R "$RELEASE_REPO" --json assets -q '.assets[].name' > "$work/assets" 2>/dev/null ||
die "no GitHub release $T yet" "run the earlier steps: scripts/release.sh $V --from tag"
grep -qx SHA256SUMS.txt "$work/assets" || die "release $T has no SHA256SUMS.txt (unfinished)" "re-run the Release workflow: gh workflow run release.yml -R $REPO -f tag=$T"
+ # One-click update (src/core/SelfUpdate.h): once the app has a key, every release must carry the signature.
+ if grep -q 'kUpdatePublicKeyHex = "[0-9a-f]\{64\}"' src/core/SelfUpdate.h 2>/dev/null; then
+ grep -qx SHA256SUMS.txt.sig "$work/assets" || die "release $T has no SHA256SUMS.txt.sig: apps can't update to it in one click" "check the UPDATE_SIGNING_KEY secret, then re-run the Release workflow: gh workflow run release.yml -R $REPO -f tag=$T"
+ fi
}
# Downloads one release asset and checks it against SHA256SUMS.txt with a checksum computed here. Prints the sum.
asset_sha() {
diff --cc src/app/PanelProject.cpp
index 54543028,ac2d8098..62a55c33
--- a/src/app/PanelProject.cpp
+++ b/src/app/PanelProject.cpp
@@@ -786,21 -803,23 +803,23 @@@ void App::drawUpdateBanner()
if (guide_.bodyFont()) ImGui::PopFont();
ImGui::Spacing();
bool close = false;
- if (ImGui::Button(tr("What's new"))) SDL_OpenURL(u.notesUrl.c_str());
- ImGui::SameLine();
- if (ImGui::Button(tr("Download"))) {
- SDL_OpenURL(u.downloadUrl.c_str());
- close = true;
- }
- ImGui::SameLine();
- if (ImGui::Button(tr("Become a member"))) openSupportPage();
- ImGui::SameLine();
- if (ImGui::Button(tr("Later"))) close = true;
- ImGui::SameLine();
- if (ImGui::Button(tr("Skip this version"))) {
- updateSkipped_ = u.version;
- saveProjectPrefs();
- close = true;
+ if (!drawSelfUpdate(u, close)) { // (PanelUpdate.cpp: Update, or the package manager's command)
+ if (ImGui::Button(tr("What's new"))) SDL_OpenURL(u.notesUrl.c_str());
+ ImGui::SameLine();
+ if (ImGui::Button(tr("Download"))) {
+ SDL_OpenURL(u.downloadUrl.c_str());
+ close = true;
+ }
+ ImGui::SameLine();
- if (ImGui::Button(tr("Become an Insider"))) openSupportPage();
++ if (ImGui::Button(tr("Become a member"))) openSupportPage();
+ ImGui::SameLine();
+ if (ImGui::Button(tr("Later"))) close = true;
+ ImGui::SameLine();
+ if (ImGui::Button(tr("Skip this version"))) {
+ updateSkipped_ = u.version;
+ saveProjectPrefs();
+ close = true;
+ }
}
if (close) updateAvailable_.reset();
}
diff --cc tests/release_beta_test.sh
index 2b2472e4,3f0282c5..eb5aa39d
--- a/tests/release_beta_test.sh
+++ b/tests/release_beta_test.sh
@@@ -58,9 -57,7 +58,9 @@@ cat > "$S/bin/gh" <<EO
#!/usr/bin/env bash
case "\$*" in
"auth status"*) echo "Logged in to github.com account islandmed" ;;
+ "secret list"*) printf 'INSIDERS_REPO_TOKEN\t2026-11-05T00:00:00Z\n' ;;
+ "repo view islandmed/sculptforge-insiders"*) echo "islandmed/sculptforge-insiders" ;;
- "release view"*) echo SHA256SUMS.txt ;;
+ "release view"*) printf 'SHA256SUMS.txt\nSHA256SUMS.txt.sig\n' ;; # (signed: the app has an update key)
"release download"*) exit 1 ;;
*homebrew-tap*) printf ' version "0.10.10"\n' | base64 ;;
"pr view 1800"*) echo "OPEN islandmed sculptforge-bump" ;;