mirror of
https://github.com/cinnyapp/cinny-desktop.git
synced 2024-12-28 02:16:11 +00:00
GH doesn't have arm runner yet
This commit is contained in:
parent
671ff5f4c1
commit
747666fa42
114
.github/workflows/tauri.yml
vendored
114
.github/workflows/tauri.yml
vendored
|
@ -164,67 +164,67 @@ jobs:
|
||||||
src-tauri/target/release/bundle/macos/Cinny_desktop-x86_64.app.tar.gz.sig
|
src-tauri/target/release/bundle/macos/Cinny_desktop-x86_64.app.tar.gz.sig
|
||||||
|
|
||||||
# macos-aarch64
|
# macos-aarch64
|
||||||
macos-aarch64:
|
# macos-aarch64:
|
||||||
runs-on: macos-12
|
# runs-on: macos-12
|
||||||
steps:
|
# steps:
|
||||||
- name: Checkout repository
|
# - name: Checkout repository
|
||||||
uses: actions/checkout@v3.0.2
|
# uses: actions/checkout@v3.0.2
|
||||||
with:
|
# with:
|
||||||
submodules: true
|
# submodules: true
|
||||||
- name: Get release
|
# - name: Get release
|
||||||
id: get_release
|
# id: get_release
|
||||||
uses: bruceadams/get-release@3a8733307b85cd96d52772b037617bd63d99522e
|
# uses: bruceadams/get-release@3a8733307b85cd96d52772b037617bd63d99522e
|
||||||
env:
|
# env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
- name: Setup node
|
# - name: Setup node
|
||||||
uses: actions/setup-node@v3.3.0
|
# uses: actions/setup-node@v3.3.0
|
||||||
with:
|
# with:
|
||||||
node-version: 17.9.0
|
# node-version: 17.9.0
|
||||||
- name: Install Rust stable
|
# - name: Install Rust stable
|
||||||
uses: actions-rs/toolchain@v1.0.7
|
# uses: actions-rs/toolchain@v1.0.7
|
||||||
with:
|
# with:
|
||||||
toolchain: stable
|
# toolchain: stable
|
||||||
- name: Install cinny dependencies
|
# - name: Install cinny dependencies
|
||||||
run: cd cinny && npm ci
|
# run: cd cinny && npm ci
|
||||||
- name: Install tauri dependencies
|
# - name: Install tauri dependencies
|
||||||
run: npm ci
|
# run: npm ci
|
||||||
- name: Install rustup target aarch64 darwin
|
# - name: Install rustup target aarch64 darwin
|
||||||
run: rustup target add aarch64-apple-darwin
|
# run: rustup target add aarch64-apple-darwin
|
||||||
- name: Build desktop app with Tauri
|
# - name: Build desktop app with Tauri
|
||||||
uses: tauri-apps/tauri-action@v0.3.1
|
# uses: tauri-apps/tauri-action@v0.3.1
|
||||||
env:
|
# env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
TAURI_PRIVATE_KEY: ${{ secrets.TAURI_PRIVATE_KEY }}
|
# TAURI_PRIVATE_KEY: ${{ secrets.TAURI_PRIVATE_KEY }}
|
||||||
TAURI_KEY_PASSWORD: ${{ secrets.TAURI_KEY_PASSWORD }}
|
# TAURI_KEY_PASSWORD: ${{ secrets.TAURI_KEY_PASSWORD }}
|
||||||
with:
|
# with:
|
||||||
args: --target aarch64-apple-darwin
|
# args: --target aarch64-apple-darwin
|
||||||
releaseId: ${{ steps.get_release.outputs.upload_url }}
|
# releaseId: ${{ steps.get_release.outputs.upload_url }}
|
||||||
- name: Get app version
|
# - name: Get app version
|
||||||
if: always()
|
# if: always()
|
||||||
id: vars
|
# id: vars
|
||||||
run: echo ::set-output name=tag::$(jq .package.version src-tauri/tauri.conf.json | tr -d '"')
|
# run: echo ::set-output name=tag::$(jq .package.version src-tauri/tauri.conf.json | tr -d '"')
|
||||||
- name: Move dmg
|
# - name: Move dmg
|
||||||
if: always()
|
# if: always()
|
||||||
run: mv "src-tauri/target/aarch64-apple-darwin/release/bundle/dmg/Cinny_${{ steps.vars.outputs.tag }}_aarch64.dmg" "src-tauri/target/aarch64-apple-darwin/release/bundle/dmg/Cinny_desktop-aarch64.dmg"
|
# run: mv "src-tauri/target/aarch64-apple-darwin/release/bundle/dmg/Cinny_${{ steps.vars.outputs.tag }}_aarch64.dmg" "src-tauri/target/aarch64-apple-darwin/release/bundle/dmg/Cinny_desktop-aarch64.dmg"
|
||||||
- name: Move app.tar.gz
|
# - name: Move app.tar.gz
|
||||||
if: always()
|
# if: always()
|
||||||
run: mv "src-tauri/target/aarch64-apple-darwin/release/bundle/macos/Cinny.app.tar.gz" "src-tauri/target/aarch64-apple-darwin/release/bundle/macos/Cinny_desktop-aarch64.app.tar.gz"
|
# run: mv "src-tauri/target/aarch64-apple-darwin/release/bundle/macos/Cinny.app.tar.gz" "src-tauri/target/aarch64-apple-darwin/release/bundle/macos/Cinny_desktop-aarch64.app.tar.gz"
|
||||||
- name: Move app.tar.gz.sig
|
# - name: Move app.tar.gz.sig
|
||||||
if: always()
|
# if: always()
|
||||||
run: mv "src-tauri/target/aarch64-apple-darwin/release/bundle/macos/Cinny.app.tar.gz.sig" "src-tauri/target/aarch64-apple-darwin/release/bundle/macos/Cinny_desktop-aarch64.app.tar.gz.sig"
|
# run: mv "src-tauri/target/aarch64-apple-darwin/release/bundle/macos/Cinny.app.tar.gz.sig" "src-tauri/target/aarch64-apple-darwin/release/bundle/macos/Cinny_desktop-aarch64.app.tar.gz.sig"
|
||||||
- name: Upload tagged release
|
# - name: Upload tagged release
|
||||||
if: always()
|
# if: always()
|
||||||
uses: softprops/action-gh-release@1e07f4398721186383de40550babbdf2b84acfc5
|
# uses: softprops/action-gh-release@1e07f4398721186383de40550babbdf2b84acfc5
|
||||||
with:
|
# with:
|
||||||
files: |
|
# files: |
|
||||||
src-tauri/target/aarch64-apple-darwin/release/bundle/dmg/Cinny_desktop-aarch64.dmg
|
# src-tauri/target/aarch64-apple-darwin/release/bundle/dmg/Cinny_desktop-aarch64.dmg
|
||||||
src-tauri/target/aarch64-apple-darwin/release/bundle/macos/Cinny_desktop-aarch64.tar.gz
|
# src-tauri/target/aarch64-apple-darwin/release/bundle/macos/Cinny_desktop-aarch64.tar.gz
|
||||||
src-tauri/target/aarch64-apple-darwin/release/bundle/macos/Cinny_desktop-aarch64.tar.gz.sig
|
# src-tauri/target/aarch64-apple-darwin/release/bundle/macos/Cinny_desktop-aarch64.tar.gz.sig
|
||||||
|
|
||||||
# Upload release.json
|
# Upload release.json
|
||||||
release-update:
|
release-update:
|
||||||
if: always()
|
if: always()
|
||||||
needs: [windows-x86_64, linux-x86_64, macos-x86_64, macos-aarch64]
|
needs: [windows-x86_64, linux-x86_64, macos-x86_64] #, macos-aarch64]
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
|
|
|
@ -34,7 +34,7 @@ async function createTauriRelease() {
|
||||||
const windowsX86_64 = {};
|
const windowsX86_64 = {};
|
||||||
const linuxX86_64 = {};
|
const linuxX86_64 = {};
|
||||||
const darwinX86_64 = {};
|
const darwinX86_64 = {};
|
||||||
const darwinAarch64 = {};
|
// const darwinAarch64 = {};
|
||||||
|
|
||||||
const promises = latestAssets.map(async (asset) => {
|
const promises = latestAssets.map(async (asset) => {
|
||||||
const { name, browser_download_url } = asset;
|
const { name, browser_download_url } = asset;
|
||||||
|
@ -60,12 +60,12 @@ async function createTauriRelease() {
|
||||||
darwinX86_64.signature = await getAssetSign(browser_download_url);
|
darwinX86_64.signature = await getAssetSign(browser_download_url);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (/aarch64\.app\.tar\.gz$/.test(name)) {
|
// if (/aarch64\.app\.tar\.gz$/.test(name)) {
|
||||||
darwinAarch64.url = browser_download_url;
|
// darwinAarch64.url = browser_download_url;
|
||||||
}
|
// }
|
||||||
if (/aarch64\.app\.tar\.gz\.sig$/.test(name)) {
|
// if (/aarch64\.app\.tar\.gz\.sig$/.test(name)) {
|
||||||
darwinAarch64.signature = await getAssetSign(browser_download_url);
|
// darwinAarch64.signature = await getAssetSign(browser_download_url);
|
||||||
}
|
// }
|
||||||
});
|
});
|
||||||
|
|
||||||
await Promise.allSettled(promises);
|
await Promise.allSettled(promises);
|
||||||
|
@ -86,8 +86,8 @@ async function createTauriRelease() {
|
||||||
if (darwinX86_64.url) releaseData.platforms["darwin-x86_64"] = darwinX86_64;
|
if (darwinX86_64.url) releaseData.platforms["darwin-x86_64"] = darwinX86_64;
|
||||||
else console.error('Failed to get release for darwinX86_64');
|
else console.error('Failed to get release for darwinX86_64');
|
||||||
|
|
||||||
if (darwinAarch64.url) releaseData.platforms["darwin-aarch64"] = darwinAarch64;
|
// if (darwinAarch64.url) releaseData.platforms["darwin-aarch64"] = darwinAarch64;
|
||||||
else console.error('Failed to get release for darwinAarch64');
|
// else console.error('Failed to get release for darwinAarch64');
|
||||||
|
|
||||||
const releaseResult = await repos.getReleaseByTag({ ...repoMetaData, tag: 'tauri' });
|
const releaseResult = await repos.getReleaseByTag({ ...repoMetaData, tag: 'tauri' });
|
||||||
const tauriRelease = releaseResult.data;
|
const tauriRelease = releaseResult.data;
|
||||||
|
|
Loading…
Reference in a new issue