vamtiger-node-typescript-commit

Commits changes within a node.js-typescript project.

Usage no npm install needed!

<script type="module">
  import vamtigerNodeTypescriptCommit from 'https://cdn.skypack.dev/vamtiger-node-typescript-commit';
</script>

README

VAMTIGER Node Typescript Commit

VAMTIGER Node Typescript Commit commits unsaved source code on the source branch, and merges the corresponding build into the master branch. The purpose for this commit strategy is to explore the feesibility of removing any requirement/reliance on postinstall configuration by branch-based separation of Typescript source code and the corresponding traspiled result in order to reduce install time.
* The source branch is thus reserved for development.
* The master branch is always derived from the source branch.

Installation

VAMTIGER Node Typescript Commit can be installed using npm or yarn:

npm i --save-dev vamtiger-node-typescript-commit

or

yarn add --dev vamtiger-node-typescript-commit

VAMTIGER Node Typescript Commit can also be installed globally:

npm i --global vamtiger-node-typescript-commit

or

yarn global vamtiger-node-typescript-commit

Usage

Customiseable options can be listed:

vamtiger-node-typescript-commit --help

VAMTIGER Node Typescript Commit can be referenced as an npm script:

{
    "scripts": {
        "commit": "vamtiger-node-typescript-commit"
    }
}

VAMTIGER Node Typescript Commit can then be executed using:

To push changes to a defined remote repository:

{
    "scripts": {
        "commit": "vamtiger-node-typescript-commit -- --push"
    }
}

* "--" before options.

The latest master build can also be published to npm:

{
    "scripts": {
        "commit": "vamtiger-node-typescript-commit -- --push --publish"
    }
}

Once defined as an npm script, VAMTIGER Node Typescript Commit can executed using:

npm run commit

A custom commit meessage can also be defined:

npm run commit --commitMessage "Some custom commit message"

Custom folder names can also be defined:

npm run commit --buildFolder "build" --sourceFolder "source" # default

TS config file can be retained:

npm run commit --keepTsConfig

If installed globally, VAMTIGER Node Typescript Commit can be run as follows:

vamtiger-node-typescript-commit --push --publish --otp 123456