c-javascript-instrumenter
v0.0.1
Published
A CLI tool to get Git commitId and pass it to javascript-instrumenter
Maintainers
Readme
Commit Instrumenter CLI
A command-line tool that retrieves the commitId of the current Git repository and passes it to the javascript-instrumenter CLI.
Features
- Get the latest commitId of the current Git repository automatically
- Allow users to specify a custom commitId using the -c, --commit option
- Pass the commitId and all options to the javascript-instrumenter CLI
Installation
# Global installation
npm install -g c-javascript-instrumenter
# Local installation
npx c-javascript-instrumenterUsage
Basic Usage
usage examples
# Execute javascript-instrumenter and pass the commitId to the specified JavaScript file
c-javascript-instrumenter --input 'D:/git/teamscale/demo-teamscale/dist/assets/* ' \
--collector localhost:54678 \
--config-id demo-teamscale \
--in-place \
--include-origin 'demo-teamscale' \
--log-level debug
c-javascript-instrumenter --input 'D:/git/teamscale/demo-teamscale/dist/assets/*' --collector localhost:54678 --config-id demo-teamscale --in-place --include-origin 'demo-teamscale' --log-level debug
Command-line Options
This tool supports the following additional option:
-c, --commit <commitId>: Use the specified commitId instead of automatically retrieving from Git
For all other parameters, refer to the documentation of @teamscale/javascript-instrumenter. The commit parameter is automatically handled by this tool.
Notes
- Make sure the current directory is a Git repository
- This tool requires Node.js 16.0.0 or higher
License
ISC
