diff --git a/README.md b/README.md index fcf8e0b..4817c41 100644 --- a/README.md +++ b/README.md @@ -5,9 +5,11 @@ This action allows you to auto-invite people to your org. after they open an issue, with a specific label. ### How to use + - Go to your repository - Create a folder named `.github` and create a `workflows` folder inside it if it doesn't exist. - Create a new file named `invitation.yml` with the following contents inside the `workflows` folder: + ```yml on: issues: @@ -26,16 +28,16 @@ jobs: comment: 'Welcome to the Org.' env: INVITE_TOKEN: ${{ secrets.INVITE_TOKEN }} -``` +``` - Replace the `organization` name to put in name of your org, replace the `label` with name of the label with which you want this action to be triggered. - Replace `comment` with the message you want the github-actions bot to send after an invite is sent. -- **NOTE:** create a [personal access token](https://github.com/settings/tokens/new) called _`INVITE_TOKEN`_ _(or give it another name, but don't forget to change it in the workflow)_ with the scope of _`admin:org`_ and set the expiration date as _`No expiration`_ _(If you don't want to regenerate token again)_ +- **NOTE:** create a [personal access token](https://github.com/settings/tokens/new) called _`INVITE_TOKEN`_ _(or give it another name, but don't forget to change it in the workflow)_ with the scope of _`admin:org`_ and set the expiration date as _`No expiration`_ _(If you don't want to regenerate token again)_ ![Give admin:org access to the token](https://user-images.githubusercontent.com/43115551/109795252-b450ac80-7c3c-11eb-8de7-5dc5d600f82e.png) - Copy the generated token and navigate to your org's secrets(`Organization Settings > Secrets`) and create a `New Organization Secret` with the Name as `INVITE_TOKEN` and the value as the token that you copied in the previous step. -`https://github.com/organizations/*your-org-name*/settings/secrets/actions` + `https://github.com/organizations/*your-org-name*/settings/secrets/actions` - You don't worry about the `GITHUB_TOKEN`, It will be given by GitHub ### Note: @@ -48,19 +50,25 @@ jobs: > Default comment: `Invitation sent for the GitHub Organisation. Welcome to the community` +**_existingMemberMessage_** _(optional)_ Message for existing organisation members + +> Default Message: `You are already a member of our Organisation.` ### Examples + - [EddieHub invitation Workflow](https://github.com/EddieHubCommunity/support/blob/main/.github/workflows/invitation.yml) ### Contributing -Please see [`CONTRIBUTING.md`](./CONTRIBUTING.md) for getting started with the contribution. Make sure that you follow [`CODE_OF_CONDUCT.md`](./CODE_OF_CONDUCT.md) while contributing and engaging in the discussions. **When contributing, please first discuss the change you wish to make via an issue on this repository before making the actual change.** - +Please see [`CONTRIBUTING.md`](./CONTRIBUTING.md) for getting started with the contribution. Make sure that you follow [`CODE_OF_CONDUCT.md`](./CODE_OF_CONDUCT.md) while contributing and engaging in the discussions. **When contributing, please first discuss the change you wish to make via an issue on this repository before making the actual change.** #### ToDo- + - [ ] Better Docs - [ ] Fix bugs, if any + #### Bugs- + If you feel any difficulty in usage or notice a bug, don't forget to [open a new issue](https://github.com/vj-abigo/invite-on-label/issues/new). ### Contributors diff --git a/action.yml b/action.yml index c7c35e9..855cdc8 100644 --- a/action.yml +++ b/action.yml @@ -21,7 +21,7 @@ inputs: existingMemberMessage: description: Message for existing organisation members required: false - default: You are already the member of our Organisation. + default: You are already a member of our Organisation. runs: using: node12 main: dist/index.js