diff --git a/.github/ISSUE_TEMPLATE/meeting.md b/.github/ISSUE_TEMPLATE/meeting.md index 7122465..b7adb00 100644 --- a/.github/ISSUE_TEMPLATE/meeting.md +++ b/.github/ISSUE_TEMPLATE/meeting.md @@ -35,5 +35,5 @@ Extracted from **<%= agendaLabel %>** labelled issues and pull requests from **< ### Joining the meeting -* link for participants: +* link for participants: <%= meetingLink %> * For those who just want to watch: diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index ae08d8f..b507a21 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -38,6 +38,7 @@ jobs: createWithin: P2D meetingLabels: test agendaLabel: meeting-agenda-test + meetingLink: https://github.com/pkgjs/meet createNotes: true repos: pkgjs/meet,pkgjs/meet orgs: pkgjs diff --git a/action.yml b/action.yml index 9120023..ea9b12f 100644 --- a/action.yml +++ b/action.yml @@ -19,6 +19,9 @@ inputs: description: 'The labels to apply to issues generated by this GitHub Action for meetings. Default: "meeting"' default: 'meeting' required: false + meetingLink: + description: 'An optional meeting join link' + required: false agendaLabel: description: 'The label used to identify agenda items within the same repository. Default: "meeting-agenda"' default: 'meeting-agenda' diff --git a/lib/conversions.js b/lib/conversions.js index 6a6d2c4..aa8366f 100644 --- a/lib/conversions.js +++ b/lib/conversions.js @@ -5,7 +5,8 @@ const inputs = { title: core.getInput('issueTitle'), agendaLabel: core.getInput('agendaLabel'), invitees: core.getInput('invitees'), - observers: core.getInput('observers') + observers: core.getInput('observers'), + meetingLink: core.getInput('meetingLink') } // template keys and values that we automagically replace in @@ -15,13 +16,15 @@ const templates = { title: '', agendaLabel: '', invitees: '', - observers: '' + observers: '', + meetingLink: '' }, values: { title: inputs.issueTitle, agendaLabel: inputs.agendaLabel, invitees: inputs.invitees, - observers: inputs.observers + observers: inputs.observers, + meetingLink: inputs.meetingLink } } diff --git a/lib/default-template.js b/lib/default-template.js index 9ff078e..9edd7fe 100644 --- a/lib/default-template.js +++ b/lib/default-template.js @@ -1,6 +1,6 @@ 'use strict' -module.exports = ({ date, agendaIssues, agendaLabel, meetingNotes, owner, repo }) => { +module.exports = ({ date, agendaIssues, agendaLabel, meetingNotes, owner, repo, meetingLink }) => { return ` ## Date/Time @@ -39,6 +39,6 @@ ${agendaIssues.map((i) => { ### Joining the meeting -* link for participants: +* link for participants: ${meetingLink || ''} * For those who just want to watch:` } diff --git a/lib/meetings.js b/lib/meetings.js index 3286612..6bcc5cc 100644 --- a/lib/meetings.js +++ b/lib/meetings.js @@ -29,6 +29,7 @@ function getNextIssue (opts) { date, agendaLabel: opts.agendaLabel, agendaIssues: opts.agendaIssues, + meetingLink: opts.meetingLink, labels: opts.meetingLabels, meetingNotes: opts.meetingNotes || '', issue_number: (opts.issue || {}).number || null, diff --git a/run.js b/run.js index 9de0728..0b7993d 100644 --- a/run.js +++ b/run.js @@ -33,6 +33,8 @@ const pkg = require('./package.json') const createNotes = core.getInput('createNotes') const notesUserTemplate = core.getInput('notesTemplate') + const meetingLink = core.getInput('meetingLink') + // Get list of repos let repos = core.getInput('repos') const repo = github.context.repo @@ -115,6 +117,7 @@ const pkg = require('./package.json') meetingLabels, createWithin, agendaLabel, + meetingLink, agendaIssues, issueTitle: titleTemplate }