Skip to content

[Nomination] Nour Majdoub #278

[Nomination] Nour Majdoub

[Nomination] Nour Majdoub #278

Workflow file for this run

name: "Auto-Comment on Nomination Issues"
on:
issues:
types: [opened]
jobs:
comment-on-issue:
runs-on: ubuntu-latest
steps:
- name: Add Welcome Comment Based on Program
uses: actions/github-script@v6
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
const issue = context.payload.issue;
const labels = issue.labels.map(label => label.name.toLowerCase());
const issueNumber = issue.number;
const repoOwner = context.repo.owner;
const repoName = context.repo.repo;
let programName = "PyTorch Foundation Program";
let programDocs = "https://github.com/pytorch-fdn/foundation-programs";
let commentBody = "";
if (labels.includes("ambassador")) {
programName = "PyTorch Ambassador Program";
programDocs = "https://github.com/pytorch-fdn/ambassador-program/blob/main/README.md";
commentBody = [
`πŸ‘‹ Thank you for submitting a nomination for the **${programName}**! πŸŽ‰`,
"",
"Your nomination is currently under review. A team member will evaluate the submission and update the status accordingly.",
"",
"πŸ”Ή **Review Process & Next Steps:**",
"1️⃣ Initial Review – The nomination will be reviewed by the team.",
"2️⃣ Scoring & Selection – Reviewers will assign scores based on eligibility and impact.",
"3️⃣ One-on-One Review – If shortlisted, the nominee will have a session with the Executive Director.",
"4️⃣ Final Decision – Selected ambassadors will receive an **official invitation**. βœ…",
"",
`πŸ“– Program Details: [View Documentation](${programDocs})`,
"",
"πŸ’¬ Have questions? Please submit a [Feedback or Inquiry](https://github.com/pytorch-fdn/foundation-initiative/issues/new?template=feedback.yml) and reference this nomination issue number.",
"",
"Thank you for helping grow the PyTorch community! πŸš€"
].join("\n\n");
} else if (labels.includes("speakers-bureau")) {
programName = "Speakers Bureau Program";
programDocs = "https://github.com/pytorch-fdn/foundation-programs/blob/main/speakers-bureau/README.md";
commentBody = [
`πŸ‘‹ Thank you for submitting a nomination for the **${programName}**! 🎀`,
"",
"Your nomination is currently being reviewed. A team member will evaluate the speaker’s background, proposed topics, and fit for upcoming events.",
"",
`πŸ“– Program Details: [View Documentation](${programDocs})`,
"",
"πŸ’¬ Have questions? Please submit a [Feedback or Inquiry](https://github.com/pytorch-fdn/foundation-initiative/issues/new?template=feedback.yml) and reference this issue.",
"",
"We appreciate your effort to support PyTorch education and visibility worldwide! 🌍"
].join("\n\n");
} else if (labels.includes("ospo-outreach")) {
programName = "OSPO Outreach Program";
programDocs = "https://github.com/pytorch-fdn/foundation-programs/blob/main/ospo-outreach/README.md";
commentBody = [
`πŸ‘‹ Thank you for your submission to the **${programName}**! πŸ§ͺ`,
"",
"Your outreach proposal is under review. The team will evaluate the research goals, scope, and alignment with PyTorch Foundation priorities.",
"",
`πŸ“– Program Details: [View Documentation](${programDocs})`,
"",
"πŸ’¬ Have questions? Please submit a [Feedback or Inquiry](https://github.com/pytorch-fdn/foundation-initiative/issues/new?template=feedback.yml) and reference this issue.",
"",
"Thank you for advancing open-source AI and ML innovation with us! 🀝"
].join("\n\n");
} else {
commentBody = [
`πŸ‘‹ Thank you for submitting to the **${programName}**!`,
"",
`Your submission is under review. Please refer to our [documentation](${programDocs}) for next steps.`,
"",
"If you have questions, submit a [Feedback Issue](https://github.com/pytorch-fdn/foundation-initiative/issues/new?template=feedback.yml) and include this issue number."
].join("\n\n");
}
await github.rest.issues.createComment({
owner: repoOwner,
repo: repoName,
issue_number: issueNumber,
body: commentBody
});