Skip to content

Commit 2688684

Browse files
author
Vasudev Jaiswal
authored
Update invitation.yml
1 parent 26765a6 commit 2688684

File tree

1 file changed

+17
-11
lines changed

1 file changed

+17
-11
lines changed

.github/workflows/invitation.yml

Lines changed: 17 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -13,27 +13,33 @@ jobs:
1313
label: 'invite me to the organization'
1414
repo-token: ${{ secrets.GITHUB_TOKEN }}
1515
comment: |
16-
It's great having you contribute to this project. If you would like to continue contributing to open source and want to be part of an awesome and inclusive community, consider joining our GitHub Organisation and Discord Server. We help and encourage each other to contribute to open source little and often 🤓. Any questions, feel free to ask!
17-
18-
<b>Invitation sent to join the GitHub Organisation. Welcome to the community 🎉</b><br><br>
19-
Don't forget after accepting to make it public so it appears on your GitHub profile for everyone else to see.
20-
You can do this by finding your name in the GitHub organisation list and changing the dropdown to public
21-
https://github.com/orgs/jaidevstudio/people<br><br>
22-
Tips for practising:<br>It's about collaboration, communication, and adding value<br>I hope that helps
16+
It's great having you contribute to this project. If you would like to continue contributing to open source and would like to do it with an awesome inclusive community, you should join our [Discord Server](https://discord.gg/wXFWgsAuzR) and our [GitHub Organisation](http://github.com/jaidevstudio) - we help and encourage each other to contribute to open source little and often 🤓 . Any questions let us know.
2317
env:
2418
INVITE_TOKEN: ${{ secrets.INVITE_TOKEN }}
2519

26-
- name: Post message and close the issue
20+
- name: Post first comment (Invite details)
2721
run: |
2822
# Get the issue number
2923
ISSUE_NUMBER=$(echo "${{ github.event.issue.number }}")
3024
31-
# Post a message on the issue
25+
# Post first comment (invitation)
3226
curl -X POST -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
33-
-d '{"body": "The invitation has been sent to join the GitHub Organization. The issue will now be closed. Feel free to reach out with any questions!"}' \
27+
-d '{"body": "Invitation sent for the GitHub Organisation. Welcome to the community 🎉\n\nDon\'t forget after accepting to make it public so it appears on your GitHub profile for everyone else to see, you can do this by finding your name in the GitHub organisation list and change the dropdown to public [GitHub Organisation List](https://github.com/orgs/jaidevstudio/people)\n\n![image](https://user-images.githubusercontent.com/91027746/134157300-21905417-9d2e-44e9-9961-e38cd32ae457.png)"}' \
3428
"https://api.github.com/repos/${{ github.repository }}/issues/$ISSUE_NUMBER/comments"
3529
36-
# Close the issue
30+
- name: Post second comment (Tips)
31+
run: |
32+
# Get the issue number
33+
ISSUE_NUMBER=$(echo "${{ github.event.issue.number }}")
34+
35+
# Post second comment (tips)
36+
curl -X POST -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
37+
-d '{"body": "### Tips for practising:\n\nRemember contributing to open source is not just about code, its about collaboration, communication, and adding value\n\nI hope that helps."}' \
38+
"https://api.github.com/repos/${{ github.repository }}/issues/$ISSUE_NUMBER/comments"
39+
40+
- name: Close the issue
41+
run: |
42+
# Close the issue after sending the comments
3743
curl -X PATCH -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
3844
-d '{"state": "closed"}' \
3945
"https://api.github.com/repos/${{ github.repository }}/issues/$ISSUE_NUMBER"

0 commit comments

Comments
 (0)