Skip to main content

@ncfour-us/projen-utils

Project description

projen-utils

This project contains a couple of constructs which are meant to be used with the projen project. These utilities extend existing projen constructs to enable easier development of TypeScript ESM projects/packages as well as handling pre-commit configuration in projen-managed projects.

Badges

GitHub top language GitHub License GitHub Release GitHub commit activity GitHub Issues or Pull Requests GitHub Issues or Pull Requests

GitHub Actions Workflow Status GitHub Actions Workflow Status

NPM Version NPM Last Update NPM Downloads

Table of Contents

Installation

Install using npm, yarn, or pnpm (preferred).

pnpm add --save-dev @ncfour-us/projen-utils

Getting Started

Documentation on constructs.dev: @ncfour-us/projen-utils

Project documentation: @ncfour-us/projen-utils

The TypeScriptESMProject supports both "local" and "Github workflow" styles of build/release handling. (NOTE: "Github workflow" handling is still under development).

Local build and release processing

With "local" style builds/releases, a project is managed from a user's workstation terminal interface, using the pnpm build and pnpm release commands.

Support exists for publishing build artifacts to:

  • "local" archive (a folder on the local workstation)
  • "npm" package registry (the NPM Package registry)
  • "github" creating tagged releases in the associated Github-hosted Git repository

There are some preparatory steps required before publishing to NPM and Github will work.

For publishing to NPM, the package MUST have first been created in NPM by a manual publishing step.

The command to publish to NPM is:

npm publish <file name .tgz file containing the package> --access public

This command will create the package in the NPM registry.

The command to create a Github repository, using the gh GitHub CLI is:

gh repo create ncfour-us/byte-buffer --public --source=. --remote=origin

This command will use the contents of the current folder to create a Git repository on Github and link the remote repository with name origin.

After creating the repository, use git push to link the main branch of the local repository to the main branch in GitHub using command:

git push -u origin main

Once these steps are completed, the publish tasks for NPM and GitHub can be enabled by setting:

    ...
    releaseToNpm: true,
    releaseToGithub: true
    ...

in the constructor options of the TypeScriptESMProject project.

When running pnpm release locally, there is a requirement that the user has active login credentials to both NPM and GitHub. For NPM, 2FA login is required when running a npm publish. If interactive user credentials are being used, the user will be prompted to supply their 2FA login info during the publish:npm task processing.

To login to GitHub, use the gh auth login command. Login status can be checked using the gh auth status command. GitHub login credentials are used during the publish:github task processing.

Contributing

Fork this repository and submit a PR.

Authors

License

The project is covered by the MIT license, see LICENSE.

Acknowledgements

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ncfour_us_projen_utils-0.1.21.tar.gz (156.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ncfour_us_projen_utils-0.1.21-py3-none-any.whl (155.0 kB view details)

Uploaded Python 3

File details

Details for the file ncfour_us_projen_utils-0.1.21.tar.gz.

File metadata

  • Download URL: ncfour_us_projen_utils-0.1.21.tar.gz
  • Upload date:
  • Size: 156.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.14.5

File hashes

Hashes for ncfour_us_projen_utils-0.1.21.tar.gz
Algorithm Hash digest
SHA256 e65097cfc894731a8cef460bc3dd9b971312aa04edde5329cd2710a730565756
MD5 e2d207d0d32e4de0dffcf0e502454249
BLAKE2b-256 8e3fdc2a430da73aedb4d1ee4fe9f158e9e46557f69c973890a9f00dd046b95c

See more details on using hashes here.

Provenance

The following attestation bundles were made for ncfour_us_projen_utils-0.1.21.tar.gz:

Publisher: release.yml on ncfour-us/projen-utils

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file ncfour_us_projen_utils-0.1.21-py3-none-any.whl.

File metadata

File hashes

Hashes for ncfour_us_projen_utils-0.1.21-py3-none-any.whl
Algorithm Hash digest
SHA256 228c351dff919640ad4b5b34744f3009a704a65eeca461168a67dbb6e071aef1
MD5 4461956bce546aa2e4abe6e890ce37f6
BLAKE2b-256 ff363ad5fa7a5dcdd28dbab8cbe65425f68c1768a2c5602819f02aaff8a056d2

See more details on using hashes here.

Provenance

The following attestation bundles were made for ncfour_us_projen_utils-0.1.21-py3-none-any.whl:

Publisher: release.yml on ncfour-us/projen-utils

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page