feat: added action #251
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# File location: .github/workflows/greetings.yml | |
name: Greetings Workflow with Auto-Assign | |
on: # Trigger events | |
push: | |
branches: [main] | |
issues: | |
types: [opened] # Trigger on issue opened | |
pull_request_target: | |
types: [opened] # Trigger on pull request opened | |
jobs: | |
greet-and-assign: | |
runs-on: ubuntu-latest # The environment | |
steps: | |
- name: Checkout repository content | |
uses: actions/checkout@v3 # Checks out the repository | |
- name: Run greeting and assign action | |
uses: ./ # This points to the root directory where action.yml resides | |
with: | |
github-token: ${{ secrets.GITHUB_TOKEN }} # GitHub authentication | |
issue-message: 'Welcome, @{{ github.actor }}! Thanks for opening this issue!' | |
pr-message: 'Great job, @{{ github.actor }}! Thanks for the pull request!' | |
footer: 'The maintainers will review your request soon. Stay tuned!' | |
assign-user: 'username-to-assign' # You can replace this with any username or GitHub handle |