@buildshipapp/git-manager
v1.0.1
Published
CLI tool to manage git repositories for BuildShip workflows
Downloads
200
Readme
Git Manager for BuildShip Workflows
This package contains a CLI tool to manage Git repositories within BuildShip workflows.
Usage
npx @buildshipapp/git-manager <operation> [options]npm i @buildshipapp/git-manager -g
git-manager <operation> [options]Manual
git-manager - A CLI tool for managing Git repositories in BuildShip workflows.
COMMANDS
validate-workflows
Validates the schema for Git workflows defined in the BuildShip project.Validate Workflows
git-manager validate-workflows <repo-path> [report-inputs]
OPTIONS
<repo-path>
Path to the local Git repository to validate.
[report-inputs]
Optional, set to "true" to include invalid input values in the report for debugging purposesPre-commit hook
To set up the Git Manager as a pre-commit hook:
- Install the package in your repository:
npm install --save-dev @buildshipapp/git-manager- Create a
.huskydirectory (if using Husky):
npx husky init- Create a pre-commit hook file at
.husky/pre-commit:
#!/bin/sh
npx @buildshipapp/git-manager validate-workflows . true- Make the hook executable:
chmod +x .husky/pre-commitAlternatively, without Husky, create .git/hooks/pre-commit directly:
#!/bin/sh
npx @buildshipapp/git-manager validate-workflows . trueThe hook will now validate workflows before each commit.
