mirror of
https://github.com/Kuingsmile/PicList.git
synced 2025-02-02 02:58:13 -05:00
📦 Chore: add mac-arm64 build support
This commit is contained in:
parent
34b3656605
commit
f2a4197ca2
5
.github/workflows/main.yml
vendored
5
.github/workflows/main.yml
vendored
@ -23,7 +23,7 @@ jobs:
|
|||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
os: [ubuntu-latest, macos-10.15]
|
os: [ubuntu-latest, macos-12]
|
||||||
|
|
||||||
# create steps
|
# create steps
|
||||||
steps:
|
steps:
|
||||||
@ -50,6 +50,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Build & release app
|
- name: Build & release app
|
||||||
run: |
|
run: |
|
||||||
npm run release
|
yarn build --arm64
|
||||||
|
yarn release
|
||||||
env:
|
env:
|
||||||
GH_TOKEN: ${{ secrets.GH_TOKEN }}
|
GH_TOKEN: ${{ secrets.GH_TOKEN }}
|
||||||
|
@ -29,4 +29,4 @@ build_script:
|
|||||||
- yarn build --win --ia32
|
- yarn build --win --ia32
|
||||||
- yarn release
|
- yarn release
|
||||||
|
|
||||||
test: off
|
test: false
|
||||||
|
@ -4,7 +4,6 @@ import {
|
|||||||
Notification,
|
Notification,
|
||||||
ipcMain
|
ipcMain
|
||||||
} from 'electron'
|
} from 'electron'
|
||||||
import path from 'path'
|
|
||||||
import db, { GalleryDB } from 'apis/core/datastore'
|
import db, { GalleryDB } from 'apis/core/datastore'
|
||||||
import { dbPathChecker, defaultConfigPath, getGalleryDBPath } from 'apis/core/datastore/dbChecker'
|
import { dbPathChecker, defaultConfigPath, getGalleryDBPath } from 'apis/core/datastore/dbChecker'
|
||||||
import uploader from 'apis/app/uploader'
|
import uploader from 'apis/app/uploader'
|
||||||
@ -18,7 +17,6 @@ import {
|
|||||||
SHOW_INPUT_BOX
|
SHOW_INPUT_BOX
|
||||||
} from '~/universal/events/constants'
|
} from '~/universal/events/constants'
|
||||||
import { DBStore } from '@picgo/store'
|
import { DBStore } from '@picgo/store'
|
||||||
type PromiseResType<T> = T extends Promise<infer R> ? R : T
|
|
||||||
|
|
||||||
// Cross-process support may be required in the future
|
// Cross-process support may be required in the future
|
||||||
class GuiApi implements IGuiApi {
|
class GuiApi implements IGuiApi {
|
||||||
|
2
src/universal/types/types.d.ts
vendored
2
src/universal/types/types.d.ts
vendored
@ -333,3 +333,5 @@ interface IMiniWindowPos {
|
|||||||
height: number,
|
height: number,
|
||||||
width: number
|
width: number
|
||||||
}
|
}
|
||||||
|
|
||||||
|
type PromiseResType<T> = T extends Promise<infer R> ? R : T
|
||||||
|
@ -4,6 +4,7 @@ function resolve (dir) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const arch = process.argv.includes('--ia32') ? 'ia32' : 'x64'
|
const arch = process.argv.includes('--ia32') ? 'ia32' : 'x64'
|
||||||
|
const macArch = process.argv.includes('--arm64') ? 'arm64' : 'x64'
|
||||||
|
|
||||||
const config = {
|
const config = {
|
||||||
configureWebpack: {
|
configureWebpack: {
|
||||||
@ -65,7 +66,12 @@ const config = {
|
|||||||
icon: 'build/icons/icon.icns',
|
icon: 'build/icons/icon.icns',
|
||||||
extendInfo: {
|
extendInfo: {
|
||||||
LSUIElement: 1
|
LSUIElement: 1
|
||||||
}
|
},
|
||||||
|
target: [{
|
||||||
|
target: 'dmg',
|
||||||
|
arch: macArch
|
||||||
|
}],
|
||||||
|
artifactName: `PicGo-\${version}-${macArch}.dmg`
|
||||||
},
|
},
|
||||||
win: {
|
win: {
|
||||||
icon: 'build/icons/icon.ico',
|
icon: 'build/icons/icon.ico',
|
||||||
|
Loading…
Reference in New Issue
Block a user