From d14a2a55f0c1dd467fe05c6ab893f42757d0f5ff Mon Sep 17 00:00:00 2001 From: Amr Bashir Date: Wed, 28 Aug 2024 19:27:33 +0300 Subject: [PATCH] ci: fix a few relative paths (#10813) * ci: fix a few relative paths * Update .changes/config.json --------- Co-authored-by: Lucas Fernandes Nogueira --- .changes/config.json | 2 +- .github/workflows/publish-cli-js.yml | 2 +- .scripts/ci/sync-cli-metadata.js | 9 +++------ Cargo.toml | 1 + 4 files changed, 6 insertions(+), 8 deletions(-) diff --git a/.changes/config.json b/.changes/config.json index 0fcea28f1..947393c0a 100644 --- a/.changes/config.json +++ b/.changes/config.json @@ -232,7 +232,7 @@ "dependencies": ["tauri-bundler", "tauri-utils", "tauri-macos-sign"], "postversion": [ "cargo check", - "cargo build --manifest-path ../../crates/tauri-schema-generator/Cargo.toml" + "cargo build --manifest-path ../tauri-schema-generator/Cargo.toml" ] }, "tauri-driver": { diff --git a/.github/workflows/publish-cli-js.yml b/.github/workflows/publish-cli-js.yml index 34173739a..8544836d4 100644 --- a/.github/workflows/publish-cli-js.yml +++ b/.github/workflows/publish-cli-js.yml @@ -178,7 +178,7 @@ jobs: # pnpm build:release # strip -x *.node # rm -rf node_modules - # rm -rf ../target + # rm -rf ../../target # - name: Upload artifact # uses: actions/upload-artifact@v3 # with: diff --git a/.scripts/ci/sync-cli-metadata.js b/.scripts/ci/sync-cli-metadata.js index 66d3cd275..b47212d92 100644 --- a/.scripts/ci/sync-cli-metadata.js +++ b/.scripts/ci/sync-cli-metadata.js @@ -6,7 +6,7 @@ /* This script is solely intended to be run as part of the `covector version` step to -keep the `../crates/tauri-cli/metadata.json` up to date with other version bumps. Long term +keep the `../../crates/tauri-cli/metadata-v2.json` up to date with other version bumps. Long term we should look to find a more "rusty way" to import / "pin" a version value in our tauri-cli rust binaries. */ @@ -15,10 +15,7 @@ const { readFileSync, writeFileSync } = require('fs') const { resolve } = require('path') const packageNickname = process.argv[2] -const filePath = - packageNickname === '@tauri-apps/cli' - ? `../../../crates/tauri-cli/metadata-v2.json` - : `../../crates/tauri-cli/metadata-v2.json` +const filePath = resolve(__dirname, '../../crates/tauri-cli/metadata-v2.json') const bump = process.argv[3] let index = null @@ -52,7 +49,7 @@ const inc = (version) => { } if (bump === 'premajor') { const pre = JSON.parse( - readFileSync(resolve(filePath, '../../../.changes/pre.json'), 'utf-8') + readFileSync(resolve(__dirname, '../../.changes/pre.json'), 'utf-8') ) return `${v.join('.')}-${pre.tag}.0` } diff --git a/Cargo.toml b/Cargo.toml index ae61bd6fe..97766b5ac 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -30,6 +30,7 @@ members = [ # examples "examples/file-associations/src-tauri", "examples/api/src-tauri", + "examples/api/src-tauri/tauri-plugin-sample", ] resolver = "2"