-
Notifications
You must be signed in to change notification settings - Fork 220
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
Command not found on run #253
Comments
Hey! Do you edit your PATH env in .bashrc or something? Or maybe you have an alias? How are |
I'm having a similar problem. I've aliased |
@art-solopov, did you write an alias in |
@mrexox I can print PATH contents from |
@qasim90 , could you provide more context?
Maybe you have a public project, so I could reproduce the issue? |
I guess that the issue is related to some $PATH env var tweaks. Try setting |
The problem with this is that probably most people define their
this will not work with the cc @mrexox |
@nerder , can you please provide your |
lefthook.yml rc: ~/.lefthookrc
pre-push:
parallel: true
commands:
linter:
run: flutter analyze
tests:
interactive: true
run: flutter test --coverage
pre-commit:
parallel: true
commands:
check-secrets:
interactive: true
run: bash -c '${TALISMAN_HOME}/talisman_hook_script pre-commit'
pretty:
glob: '*.dart'
exclude: '.*freezed\.dart|.*g\.dart|.*mocks\.dart'
run: dart format -l 100 {staged_files} && git add {staged_files} .lefthook.rc PATH="$PATH:$USER/flutter/bin" This wasn't working while running on the latest Ubuntu and latest version of |
@nerder, thank you for the example. Have your tried doing something like # lefthook.yml
...
pre-commit:
parallel: true
commands:
pretty:
glob: '*.dart'
exclude: '.*freezed\.dart|.*g\.dart|.*mocks\.dart'
# print $PATH -- how does this differ with and without quotes?
run: |
echo $PATH
dart format -l 100 {staged_files} && git add {staged_files} Also, do you have paths like |
Hi,
when running pre-commit hook (either by
git commit
or bylefthook run
) I get "command not found" error although in command line and in shell scripts everything works just fine...config:
Shell output:
And in none-pipe mode:
The text was updated successfully, but these errors were encountered: