-
-
Notifications
You must be signed in to change notification settings - Fork 1
62 lines (53 loc) · 1.79 KB
/
Copy pathrelease.yml
File metadata and controls
62 lines (53 loc) · 1.79 KB
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
## Periodically runs a bash script.
name: Release Latest Versions
on:
workflow_dispatch:
inputs:
should_rerelease:
description: "Repack the latest version of the package"
required: false
default: false
type: boolean
dry_run:
description: "Dry run: Run the script without pushing changes"
required: false
default: false
type: boolean
from_version:
description: "The version to start from"
required: false
default: "1.0.0"
type: string
schedule:
- cron: "0 */12 * * *"
jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.2
with:
fetch-depth: 0
- name: Set up PHP
uses: shivammathur/setup-php@44454db4f0199b8b9685a5d763dc37cbf79108e1 # v2.36.0
with:
php-version: 7.4
tools: composer:v2, wp-cli
coverage: none
- name: Install WPGraphQL dependencies
uses: ramsey/composer-install@3cf229dc2919194e9e36783941438d17239e8520 # v3.1.1
with:
composer-options: "--no-progress"
dependency-versions: "highest"
working-directory: ./source
- name: Release Latest Versions
run: |
git config user.name "github-actions[bot]"
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
if [ "${{ inputs.should_rerelease }}" = "true" ]; then
SHOULD_RERELEASE="--should-rerelease"
fi
if [ "${{ inputs.dry_run }}" = "true" ]; then
DRY_RUN="--dry-run"
fi
bash -x ./release-latest-versions.sh $SHOULD_RERELEASE $DRY_RUN --from-version=${{ inputs.from_version }}