-
Notifications
You must be signed in to change notification settings - Fork 2
/
action.yml
72 lines (71 loc) · 3.35 KB
/
action.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
inputs:
macos-cert-importer:
description: 'Path to script used to import the macOS P12 certificate used to sign the app.'
default: '$GITHUB_ACTION_PATH/scripts/import-macos-cert.sh'
required: false
macos-cert-p12:
description: 'The base64-encoded contents of the macOS P12 certificate used to sign the app. Used by the default `macos-cert-importer` script.'
required: false
macos-cert-password:
description: 'The password used to unlock the signing certificate so that it can be imported into the keychain.'
required: false
node-installer:
description: 'Which Node.js package manager to use (`yarn` or `npm`). Defaults to detecting which package manager was used on the app via `yarn-or-npm` (which is used by Electron Forge).'
required: false
target-arch:
description: 'The target architecture for the Electron app distributable.'
required: false
target-maker:
description: 'The target Electron Forge maker module which generates the distributable artifacts. For example, @electron-forge/maker-deb'
required: true
target-platform:
description: 'The target platform for the Electron app distributable.'
required: true
windows-cert-filename:
description: 'Path to the PFX certificate generated from the windows-cert-p12 input. Provided to a JavaScript-based Forge config as `process.env.WINDOWS_CERT_FILENAME`.'
default: 'windows-certificate.pfx'
windows-cert-importer:
description: 'Path to script used to import the macOS P12 certificate used to sign the app.'
default: 'node $GITHUB_ACTION_PATH/scripts/import-windows-cert.js'
required: false
windows-cert-p12:
description: 'The base64-encoded contents of the Windows P12 certificate used to sign the app for Squirrel and AppX makers. Used by the default `windows-cert-importer` script.'
required: false
windows-cert-password:
description: 'The password used to unlock the signing certificate so that it can sign the distributables. Provided to a JavaScript-based Forge config as `process.env.WINDOWS_CERT_PASSWORD`.'
required: false
runs:
using: composite
steps:
- name: Install platform dependencies
shell: bash
run: $GITHUB_ACTION_PATH/scripts/platform-dependencies.sh
env:
TARGET_MAKER: ${{ inputs.target-maker }}
- name: Install Node.js dependencies
shell: bash
run: $GITHUB_ACTION_PATH/scripts/install.sh
env:
NODE_INSTALLER: ${{ inputs.node-installer }}
- name: Set up macOS signing certificate
shell: bash
run: ${{ inputs.macos-cert-importer }}
env:
MACOS_CERT_PASSWORD: ${{ inputs.macos-cert-password }}
MACOS_CERT_P12: ${{ inputs.macos-cert-p12 }}
- name: Set up Windows signing certificate
shell: bash
run: ${{ inputs.windows-cert-importer }}
env:
WINDOWS_CERT_FILENAME: ${{ inputs.windows-cert-filename }}
WINDOWS_CERT_P12: ${{ inputs.windows-cert-p12 }}
- name: Create app distributable
shell: bash
run: $GITHUB_ACTION_PATH/scripts/make.sh
env:
NODE_INSTALLER: ${{ inputs.node-installer }}
TARGET_ARCH: ${{ inputs.target-arch }}
TARGET_MAKER: ${{ inputs.target-maker }}
TARGET_PLATFORM: ${{ inputs.target-platform }}
WINDOWS_CERT_FILENAME: ${{ inputs.windows-cert-filename }}
WINDOWS_CERT_PASSWORD: ${{ inputs.windows-cert-password }}