Skip to content

Publish all packages to npm, Packagist, RubyGems, and pub.dev #43

Description

@yamyr

Spec: Publish All Packages to Registries

Context

All 15 framework packages are built and tested locally, but none have been published to their registries. A publish workflow already exists at .github/workflows/publish.yml that handles the 12 npm packages — it triggers on GitHub release and supports dry-run via workflow_dispatch. The non-npm packages (Laravel/Packagist, Rails/RubyGems, Flutter/pub.dev) are not yet covered by automation.

Current State

Registry Packages CI Automated Status
npm 12 (core, react, vue, svelte, angular, solid, lit, preact, qwik, alpine, vanilla, astro) publish.yml exists 🔴 Not yet published
Packagist 1 (ajentik/doo-iconik-laravel) 🔴 Not yet published
RubyGems 1 (doo_iconik) 🔴 Not yet published
pub.dev 1 (doo_iconik) 🔴 Not yet published

Pre-Publish Checklist

1. npm Org Setup

  • Create @doo-iconik npm org (if not exists)
  • Create npm automation token and add as NPM_TOKEN repo secret

2. Package Metadata Audit

All npm packages need these fields validated before publish:

Field Status
name ✅ All use @doo-iconik/ scope
version ✅ All 1.0.0
license ✅ All MIT
main / module / types / exports ✅ Present in all
files ⚠️ Only includes dist (or src for astro) — LICENSE and README.md are excluded
repository ✅ All correct
keywords ✅ All present

3. LICENSE + README in Published Artifacts

Critical fix needed: No package includes LICENSE or README.md in its files array. npm will not include them in the tarball. Update every package:

// For most packages:
"files": ["dist", "LICENSE", "README.md"]

// For astro:
"files": ["src", "LICENSE", "README.md"]

Also copy LICENSE from root into each package directory (or use npm's automatic root LICENSE detection — but explicit is safer for a monorepo).

4. Core Dependency Resolution

All framework packages use "@doo-iconik/core": "file:../core" for local dev. Before publishing:

  • Change to "@doo-iconik/core": "^1.0.0" in each package's dependencies (or the publish workflow must handle this)
  • Publish core first, then all others
  • The existing publish.yml publishes core first in its loop — verify this works

Publish Sequence

1. core        (no dependencies)
2. All others  (depend on core ^1.0.0)

npm Publish (12 packages)

  • Handled by .github/workflows/publish.yml
  • Triggers on GitHub release creation
  • Uses --access public flag
  • Supports --dry-run via workflow_dispatch

Packagist Publish (Laravel)

  • Register ajentik/doo-iconik-laravel on packagist.org
  • Link GitHub repo for auto-sync
  • Add composer.json version field or use git tags

RubyGems Publish (Rails)

  • cd packages/rails && gem build doo_iconik.gemspec && gem push doo_iconik-1.0.0.gem
  • Or add to publish workflow with GEM_HOST_API_KEY secret

pub.dev Publish (Flutter)

  • cd packages/flutter && dart pub publish
  • Requires Google account verification
  • Add homepage and repository to pubspec.yaml

Files to Change

  • All 12 npm package.json files — add LICENSE, README.md to files; change @doo-iconik/core from file:../core to ^1.0.0
  • Copy root LICENSE into each package directory
  • .github/workflows/publish.yml — add test gate, add --provenance flag
  • Optionally add Packagist/RubyGems/pub.dev publish jobs

Acceptance Criteria

  • @doo-iconik/core installable from npm
  • All 12 npm packages installable and working
  • Each published tarball includes LICENSE and README.md
  • npm install @doo-iconik/react resolves @doo-iconik/core from npm (not file:)
  • Laravel package on Packagist (or documented manual process)
  • Rails gem on RubyGems (or documented manual process)
  • Flutter package on pub.dev (or documented manual process)

Estimated Effort

~3–4 hours (npm setup + publish + non-npm registries)

Refs #1

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions