Skip to content
/ cli Public

A fully featured Contensis shell provides simple and intuitive commands to manage or profile content in your terminal

License

Notifications You must be signed in to change notification settings

contensis/cli

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Contensis Contensis CLI

If you are using this package you may want the Contensis CLI package README

Development

After cloning this project:

  • Clone any other packages you require into the /packages folder
  • yarn run bootstrap
  • cd packages/contensis-cli

To run commands in CLI

  • npm start -- {cli command}

To start the Contensis shell to run commands

  • npm start

or do this from the root folder with

  • yarn run cli

Build

To build the project from root folder

  • yarn run build

To build an executable for your operating system

  • yarn run build:exe * outputting to bin/ folder

  • yarn run build:exe:win (for Windows)

Add / update packages

Each of the package folders will contain their own respective package.json with their own dependencies and devDependencies and so on...

To install or update a dependency in the contensis-cli package run the command:

  • yarn workspace contensis-cli add --save migratortron@latest

To install or update a development-only dependency in the contensis-cli package run the command:

  • yarn workspace contensis-cli add --dev <package-names>

After managing workspace packages it is good to run yarn run bootstrap afterwards to ensure the monorepo packages are correctly hoisted and linked before continuing development

Workspace root

The root of this workspace project contains dev dependencies that are required for the workspace, or all packages to function in the context of the monorepo

To install or update a development dependency in the workspace root run the command:

  • yarn add -W --dev eslint

Release

To create a new version (prerelease)

  • Simply make a commit or merge to the main branch and the build GitHub action should take care of the rest
  • The package will be built and published to npm.js - available to install with npm i -g contensis-cli@prerelease
  • Binaries from each commit's build workflow are uploaded to the job summary as build assets

Prepare the next release version

  • The next release is taken care of by the Release Please Action
  • Each valid commit to main will be analysed for changes automatically in the build action
  • The next version, changelog and GitHub Release tag / notes will be brought together by the Release Please Action
  • A Pull Request will be created/updated containing the next CLI version and you can view the changelog for that version in the PR description with your last commit message added to it

Make the release

  • Simply Squash and merge the open Pull Request

  • Any merge conflicts reported here are tiny and can be resolved in the GitHub UI accepting all changes from the release-please branch and rejecting all the interim changes made in main

  • The Release Please Action will trigger a new build in the CI, this time the build will return release variables.

  • A tag and a GitHub release will be created for the Pull Request version you merged and the release action workflow will be triggered

  • The release workflow will publish release versions to:

Related repositories / packages

A few other resources exist as ways to consume Contensis CLI - the source code for building for those targets is included in this repository unless that platform requires the respective assets to be hosted in a git repository of its own

NPM package

https://www.npmjs.com/package/contensis-cli | Source

Chocolatey package

https://community.chocolatey.org/packages/contensis-cli | Source

Homebrew tap & formula

https://github.com/contensis/homebrew-cli

GitHub Actions

https://github.com/marketplace/actions/contensis-cli-action | Source

https://github.com/marketplace/actions/contensis-block-push | Source

GitLab reusable workflows

https://gitlab.zengenti.com/ops/contensis-ci

About

A fully featured Contensis shell provides simple and intuitive commands to manage or profile content in your terminal

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors 5