Skip to content

armgit / Cap

Public Imported from GitHub
0

Open source Loom alternative. Beautiful, shareable screen recordings.

use Cargo.toml in CI

Brendan Alland259b9623043
diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml
index 83c545a1f..225f89941 100644
--- a/.github/workflows/publish.yml
+++ b/.github/workflows/publish.yml
@@ -5,6 +5,7 @@ on: workflow_dispatch
env:
CN_APPLICATION: cap/cap
+ APP_CARGO_TOML: apps/desktop-solid/src-tauri/Cargo.toml
jobs:
cap-desktop-release:
@@ -16,14 +17,17 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v4
- - name: Get app version
- id: get_version
- run: echo "appVersion=$(jq -r '.version' apps/desktop/package.json)" >> $GITHUB_OUTPUT
+ - name: Read version number
+ uses: SebRollen/[email protected]
+ id: read_version
+ with:
+ file: ${{ env.APP_CARGO_TOML }}
+ field: "package.version"
- name: create draft release
uses: crabnebula-dev/cloud-release@v0
with:
- command: release draft ${{ env.CN_APPLICATION }} ${{ steps.get_version.outputs.appVersion }} --framework tauri
+ command: release draft ${{ env.CN_APPLICATION }} ${{ steps.read_version.outputs.value }} --framework tauri
api-key: ${{ secrets.CN_API_KEY }}
- name: Create API Key File
@@ -50,7 +54,7 @@ jobs:
- name: Create .env file in root
run: |
- echo "appVersion=${{ steps.get_version.outputs.appVersion }}" >> .env
+ echo "appVersion=${{ steps.read_version.outputs.value }}" >> .env
echo "CAP_DESKTOP_SENTRY_URL=https://efd3156d9c0a8a49bee3ee675bec80d8@o4506859771527168.ingest.us.sentry.io/4506859844403200" >> .env
- name: Copy .env to apps/desktop-solid
@@ -64,7 +68,7 @@ jobs:
# Build both intel and apple silicon
working-directory: apps/desktop-solid
run: |
- rustup target add x86_64-apple-darwin
+ rustup target add x86_64-apple-darwin
pnpm install
pnpm tauri build --target x86_64-apple-darwin
pnpm tauri build --target aarch64-apple-darwin
diff --git a/Cargo.lock b/Cargo.lock
index a5dd411d7..45d711480 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -1520,7 +1520,7 @@ dependencies = [
[[package]]
name = "desktop"
-version = "0.1.0"
+version = "0.2.0"
dependencies = [
"anyhow",
"axum",
diff --git a/apps/desktop-solid/src-tauri/Cargo.toml b/apps/desktop-solid/src-tauri/Cargo.toml
index 81a0ffc79..090fdefbb 100644
--- a/apps/desktop-solid/src-tauri/Cargo.toml
+++ b/apps/desktop-solid/src-tauri/Cargo.toml
@@ -1,6 +1,6 @@
[package]
name = "desktop"
-version = "0.1.0"
+version = "0.2.0"
description = "A Tauri App"
authors = ["you"]
edition = "2021"