Skip to content

Set up TypeScript project infrastructure for HACS action - #49

Closed
ludeeus wants to merge 2 commits into
mainfrom
claude/sharp-wozniak-eyyrxc
Closed

ludeeus wants to merge 2 commits into
mainfrom
claude/sharp-wozniak-eyyrxc

Conversation

@ludeeus

@ludeeus ludeeus commented Oct 16, 2026 •

Copy link
Copy Markdown
Member

Summary

This PR establishes the foundational project structure and tooling for the HACS action, converting it to a TypeScript-based implementation with a complete development and CI/CD pipeline.

Key Changes

  • CI/CD Pipeline: Added GitHub Actions workflow (.github/workflows/ci.yml) that runs linting, formatting checks, type checking, tests, and builds on every push and pull request to main
  • TypeScript Configuration: Added tsconfig.json with strict type checking enabled and ES2024 as the target
  • Build System: Implemented esbuild-based bundling (scripts/build.mjs) that compiles TypeScript to ESM with CommonJS compatibility shim
  • Linting & Formatting: Configured ESLint with TypeScript support and Prettier for code formatting
  • Package Configuration: Created package.json with all necessary dependencies and npm scripts for development workflow
  • NPM Configuration: Added .npmrc to enforce exact dependency versions
  • Dependency Management: Extended Dependabot configuration to monitor npm dependencies
  • Initial Implementation: Added minimal src/main.ts entry point using @actions/core
  • Git Configuration: Updated .gitignore to exclude node_modules/ and dist/ directories

Notable Implementation Details

  • The build process includes a banner that injects createRequire to support CommonJS dependencies in ESM output
  • Node.js 24 is specified for both the build environment and runtime target
  • All npm dependencies are pinned to exact versions for reproducibility
  • The project uses modern tooling: TypeScript 6.0, ESLint 10, Vitest 5, and esbuild 0.28

Set up the tooling for moving the validation logic into this
repository: esbuild bundling, strict TypeScript, Vitest, ESLint and
Prettier, a CI workflow and npm updates through Dependabot. The
entry point is a placeholder, and action.yml still runs the Docker
image.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Uy8sjiJDFtdc39e6CDBUN4
Add save-exact to .npmrc so later installs pin as well.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Uy8sjiJDFtdc39e6CDBUN4
Copilot AI balanced review requested due to automatic review settings October 16, 2026 14:46

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟢 Approval recommended

The infrastructure scaffold is internally consistent, leaves the existing runtime unchanged, and has no identified blocking issues.

0 open findings

What changed in this PR

Adds TypeScript development infrastructure for the HACS action without changing the existing action runtime.

Changes:

  • Adds a placeholder entry point and Node.js 24 ESM bundling.
  • Configures type checking, linting, formatting, and test tooling.
  • Adds CI checks, pinned dependencies, and npm Dependabot updates.
File Description
tsconfig.json Enables strict TypeScript checking.
src/​main.ts Adds a placeholder entry point.
scripts/​build.mjs Bundles ESM with CommonJS compatibility.
package.json Defines dependencies and development commands.
package-lock.json Locks dependency resolutions.
eslint.config.mjs Configures JavaScript and TypeScript linting.
.npmrc Saves exact dependency versions.
.gitignore Excludes dependencies and build output.
.github/​workflows/​ci.yml Runs checks and builds on main pushes and PRs.
.github/​dependabot.yml Adds daily npm dependency updates.

🧠 Review effort: Balanced


💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@ludeeus
ludeeus marked this pull request as draft October 18, 2026 18:16
@ludeeus ludeeus closed this Oct 18, 2026
@ludeeus
ludeeus deleted the claude/sharp-wozniak-eyyrxc branch October 18, 2026 18:22
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.

3 participants