0.0.3 • Published 1 year ago

@hubootech/set-version-script v0.0.3

Weekly downloads
-
License
ISC
Repository
-
Last release
1 year ago

Set Version Script

Script that can be added as a submodule to increment a version in a config file within a pipeline step.

Supports .yml, .yaml, .json and .txt file types.

Usage

Args

  • version: The version to modify the current value to
  • file: The path to the file you want to modify
  • keyPath: The path to the key within the file. Could be in the following format: obj1.obj2.obj3.key key * obj1.array1.obj2.key
  • enforceQuotes?: true|false Whether or not to add quotes to the output version (useful for yaml)

This can be ran from the root directory using the following command.

npm start $version $file $keyPath $enforceQuotes

Or from another directory by doing

npm --prefix <path to script directory> start $version $file $keyPath $enforceQuotes