Skip to content

Commit 3a45985

Browse files
authored
Merge pull request #33 from jcdcdev/dev/v17
17.0.1
2 parents 543a5d0 + 31a6a59 commit 3a45985

File tree

8 files changed

+453
-337
lines changed

8 files changed

+453
-337
lines changed

.github/workflows/build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ jobs:
77
runs-on: ubuntu-latest
88
steps:
99
- name: Build
10-
uses: jcdcdev/jcdcdev.Umbraco.Github.Build@v17
10+
uses: jcdcdev/jcdcdev.Umbraco.GitHub.Build@v17
1111
with:
1212
project-name: Umbraco.Community.SimpleTrees
1313
project-path: src/Umbraco.Community.SimpleTrees/Umbraco.Community.SimpleTrees.csproj

.github/workflows/create-pr.yml

Lines changed: 30 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ on:
88
default: false
99
type: boolean
1010
schedule:
11-
- cron: '0 2 * * *'
11+
- cron: "0 2 * * *"
1212
jobs:
1313
get-branches:
1414
outputs:
@@ -34,7 +34,7 @@ jobs:
3434
strategy:
3535
max-parallel: 1
3636
matrix:
37-
branch: ${{fromJson(needs.get-branches.outputs.branches)}}
37+
branch: ${{fromJson(needs.get-branches.outputs.branches)}}
3838
runs-on: ubuntu-latest
3939
env:
4040
DRY_RUN: ${{ contains(github.event.inputs.dry-run, 'true') }}
@@ -43,25 +43,49 @@ jobs:
4343
run: |
4444
TARGET=$(echo ${{ matrix.branch }} | sed 's/dev\///')
4545
SOURCE=${{ matrix.branch }}
46+
# Extract major version from TARGET by removing all non-digit characters
47+
MAJOR_VERSION=$(echo "$TARGET" | tr -dc '0-9')
4648
4749
if [ -z "$TARGET" ]; then
4850
echo "TARGET is empty"
4951
exit 1
5052
fi
51-
53+
5254
if [ -z "$SOURCE" ]; then
5355
echo "SOURCE is empty"
5456
exit 1
5557
fi
5658
59+
if [ -z "$MAJOR_VERSION" ]; then
60+
echo "MAJOR_VERSION is empty"
61+
exit 1
62+
fi
63+
64+
ACTION_VERSION="1"
65+
if [[ "$MAJOR_VERSION" -lt "17" ]]; then
66+
ACTION_VERSION="0"
67+
fi
68+
5769
echo "SOURCE=$SOURCE"
5870
echo "TARGET=$TARGET"
71+
echo "ACTION_VERSION=$ACTION_VERSION"
5972
73+
echo "ACTION_VERSION=$ACTION_VERSION" >> $GITHUB_ENV
6074
echo "SOURCE=$SOURCE" >> $GITHUB_ENV
6175
echo "TARGET=$TARGET" >> $GITHUB_ENV
62-
- name: Create Pull Request
63-
id: create-pull-request
64-
uses: jcdcdev/jcdcdev.GitHub.CreatePullRequest@main
76+
- name: Create Pull Request - Action v0
77+
if: ${{ env.ACTION_VERSION == '0' }}
78+
id: create-pull-request-v0
79+
uses: jcdcdev/jcdcdev.GitHub.CreatePullRequest@v0
80+
with:
81+
source-branch: ${{ env.SOURCE }}
82+
target-branch: ${{ env.TARGET }}
83+
dry-run: ${{ env.DRY_RUN }}
84+
github-token: ${{ secrets.JCDC_BOT_TOKEN }}
85+
- name: Create Pull Request - Action v1
86+
if: ${{ env.ACTION_VERSION == '1' }}
87+
id: create-pull-request-v1
88+
uses: jcdcdev/jcdcdev.GitHub.CreatePullRequest@v1
6589
with:
6690
source-branch: ${{ env.SOURCE }}
6791
target-branch: ${{ env.TARGET }}

.github/workflows/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
steps:
1414
- name: Build
1515
id: build
16-
uses: jcdcdev/jcdcdev.Umbraco.Github.Build@v17
16+
uses: jcdcdev/jcdcdev.Umbraco.GitHub.Build@v17
1717
with:
1818
project-name: Umbraco.Community.SimpleTrees
1919
project-path: src/Umbraco.Community.SimpleTrees/Umbraco.Community.SimpleTrees.csproj

.github/workflows/update-readme.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ on:
88
default: false
99
type: boolean
1010
schedule:
11-
- cron: '30 23,11 * * *'
11+
- cron: "30 23,11 * * *"
1212
jobs:
1313
get-refs:
1414
runs-on: ubuntu-latest
@@ -36,7 +36,7 @@ jobs:
3636
strategy:
3737
max-parallel: 1
3838
matrix:
39-
ref: ${{fromJson(needs.get-refs.outputs.refs) }}
39+
ref: ${{fromJson(needs.get-refs.outputs.refs) }}
4040
steps:
4141
- name: Update README
4242
uses: jcdcdev/jcdcdev.Umbraco.GitHub.PackageReadme@main
@@ -47,4 +47,3 @@ jobs:
4747
nuget-readme-filepath: ${{ env.NUGET_README_FILEPATH }}
4848
branch: ${{ matrix.ref }}
4949
api-key: ${{ secrets.SECURITY_POLICY_API_KEY }}
50-

.github/workflows/update-security-policy.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ on:
88
default: false
99
type: boolean
1010
schedule:
11-
- cron: '0 23,11 * * *'
11+
- cron: "0 23,11 * * *"
1212
jobs:
1313
get-refs:
1414
runs-on: ubuntu-latest
@@ -35,7 +35,7 @@ jobs:
3535
strategy:
3636
max-parallel: 1
3737
matrix:
38-
ref: ${{fromJson(needs.get-refs.outputs.refs) }}
38+
ref: ${{fromJson(needs.get-refs.outputs.refs) }}
3939
steps:
4040
- name: Update Security Policy
4141
uses: jcdcdev/jcdcdev.Umbraco.GitHub.PackageSecurity@main
@@ -45,4 +45,3 @@ jobs:
4545
security-policy-filepath: ${{ env.SECURITY_POLICY_FILEPATH }}
4646
security-policy-api-key: ${{ secrets.SECURITY_POLICY_API_KEY }}
4747
branch: ${{ matrix.ref }}
48-

GitVersion.yml

Lines changed: 94 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,94 @@
1+
workflow: ""
2+
3+
assembly-versioning-scheme: MajorMinorPatch
4+
assembly-file-versioning-scheme: MajorMinorPatch
5+
tag-prefix: "[vV]?"
6+
tag-pre-release-weight: 60000
7+
commit-message-incrementing: Enabled
8+
commit-date-format: "yyyy-MM-dd"
9+
mode: ContinuousDelivery
10+
label: "{BranchName}"
11+
increment: Inherit
12+
prevent-increment:
13+
of-merged-branch: false
14+
when-branch-merged: false
15+
when-current-commit-tagged: true
16+
track-merge-target: false
17+
track-merge-message: true
18+
regex: ""
19+
source-branches: []
20+
is-source-branch-for: []
21+
tracks-release-branches: false
22+
is-release-branch: false
23+
is-main-branch: false
24+
25+
ignore:
26+
commits-before: 2025-11-25T00:00:00Z
27+
sha: []
28+
paths: []
29+
30+
strategies:
31+
- MergeMessage
32+
- TaggedCommit
33+
- Fallback
34+
35+
branches:
36+
vX-release:
37+
regex: '^v(?<BranchName>\d+)$'
38+
mode: ContinuousDeployment
39+
label: ""
40+
increment: Patch
41+
is-main-branch: true
42+
prevent-increment:
43+
of-merged-branch: true
44+
source-branches: []
45+
pre-release-weight: 55000
46+
47+
dev-vX:
48+
regex: '^dev\/v(?<BranchName>\d+)$'
49+
mode: ContinuousDelivery
50+
label: "alpha"
51+
increment: Patch
52+
source-branches: [vX-release]
53+
is-main-branch: false
54+
pre-release-weight: 30000
55+
56+
main:
57+
regex: ^master$|^main$
58+
mode: ContinuousDelivery
59+
label: ""
60+
increment: Patch
61+
is-main-branch: true
62+
prevent-increment:
63+
of-merged-branch: true
64+
source-branches: []
65+
pre-release-weight: 55000
66+
67+
pull-request:
68+
mode: ContinuousDelivery
69+
label: PullRequest{Number}
70+
increment: Inherit
71+
prevent-increment:
72+
of-merged-branch: false
73+
when-current-commit-tagged: false
74+
track-merge-message: true
75+
regex: ^(pull-requests|pull|pr)[\/-](?<Number>\d*)
76+
source-branches:
77+
- main
78+
- vX-release
79+
- dev-vX
80+
pre-release-weight: 30000
81+
82+
unknown:
83+
mode: ContinuousDelivery
84+
label: "{BranchName}"
85+
increment: Inherit
86+
prevent-increment:
87+
when-current-commit-tagged: true
88+
regex: (?<BranchName>.+)
89+
source-branches:
90+
- main
91+
- vX-release
92+
- dev-vX
93+
- pull-request
94+
pre-release-weight: 0

0 commit comments

Comments
 (0)