Skip to content

Commit 2366839

Browse files
committed
fix: semantic release config
1 parent a964dd8 commit 2366839

File tree

2 files changed

+28
-7
lines changed

2 files changed

+28
-7
lines changed

.circleci/config.yml

+22-1
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,20 @@ jobs:
5252
name: Release new version
5353
command: npm run release
5454

55+
# Reset alpha branch after a release
56+
post_release:
57+
docker:
58+
- image: circleci/node:12
59+
steps:
60+
- checkout_code
61+
- run:
62+
name: Set tip of alpha branch on top of release and force-push it to remote
63+
command: |
64+
git pull origin release
65+
git checkout alpha
66+
git reset --hard release --
67+
git push "https://$GITHUB_TOKEN@github.com/$CIRCLE_PROJECT_USERNAME/$CIRCLE_PROJECT_REPONAME.git" --force
68+
5569
workflows:
5670
version: 2
5771
main:
@@ -65,6 +79,13 @@ workflows:
6579
- build
6680
filters:
6781
branches:
68-
only:
82+
only:
6983
- release
7084
- alpha
85+
- post_release:
86+
requires:
87+
- release
88+
filters:
89+
branches:
90+
only:
91+
- release

package.json

+6-6
Original file line numberDiff line numberDiff line change
@@ -41,14 +41,14 @@
4141
[
4242
"semantic-release-version-bump",
4343
{
44-
"files": "newspack-new-plugin-boilerplate.php",
44+
"files": "newspack-sponsors.php",
4545
"callback": "npm run release:archive"
4646
}
4747
],
4848
{
4949
"path": "@semantic-release/git",
5050
"assets": [
51-
"newspack-new-plugin-boilerplate.php",
51+
"newspack-sponsors.php",
5252
"package.json",
5353
"package-lock.json",
5454
"CHANGELOG.md"
@@ -71,8 +71,8 @@
7171
{
7272
"assets": [
7373
{
74-
"path": "./release/newspack-new-plugin-boilerplate.zip",
75-
"label": "newspack-new-plugin-boilerplate.zip"
74+
"path": "./release/newspack-sponsors.zip",
75+
"label": "newspack-sponsors.zip"
7676
}
7777
]
7878
}
@@ -86,11 +86,11 @@
8686
},
8787
"repository": {
8888
"type": "git",
89-
"url": "git+https://github.com/Automattic/newspack-new-plugin-boilerplate.git"
89+
"url": "git+https://github.com/Automattic/newspack-sponsors.git"
9090
},
9191
"license": "GPL-2.0-or-later",
9292
"bugs": {
93-
"url": "https://github.com/Automattic/newspack-new-plugin-boilerplate/issues"
93+
"url": "https://github.com/Automattic/newspack-sponsors/issues"
9494
},
9595
"dependencies": {
9696
"@wordpress/api-fetch": "^3.12.0",

0 commit comments

Comments
 (0)