Prebuild macOS smoke app in CI
This commit is contained in:
@@ -96,15 +96,28 @@ jobs:
|
|||||||
- name: Build managed runtime for macOS
|
- name: Build managed runtime for macOS
|
||||||
run: npm run prepare:managed-runtime --workspace=@getpaseo/desktop
|
run: npm run prepare:managed-runtime --workspace=@getpaseo/desktop
|
||||||
|
|
||||||
- name: Smoke check managed runtime for macOS
|
|
||||||
run: npm run smoke:managed-daemon --workspace=@getpaseo/desktop
|
|
||||||
|
|
||||||
- name: Import Apple code-signing certificate
|
- name: Import Apple code-signing certificate
|
||||||
uses: apple-actions/import-codesign-certs@v3
|
uses: apple-actions/import-codesign-certs@v3
|
||||||
with:
|
with:
|
||||||
p12-file-base64: ${{ secrets.APPLE_CERTIFICATE }}
|
p12-file-base64: ${{ secrets.APPLE_CERTIFICATE }}
|
||||||
p12-password: ${{ secrets.APPLE_CERTIFICATE_PASSWORD }}
|
p12-password: ${{ secrets.APPLE_CERTIFICATE_PASSWORD }}
|
||||||
|
|
||||||
|
- name: Build packaged app for macOS smoke
|
||||||
|
env:
|
||||||
|
APPLE_SIGNING_IDENTITY: ${{ secrets.APPLE_SIGNING_IDENTITY }}
|
||||||
|
APPLE_ID: ${{ secrets.APPLE_ID }}
|
||||||
|
APPLE_PASSWORD: ${{ secrets.APPLE_PASSWORD }}
|
||||||
|
APPLE_TEAM_ID: ${{ secrets.APPLE_TEAM_ID }}
|
||||||
|
TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY }}
|
||||||
|
TAURI_SIGNING_PRIVATE_KEY_PASSWORD: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY_PASSWORD }}
|
||||||
|
run: npm run tauri --workspace=@getpaseo/desktop build -- --target ${{ matrix.rust_target }}
|
||||||
|
|
||||||
|
- name: Smoke check managed runtime for macOS
|
||||||
|
env:
|
||||||
|
PASEO_MANAGED_SMOKE_SKIP_BUILD: "1"
|
||||||
|
PASEO_MANAGED_SMOKE_RUST_TARGET: ${{ matrix.rust_target }}
|
||||||
|
run: npm run smoke:managed-daemon --workspace=@getpaseo/desktop
|
||||||
|
|
||||||
- name: Sign bundled managed runtime for macOS
|
- name: Sign bundled managed runtime for macOS
|
||||||
env:
|
env:
|
||||||
APPLE_SIGNING_IDENTITY: ${{ secrets.APPLE_SIGNING_IDENTITY }}
|
APPLE_SIGNING_IDENTITY: ${{ secrets.APPLE_SIGNING_IDENTITY }}
|
||||||
|
|||||||
@@ -26,12 +26,18 @@ const currentRuntimePointer = JSON.parse(
|
|||||||
const currentRuntimeId = currentRuntimePointer.runtimeId;
|
const currentRuntimeId = currentRuntimePointer.runtimeId;
|
||||||
|
|
||||||
function resolvePackagedBinary() {
|
function resolvePackagedBinary() {
|
||||||
|
const targetRoot = process.env.PASEO_MANAGED_SMOKE_RUST_TARGET
|
||||||
|
? path.join(
|
||||||
|
desktopRoot,
|
||||||
|
"src-tauri",
|
||||||
|
"target",
|
||||||
|
process.env.PASEO_MANAGED_SMOKE_RUST_TARGET,
|
||||||
|
"release"
|
||||||
|
)
|
||||||
|
: path.join(desktopRoot, "src-tauri", "target", "release");
|
||||||
if (process.platform === "darwin") {
|
if (process.platform === "darwin") {
|
||||||
return path.join(
|
return path.join(
|
||||||
desktopRoot,
|
targetRoot,
|
||||||
"src-tauri",
|
|
||||||
"target",
|
|
||||||
"release",
|
|
||||||
"bundle",
|
"bundle",
|
||||||
"macos",
|
"macos",
|
||||||
"Paseo.app",
|
"Paseo.app",
|
||||||
@@ -42,10 +48,7 @@ function resolvePackagedBinary() {
|
|||||||
}
|
}
|
||||||
if (process.platform === "linux") {
|
if (process.platform === "linux") {
|
||||||
return path.join(
|
return path.join(
|
||||||
desktopRoot,
|
targetRoot,
|
||||||
"src-tauri",
|
|
||||||
"target",
|
|
||||||
"release",
|
|
||||||
"bundle",
|
"bundle",
|
||||||
"appimage",
|
"appimage",
|
||||||
`Paseo_${desktopPackageJson.version}_amd64.AppImage`
|
`Paseo_${desktopPackageJson.version}_amd64.AppImage`
|
||||||
@@ -53,10 +56,7 @@ function resolvePackagedBinary() {
|
|||||||
}
|
}
|
||||||
if (process.platform === "win32") {
|
if (process.platform === "win32") {
|
||||||
return path.join(
|
return path.join(
|
||||||
desktopRoot,
|
targetRoot,
|
||||||
"src-tauri",
|
|
||||||
"target",
|
|
||||||
"release",
|
|
||||||
"Paseo.exe"
|
"Paseo.exe"
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@@ -358,6 +358,9 @@ function assertNoForbiddenPathsOrPorts(value, forbidden) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
async function ensurePackagedArtifact(binaryPath) {
|
async function ensurePackagedArtifact(binaryPath) {
|
||||||
|
if (process.env.PASEO_MANAGED_SMOKE_SKIP_BUILD === "1") {
|
||||||
|
return;
|
||||||
|
}
|
||||||
try {
|
try {
|
||||||
await execFileAsync("npm", ["run", "build"], {
|
await execFileAsync("npm", ["run", "build"], {
|
||||||
cwd: desktopRoot,
|
cwd: desktopRoot,
|
||||||
|
|||||||
Reference in New Issue
Block a user