Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pathspec 'git' did not match any file(s) known to git #977

Open
wgfire opened this issue Jul 31, 2023 · 2 comments
Open

pathspec 'git' did not match any file(s) known to git #977

wgfire opened this issue Jul 31, 2023 · 2 comments

Comments

@wgfire
Copy link

wgfire commented Jul 31, 2023

import { bootstrap } from "commitizen/dist/cli/git-cz"
import path from "path"

export const runCommitCZ = () => {
	const cliPath = path.join(__dirname, "../../../../node_modules/commitizen")
	console.log(cliPath, "czpath")

	// eslint-disable-next-line @typescript-eslint/no-unsafe-call
	bootstrap({
		cliPath,
		config: {
			path: "cz-conventional-changelog"
		}
	})
}
const program = new Command()
export const git = program
	.command("git")
	.description("use git add git commit git push  ")
	.action(arg => {
		runCommitCZ()
	})

erro pathspec 'git' did not match any file(s) known to git
git exited with error code 1
at ChildProcess. (D:\bBoyCli\node_modules\commitizen\dist\git\commit.js:810:28)

How can I modify and fix this problem, thanks for help

@wgfire
Copy link
Author

wgfire commented Aug 1, 2023

Can anyone answer it

@jimthedev
Copy link
Member

Do you have git installed and in your path? Seems like you don’t have it in the path?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants