Skip to content

Commit 043542e

Browse files
authored
chore: update release branch with latest master (#95)
1 parent c898ab8 commit 043542e

File tree

8 files changed

+45
-34
lines changed

8 files changed

+45
-34
lines changed

.github/workflows/automerge-orphans.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,14 +20,13 @@ jobs:
2020
script: |
2121
const query = `query($owner:String!, $name:String!) {
2222
repository(owner:$owner, name:$name){
23-
pullRequests(first: 100){
23+
pullRequests(first: 100, states: OPEN){
2424
nodes{
2525
title
2626
url
2727
author {
2828
resourcePath
2929
}
30-
state
3130
}
3231
}
3332
}
@@ -38,7 +37,7 @@ jobs:
3837
};
3938
const { repository: { pullRequests: { nodes } } } = await github.graphql(query, variables);
4039
41-
let orphans = nodes.filter((pr)=> pr.state === 'OPEN' && (pr.author.resourcePath === '/asyncapi-bot' || pr.author.resourcePath === '/apps/dependabot'))
40+
let orphans = nodes.filter( (pr) => pr.author.resourcePath === '/asyncapi-bot' || pr.author.resourcePath === '/apps/dependabot')
4241
4342
if (orphans.length) {
4443
core.setOutput('found', 'true');

.github/workflows/automerge.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ jobs:
2626
steps:
2727
- name: Autoapproving
2828
uses: hmarr/auto-approve-action@v2
29-
if: github.actor == 'asyncapi-bot' || github.actor == 'dependabot[bot]' || github.actor == 'dependabot-preview[bot]'
29+
if: github.actor == ('asyncapi-bot' || github.actor == 'dependabot[bot]' || github.actor == 'dependabot-preview[bot]') && !contains(github.event.pull_request.labels.*.name, 'released')
3030
with:
3131
github-token: "${{ secrets.GITHUB_TOKEN }}"
3232

@@ -44,4 +44,4 @@ jobs:
4444
MERGE_METHOD: "squash"
4545
MERGE_COMMIT_MESSAGE: "pull-request-title"
4646
MERGE_RETRIES: "20"
47-
MERGE_RETRY_SLEEP: "20000"
47+
MERGE_RETRY_SLEEP: "30000"

.github/workflows/bump.yml

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,10 @@
1-
name: Bump package version in dependent repos
1+
#This action is centrally managed in https://github.com/asyncapi/.github/
2+
#Don't make changes to this file in this repo as they will be overwritten with changes made to the same file in above mentioned repo
3+
4+
#Purpose of this action is to update npm package in libraries that use it. It is like dependabot for asyncapi npm modules only.
5+
#It runs in a repo after merge of release commit and searches for other packages that use released package. Every found package gets updated with lates version
6+
7+
name: Bump package version in dependent repos - if Node project
28

39
on:
410
#It cannot run on release event as when release is created then version is not yet bumped in package.json
@@ -13,20 +19,14 @@ jobs:
1319
steps:
1420
- name: Checkout repo
1521
uses: actions/checkout@v2
16-
- name: Get version from package.json before release step
17-
id: extractver
18-
run: echo "::set-output name=version::$(npm run get:version --silent)"
19-
- name: Get name of package from package.json
20-
id: extractname
21-
run: echo "::set-output name=packname::$(npm run get:name --silent)"
22-
- if: startsWith(github.event.commits[0].message, 'chore(release):')
22+
- name: Check if Node.js project and has package.json
23+
id: packagejson
24+
run: test -e ./package.json && echo "::set-output name=exists::true" || echo "::set-output name=exists::false"
25+
- if: steps.packagejson.outputs.exists == 'true' && startsWith(github.event.commits[0].message, 'chore(release):')
2326
name: Bumping latest version of this package in other repositories
24-
uses: derberg/org-projects-dependency-manager@v1
27+
uses: derberg/npm-dependency-manager-for-your-github-org@v3
2528
with:
2629
github_token: ${{ secrets.GH_TOKEN }}
2730
committer_username: asyncapi-bot
2831
committer_email: info@asyncapi.io
29-
#This is commit message and PR title for repos where this package is in dependencies
30-
commit_message_prod: 'fix: update ${{ steps.extractname.outputs.packname }} to ${{ steps.extractver.outputs.version }} version'
31-
#This is commit message and PR title for repos where this package is in devDependencies
32-
commit_message_dev: 'chore: update ${{ steps.extractname.outputs.packname }} to ${{ steps.extractver.outputs.version }} version'
32+
repos_to_ignore: html-template #this is temporary until react component releases 1.0, then it can be removed

.github/workflows/issues-prs-notifications.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
#This action is centrally managed in https://github.com/asyncapi/.github/
22
#Don't make changes to this file in this repo as they will be overwritten with changes made to the same file in above mentioned repo
3+
4+
#This action notifies community on slack whenever there is a new issue, PR or discussion started in given repository
35
name: Notify slack
46

57
on:
@@ -10,6 +12,9 @@ on:
1012
pull_request_target:
1113
types: [opened, reopened, ready_for_review]
1214

15+
discussion:
16+
types: [opened]
17+
1318
jobs:
1419

1520
issue:
@@ -47,3 +52,21 @@ jobs:
4752
SLACK_TITLE: 💪 New Pull Request 💪
4853
SLACK_MESSAGE: ${{steps.prmarkdown.outputs.text}}
4954
MSG_MINIMAL: true
55+
56+
discussion:
57+
if: github.event_name == 'discussion' && github.actor != 'asyncapi-bot' && github.actor != 'dependabot[bot]' && github.actor != 'dependabot-preview[bot]'
58+
name: On every new pull request
59+
runs-on: ubuntu-latest
60+
steps:
61+
- name: Convert markdown to slack markdown for pull request
62+
uses: LoveToKnow/slackify-markdown-action@v1.0.0
63+
id: discussionmarkdown
64+
with:
65+
text: "[${{github.event.discussion.title}}](${{github.event.discussion.html_url}}) \n ${{github.event.discussion.body}}"
66+
- name: Send info about pull request
67+
uses: rtCamp/action-slack-notify@v2
68+
env:
69+
SLACK_WEBHOOK: ${{secrets.SLACK_GITHUB_NEWISSUEPR}}
70+
SLACK_TITLE: 💬 New Discussion 💬
71+
SLACK_MESSAGE: ${{steps.discussionmarkdown.outputs.text}}
72+
MSG_MINIMAL: true

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@
186186
same "printed page" as the copyright notice for easier
187187
identification within third-party archives.
188188

189-
  Copyright 2017 Fran Méndez
189+
  Copyright The Linux Foundation
190190

191191
Licensed under the Apache License, Version 2.0 (the "License");
192192
you may not use this file except in compliance with the License.

README.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,3 @@ const asyncapi = versions['1.1.0'];
3737

3838
// Do something with the schema.
3939
```
40-
41-
## Author
42-
43-
Fran Méndez – [www.fmvilas.com](https://www.fmvilas.com)

package-lock.json

Lines changed: 3 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,6 @@
66
"scripts": {
77
"test": "nyc mocha",
88
"release": "semantic-release",
9-
"get:version": "echo $npm_package_version",
10-
"get:name": "echo $npm_package_name",
119
"generate:assets": "echo 'No additional assets need to be generated at the moment'",
1210
"lint": "echo 'No linter integrated yet'",
1311
"bump:version": "npm --no-git-tag-version --allow-same-version version $VERSION"
@@ -48,7 +46,7 @@
4846
"branches": [
4947
"master",
5048
{
51-
"name": "2021-06-release",
49+
"name": "2021-09-release",
5250
"prerelease": true
5351
}
5452
],

0 commit comments

Comments
 (0)