Skip to content

Delete test

Delete test #18

Workflow file for this run

name: Greetings
on:
issues:
types: [opened]
pull_request:
types: [opened]
push:
branches:
- main
jobs:
greeting:
runs-on: ubuntu-latest
permissions:
issues: write
pull-requests: write
contents: read
steps:
- name: Issue Greeting
if: github.event_name == 'issues' && github.event.action == 'opened'
run: |
MESSAGE="Welcome to our project! 🎉 Thank you for opening your issue, @${{ github.actor }}! To help us assist you effectively, please include the following details:
- **Description**: Clearly describe the problem or feature you’re suggesting.
- **Steps to Reproduce**: If you're reporting a bug, list the steps to reproduce it.
- **Expected vs. Actual Behavior**: Explain what you expected to happen and what actually occurred.
- **Environment**: Include information about your environment (e.g., OS, version, browser).
- **Screenshots**: If applicable, attach screenshots or logs to illustrate the issue.
If you need further assistance, feel free to [Contact me](https://formsubmit.co/el/sumuhu).
Your feedback is invaluable in improving our project, and we appreciate your contribution!"
curl -X POST -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
-d "{\"body\": \"$MESSAGE\"}" \
"https://api.github.com/repos/${{ github.repository }}/issues/${{ github.event.issue.number }}/comments"
- name: Pull Request Greeting
if: github.event_name == 'pull_request' && github.event.action == 'opened'
run: |
MESSAGE="Amazing! You've submitted your first pull request, @${{ github.actor }}! 🎉 Thank you for your contribution. Here are a few things to keep in mind:
- **Description**: Ensure your pull request includes a clear description of what changes you made and why.
- **Related Issues**: Link any related issues to provide context.
- **Testing**: Describe any tests you’ve run to verify your changes and ensure nothing is broken.
- **Code Guidelines**: Please ensure your code adheres to our coding standards and formatting rules.
- **Review Process**: Once you submit, our team will review your changes. We may ask for adjustments, so keep an eye on any comments.
If you have any questions or need assistance, don’t hesitate to [Contact me](https://formsubmit.co/el/sumuhu).
Your efforts help us enhance the project, and we’re excited to work with you!"
curl -X POST -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
-d "{\"body\": \"$MESSAGE\"}" \
"https://api.github.com/repos/${{ github.repository }}/pulls/${{ github.event.pull_request.number }}/comments"
- name: Push Notification
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
run: |
MESSAGE="A new push has been made to the main branch by @${{ github.actor }}. Thank you for your contribution!
Please remember to include detailed information in any issues or pull requests you create. This helps us address your concerns quickly and effectively.
If you would like to share additional information or if you have any questions, please reach out via this [Contact me](https://formsubmit.co/el/sumuhu) form."
# Create a new issue for push notifications
curl -X POST \
-H "Accept: application/vnd.github+json" \
-H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
-H "X-GitHub-Api-Version: 2022-11-28" \
"https://api.github.com/repos/${{ github.repository }}/issues" \
-d "{\"title\":\"New Push Notification by @${{ github.actor }}\", \"body\":\"$MESSAGE\"}"