Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Jan 29, 2026

Establishes a TypeScript npm package template for Welcomer Bot utilities with automated publishing to GitHub Packages.

Package Structure

  • TypeScript package @welcomer-bot/utils configured for GitHub Packages registry
  • 8 text parser utilities: Discord mention parsing, markdown escaping, text manipulation
  • Full type definitions and CommonJS exports
  • TypeScript configured to target ES2022

Testing

  • Jest framework with 25 unit tests covering all utilities
  • Coverage reporting configured

CI/CD Pipelines

  • CI workflow: Runs tests, linting, and builds on Node.js LTS versions (20.x, 22.x) for all PRs and main branch pushes
  • Publish workflow: Automatically publishes to GitHub Packages on release creation using GITHUB_TOKEN with Node.js 22.x

Usage Example

import { parseMention, escapeMarkdown } from '@welcomer-bot/utils';

const userId = parseMention('<@123456789>');  // '123456789'
const safe = escapeMarkdown('*bold* text');    // '\\*bold\\* text'

To publish new versions, create a GitHub release with a version tag (e.g., v1.0.0). The publish workflow handles build and deployment.

Original prompt

Create a package that will be a github packages with a template for utilities functions, make tests and a ci to automaticly publish versions


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Copilot AI and others added 3 commits January 29, 2026 12:46
Co-authored-by: clementvt <47658318+clementvt@users.noreply.github.com>
Co-authored-by: clementvt <47658318+clementvt@users.noreply.github.com>
Co-authored-by: clementvt <47658318+clementvt@users.noreply.github.com>
Copilot AI changed the title [WIP] Create GitHub package for utility functions with CI Initialize utilities package with GitHub Packages publishing and CI/CD Jan 29, 2026
Copilot AI requested a review from clementvt January 29, 2026 12:50
@clementvt clementvt marked this pull request as ready for review January 30, 2026 13:04
Copy link
Member

@clementvt clementvt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use node lts versions in github workflows, also update tsconfig to latest verision

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change node version to latest version

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@copilot fix

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated Node.js versions to 20.x and 22.x (latest LTS versions). Commit: 2a494f9

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CI workflow updated with Node.js LTS versions (20.x, 22.x). Commit: 2a494f9

…ES2022

Co-authored-by: clementvt <47658318+clementvt@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Jan 30, 2026

Use node lts versions in github workflows, also update tsconfig to latest verision

Updated workflows to use Node.js LTS versions 20.x and 22.x, and updated tsconfig to target ES2022. Commit: 2a494f9

Copilot AI requested a review from clementvt January 30, 2026 13:25
@clementvt clementvt merged commit 22e4bfb into main Jan 30, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants