Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: update release branch #901

Merged
merged 19 commits into from
Jan 31, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
4ed4055
feat: release for version 2.5.0 of the spec (#842)
char0n Sep 29, 2022
949a9ff
chore: add Sergio and Vladimir as code owners (#846)
fmvilas Oct 10, 2022
529cc06
ci: update generic workflows (#851)
asyncapi-bot Oct 25, 2022
6476aaf
ci: update generic workflows (#855)
asyncapi-bot Oct 25, 2022
d110932
ci: update generic workflows (#857)
asyncapi-bot Oct 25, 2022
f2e0ed7
ci: update generic workflows (#866)
asyncapi-bot Oct 27, 2022
8912e4b
chore(deps): bump @actions/core from 1.6.0 to 1.9.1 in /.github/workf…
dependabot[bot] Oct 27, 2022
9549230
docs: set proper indentation for the TOC (#853)
smoya Oct 28, 2022
226447a
ci: update generic workflows (#871)
asyncapi-bot Nov 9, 2022
d5c8960
ci: remove not needed workflow (#872)
codingtenshi Nov 14, 2022
eb8bb65
chore: fix example for operation security (#873)
derberg Nov 17, 2022
90e6a99
chore: update asyncapi versions in the social-media example (#876)
magicmatatjahu Nov 22, 2022
77cb157
ci: update generic workflows (#877)
asyncapi-bot Nov 23, 2022
1e3ec47
ci: update generic workflows (#879)
asyncapi-bot Dec 6, 2022
95643a7
docs: update readme, add sponsors section, review requested (#886)
AnimeshKumar923 Dec 19, 2022
6c252c2
docs: fix websocket-gemini message's payload example (#884)
magicmatatjahu Dec 20, 2022
143ddd0
ci: update generic workflows (#897)
asyncapi-bot Jan 30, 2023
8087fee
chore(deps): bump cookiejar from 2.1.3 to 2.1.4 in /.github/workflows…
dependabot[bot] Jan 30, 2023
093549f
Merge branch 'master' of https://github.com/AceTheCreator/spec into n…
AceTheCreator Jan 31, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 15 additions & 14 deletions .github/workflows/add-good-first-issue-labels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,27 +4,28 @@
# Purpose of this workflow is to enable anyone to label issue with 'Good First Issue' and 'area/*' with a single command.
name: Add 'Good First Issue' and 'area/*' labels # if proper comment added

on:
issue_comment:
types:
- created
on:
issue_comment:
types:
- created

jobs:
add-labels:
if: ${{!github.event.issue.pull_request && github.event.issue.state != 'closed' && github.actor != 'asyncapi-bot'}}
if: ${{(!github.event.issue.pull_request && github.event.issue.state != 'closed' && github.actor != 'asyncapi-bot') && (contains(github.event.comment.body, '/good-first-issue') || contains(github.event.comment.body, '/gfi' ))}}
runs-on: ubuntu-latest
steps:
- name: Add label
if: contains(github.event.comment.body, '/good-first-issue') || contains(github.event.comment.body, '/gfi' )
uses: actions/github-script@v5
with:
github-token: ${{ secrets.GH_TOKEN }}
script: |
const areas = ['javascript', 'typescript', 'java' , 'go', 'docs', 'ci-cd', 'design'];
const values = context.payload.comment.body.trim().split(" ");
switch(values[1]){
const words = context.payload.comment.body.trim().split(" ");
const areaIndex = words.findIndex((word)=> word === '/gfi' || word === '/good-first-issue') + 1
let area = words[areaIndex];
switch(area){
case 'ts':
values[1] = 'typescript';
area = 'typescript';
break;
case 'js':
values[1] = 'javascript';
Expand All @@ -33,7 +34,7 @@ jobs:
values[1] = 'docs';
break;
}
if(values.length != 2 || !areas.includes(values[1])){
if(!areas.includes(area)){
const message = `Hey @${context.payload.sender.login}, your message doesn't follow the requirements, you can try \`/help\`.`

await github.rest.issues.createComment({
Expand All @@ -44,14 +45,14 @@ jobs:
})
} else {

//remove complexity and areas if there are any before adding new labels;
// remove area if there is any before adding new labels.
const currentLabels = (await github.rest.issues.listLabelsOnIssue({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
})).data.map(label => label.name);

const shouldBeRemoved = currentLabels.filter(label => (label.startsWith('area/') && !label.endsWith(values[1])));
const shouldBeRemoved = currentLabels.filter(label => (label.startsWith('area/') && !label.endsWith(area));
shouldBeRemoved.forEach(label => {
github.rest.issues.deleteLabel({
owner: context.repo.owner,
Expand All @@ -60,11 +61,11 @@ jobs:
});
});

//add new labels
// Add new labels.
github.rest.issues.addLabels({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
labels: ['good first issue', `area/${values[1]}`]
labels: ['good first issue', `area/${area}`]
});
}
12 changes: 12 additions & 0 deletions .github/workflows/scripts/mailchimp/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.