diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml index 04d4447..11831f7 100644 --- a/.github/ISSUE_TEMPLATE/config.yml +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -6,6 +6,9 @@ contact_links: - name: Join our Discord url: https://hivecommons.dev/discord about: Ask setup, contributor, and community questions in the Hive Commons Discord. + - name: Watch the hive live on Twitch + url: https://www.twitch.tv/hivecommons + about: Live stream of the hosted hive's Activity Monitor — see issues and PRs move through the pipeline in real time. - name: Propose a project to join Hive Commons url: https://github.com/hivecommons/.github/issues/new?template=join-hive-commons.yml about: Project proposals for the Hive Commons family are handled in the hivecommons/.github repository. diff --git a/README.md b/README.md index 865c5da..96bdfd9 100644 --- a/README.md +++ b/README.md @@ -593,6 +593,7 @@ promptargs is part of [Hive Commons](https://hivecommons.dev), a family of tools - Want to contribute? See [CONTRIBUTING.md](CONTRIBUTING.md) for setup, checks, and pull request guidelines. - Found a bug or have an idea? Open an [issue](https://github.com/hivecommons/promptargs/issues). +- Have a question? Ask on [Discord](https://hivecommons.dev/discord), or watch the hive live on [Twitch](https://www.twitch.tv/hivecommons). - Reporting a security vulnerability? Follow [SECURITY.md](SECURITY.md) to report it privately, not through public issues. - Please follow the [Hive Commons Code of Conduct](https://github.com/hivecommons/.github/blob/main/CODE_OF_CONDUCT.md). diff --git a/changelog.d/changed-414-community-links.md b/changelog.d/changed-414-community-links.md new file mode 100644 index 0000000..de59637 --- /dev/null +++ b/changelog.d/changed-414-community-links.md @@ -0,0 +1 @@ +README and the issue chooser link the Hive Commons Discord and Twitch live stream. (#414) diff --git a/dist/community.test.d.ts b/dist/community.test.d.ts new file mode 100644 index 0000000..cb0ff5c --- /dev/null +++ b/dist/community.test.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/dist/community.test.js b/dist/community.test.js new file mode 100644 index 0000000..3ae1664 --- /dev/null +++ b/dist/community.test.js @@ -0,0 +1,25 @@ +import { test } from 'node:test'; +import assert from 'node:assert'; +import { readFileSync } from 'node:fs'; +import { join, dirname } from 'node:path'; +import { fileURLToPath } from 'node:url'; +const ROOT = join(dirname(fileURLToPath(import.meta.url)), '..'); +// The Hive Commons community links (hivecommons/promptargs#414) must +// stay reachable from both places newcomers land: the README npm renders and +// the GitHub "New issue" chooser. +const LINKS = ['https://hivecommons.dev/discord', 'https://www.twitch.tv/hivecommons']; +test('README Contributing & Community section links Discord and Twitch', () => { + const readme = readFileSync(join(ROOT, 'README.md'), 'utf-8'); + const start = readme.indexOf('## Contributing & Community'); + assert.notStrictEqual(start, -1, 'README lost its "Contributing & Community" section'); + const end = readme.indexOf('\n## ', start + 1); + const section = readme.slice(start, end === -1 ? undefined : end); + for (const url of LINKS) + assert.ok(section.includes(`(${url})`), `README community section is missing ${url}`); +}); +test('issue chooser config lists Discord and Twitch contact links', () => { + const config = readFileSync(join(ROOT, '.github', 'ISSUE_TEMPLATE', 'config.yml'), 'utf-8'); + for (const url of LINKS) + assert.match(config, new RegExp(`^\\s+url: ${url.replace(/[.]/g, '\\.')}$`, 'm'), `config.yml is missing ${url}`); +}); +//# sourceMappingURL=community.test.js.map \ No newline at end of file diff --git a/dist/community.test.js.map b/dist/community.test.js.map new file mode 100644 index 0000000..447def4 --- /dev/null +++ b/dist/community.test.js.map @@ -0,0 +1 @@ +{"version":3,"file":"community.test.js","sourceRoot":"","sources":["../src/community.test.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AACjC,OAAO,MAAM,MAAM,aAAa,CAAC;AACjC,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACvC,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAEzC,MAAM,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,CAAC,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} \ No newline at end of file diff --git a/src/community.test.ts b/src/community.test.ts new file mode 100644 index 0000000..20c183a --- /dev/null +++ b/src/community.test.ts @@ -0,0 +1,26 @@ +import { test } from 'node:test'; +import assert from 'node:assert'; +import { readFileSync } from 'node:fs'; +import { join, dirname } from 'node:path'; +import { fileURLToPath } from 'node:url'; + +const ROOT = join(dirname(fileURLToPath(import.meta.url)), '..'); + +// The Hive Commons community links (hivecommons/promptargs#414) must +// stay reachable from both places newcomers land: the README npm renders and +// the GitHub "New issue" chooser. +const LINKS = ['https://hivecommons.dev/discord', 'https://www.twitch.tv/hivecommons']; + +test('README Contributing & Community section links Discord and Twitch', () => { + const readme = readFileSync(join(ROOT, 'README.md'), 'utf-8'); + const start = readme.indexOf('## Contributing & Community'); + assert.notStrictEqual(start, -1, 'README lost its "Contributing & Community" section'); + const end = readme.indexOf('\n## ', start + 1); + const section = readme.slice(start, end === -1 ? undefined : end); + for (const url of LINKS) assert.ok(section.includes(`(${url})`), `README community section is missing ${url}`); +}); + +test('issue chooser config lists Discord and Twitch contact links', () => { + const config = readFileSync(join(ROOT, '.github', 'ISSUE_TEMPLATE', 'config.yml'), 'utf-8'); + for (const url of LINKS) assert.match(config, new RegExp(`^\\s+url: ${url.replace(/[.]/g, '\\.')}$`, 'm'), `config.yml is missing ${url}`); +});