Build your personal knowledge base with Trilium Notes
TypeScript electronelectron-appknowledge-baseknowledge-graphknowledge-managementknowledge-management-graphlocal-firstnote-managmentnote-takernote-takingnotebooknotesnotes-apppersonal-knowledge-basepersonal-wikiscriptableself-hostedself-hostingwiki
feat(forge): match name for artifacts
Elian Dorana7d6bf1bd876
diff --git a/.github/actions/build-electron/action.yml b/.github/actions/build-electron/action.ymlindex dc203c667b..6c1b6d8190 100644--- a/.github/actions/build-electron/action.yml+++ b/.github/actions/build-electron/action.yml@@ -81,6 +81,7 @@ runs:APPLE_ID: ${{ env.APPLE_ID }}APPLE_ID_PASSWORD: ${{ env.APPLE_ID_PASSWORD }}WINDOWS_SIGN_EXECUTABLE: ${{ env.WINDOWS_SIGN_EXECUTABLE }}+ TRILIUM_ARTIFACT_NAME_HINT: TriliumNextNotes ${{ inputs.os }} ${{ inputs.arch }}run: |npm run electron-forge:make -- \--arch=${{ inputs.arch }} \diff --git a/forge.config.cjs b/forge.config.cjsindex 6032eec040..ba3d8c3ffb 100644--- a/forge.config.cjs+++ b/forge.config.cjs@@ -143,11 +143,18 @@ module.exports = {for (const makeResult of makeResults) {for (const artifactPath of makeResult.artifacts) {// Ignore certain artifacts.- const fileName = path.basename(artifactPath);- if (fileName === "RELEASES" || path.extname(fileName) === ".nupkg") {+ let fileName = path.basename(artifactPath);+ const extension = path.extname(fileName);+ if (fileName === "RELEASES" || extension === ".nupkg") {continue;}+ // Override the extension for the CI.+ const { TRILIUM_ARTIFACT_NAME_HINT } = process.env;+ if (TRILIUM_ARTIFACT_NAME_HINT) {+ fileName = TRILIUM_ARTIFACT_NAME_HINT + extension;+ }+const outputPath = path.join(outputDir, fileName);console.log(`[Artifact] ${artifactPath} -> ${outputPath}`);fs.copyFile(artifactPath, outputPath);