@openbox/shared-types
v0.6.13
Published
Shared Types for Openbox Cloud.
Readme
Quick Start
Requirements
- NodeJS 16.19.0 (preferiblemente NVM)
- Yarn
Ejecutar los siguientes comandos
Cambiar a NodeJS 16.19.0
nvm use v16.19.0Instalar Yarn globalmente
npm install -g yarnInstalar dependencias y inicializar hooks
$ yarn install && yarn husky installCI/CD
Automatic NPM Publishing
This repository includes a GitHub Action workflow that automatically publishes the package to NPM when changes are merged into the development branch.
Workflow Overview
- Trigger: Pushes to
developmentbranch - Build Process: Install dependencies, run linting, formatting checks, and build the package
- Publishing: Automatically publishes to NPM registry if the version doesn't already exist
- Version Management: Checks if the current package.json version exists on NPM before publishing
Setup Requirements
- NPM Token: Add
NPM_TOKENsecret to repository settings with a valid NPM authentication token - Version Management: Update version in
package.jsonbefore merging to development branch - Package Access: The workflow publishes with
--access publicfor scoped packages
Workflow Steps
Build Job:
- Checkout code
- Setup Node.js 16.19.0
- Install dependencies with frozen lockfile
- Run linting (
yarn lint) - Run formatting check (
yarn format:check) - Build package (
yarn build) - Upload build artifacts
Publish Job:
- Download build artifacts
- Check if version exists on NPM
- Publish to NPM (if version is new)
- Skip publishing if version already exists
Manual Publishing
If you need to publish manually:
# Build the package
yarn build
# Publish to NPM
npm publish --access public