Skip to content

Comments

feat(npm): add npm packages#45

Merged
jackchuka merged 1 commit intomainfrom
feat/npm-publish
Feb 22, 2026
Merged

feat(npm): add npm packages#45
jackchuka merged 1 commit intomainfrom
feat/npm-publish

Conversation

@jackchuka
Copy link
Owner

This pull request adds official npm packaging and publishing support for the mdschema tool, enabling users to install and run mdschema via npm across all major platforms (macOS, Linux, Windows, both x64 and arm64). It introduces per-platform npm packages containing pre-built binaries, a main npm package with a cross-platform CLI, and an automated GitHub Actions workflow to build and publish these packages on release. The documentation is also updated to describe npm installation and usage.

NPM packaging and distribution:

  • Adds per-platform npm packages (e.g., @jackchuka/mdschema-darwin-arm64, @jackchuka/mdschema-linux-x64, etc.) that each ship a pre-built mdschema binary for their respective OS/architecture. [1] [2] [3] [4] [5] [6]
  • Adds the main @jackchuka/mdschema npm package, which depends on all platform-specific packages as optional dependencies and provides a CLI entry point.
  • Implements a Node.js installer script (install.js) and platform detection logic (lib/platform.js) in the main package to select the correct binary or download it if necessary. [1] [2]

Release automation:

  • Updates the GitHub Actions workflow to build, version, and publish all npm packages automatically on release, including extracting binaries from GitHub releases and updating dependency versions.
  • Updates GoReleaser config to ensure archives are created in the correct format for each platform (tar.gz for Unix, zip for Windows).

Documentation:

  • Updates the README.md to document npm installation and usage, including global install and npx usage examples.

@jackchuka jackchuka marked this pull request as ready for review February 22, 2026 16:33
@jackchuka jackchuka merged commit c282027 into main Feb 22, 2026
1 check passed
@jackchuka jackchuka deleted the feat/npm-publish branch February 22, 2026 16:33
tmeijn pushed a commit to tmeijn/dotfiles that referenced this pull request Feb 25, 2026
This MR contains the following updates:

| Package | Update | Change |
|---|---|---|
| [jackchuka/mdschema](https://github.com/jackchuka/mdschema) | minor | `v0.11.2` → `v0.12.3` |

MR created with the help of [el-capitano/tools/renovate-bot](https://gitlab.com/el-capitano/tools/renovate-bot).

**Proposed changes to behavior should be submitted there as MRs.**

---

### Release Notes

<details>
<summary>jackchuka/mdschema (jackchuka/mdschema)</summary>

### [`v0.12.3`](https://github.com/jackchuka/mdschema/releases/tag/v0.12.3)

[Compare Source](jackchuka/mdschema@v0.12.2...v0.12.3)

#### What's Changed

- fix(npm): include bin/cli.js in published package by [@&#8203;jackchuka](https://github.com/jackchuka) in [#&#8203;47](jackchuka/mdschema#47)

**Full Changelog**: <jackchuka/mdschema@v0.12.2...v0.12.3>

### [`v0.12.2`](https://github.com/jackchuka/mdschema/releases/tag/v0.12.2)

[Compare Source](jackchuka/mdschema@v0.12.1...v0.12.2)

#### What's Changed

- fix: npm bin url by [@&#8203;jackchuka](https://github.com/jackchuka) in [#&#8203;46](jackchuka/mdschema#46)

**Full Changelog**: <jackchuka/mdschema@v0.12.0...v0.12.2>

### [`v0.12.1`](https://github.com/jackchuka/mdschema/releases/tag/v0.12.1)

[Compare Source](jackchuka/mdschema@v0.12.0...v0.12.1)

#### Changelog

- [`c282027`](jackchuka/mdschema@c282027) feat(npm): add npm packages ([#&#8203;45](jackchuka/mdschema#45))

### [`v0.12.0`](https://github.com/jackchuka/mdschema/releases/tag/v0.12.0)

[Compare Source](jackchuka/mdschema@v0.11.2...v0.12.0)

#### What's Changed

- feat(npm): add npm packages by [@&#8203;jackchuka](https://github.com/jackchuka) in [#&#8203;45](jackchuka/mdschema#45)

**Full Changelog**: <jackchuka/mdschema@v0.11.2...v0.12.0>

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

♻ **Rebasing**: Whenever MR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this MR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this MR, check this box

---

This MR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0My4zMS45IiwidXBkYXRlZEluVmVyIjoiNDMuMzEuOSIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOlsiUmVub3ZhdGUgQm90IiwiYXV0b21hdGlvbjpib3QtYXV0aG9yZWQiLCJkZXBlbmRlbmN5LXR5cGU6Om1pbm9yIl19-->
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.

1 participant