Comments (14)
Anyone for tagging a new version? 😊
That would be really helpful for updating the formula in Homebrew. The workaround given by @tobywf will work in the meantime:
brew install git-secrets --HEAD
from git-secrets.
Using make install
to install the package from source will give the illusion of fixing the error.
When committing multiple files (using the make install method), git-secrets will not recognise the AWS secret that exists in one of them.
from git-secrets.
It's worth noting that if you don't have any patterns defined, the commit works without issue.
from git-secrets.
Looks like @t13a may have some work that could fix this? Looks like it touches the relevant code.
master...t13a:feature/fix-scan-files
from git-secrets.
I'm having the same issue.
Just out of interest, what bash version are you on? #45 was meant to fix this error for bash version 4 but I'm still having the same problems.
from git-secrets.
I'm using the latest homebrew
installed version.
$ which bash
/usr/local/bin/bash
$ bash --version
GNU bash, version 4.4.19(1)-release (x86_64-apple-darwin17.3.0)
Copyright (C) 2016 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software; you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Did confirm this is still an issue.
from git-secrets.
@mtdowling - Is there any progress with this issue? I'm just wondering as I've run into it myself.
from git-secrets.
Happens in my machine as well.
Running GNU bash, version 4.4.12(1)-release (x86_64-apple-darwin16.3.0)
Git Secrets installed via Homebrew git-secrets: stable 1.2.1 (bottled), HEAD
Committing a single file (with aws secret) will result in the warning.
Committing multiple files that one of them includes the aws secret will produce the error above.
from git-secrets.
I'm not sure what's going on here, but I got exactly this error when executing git commit
:
fatal: ambiguous argument '<snip>': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...] -- [<file>...]'
So finally I figure out it's the pre-commit hook, and add a set -x
to which git-secrets
. The offending line turns out to be:
GREP_OPTIONS= LC_ALL=C git grep -nwHEI ${options} "${combined_patterns}" $files
This is because I installed it via homebrew as recommended in the README. That gets you version 1.2.1, released on Jun 27, 2016 (!).
PR #54 seems to have fixed this by adding --
to git grep
, although there is still an instance of this command without --
(line 105). Using brew install --HEAD git-secrets
installs the latest version, so I did that.
With regards to the previous comment, whether or not this fixes it, I don't know. What I do know is now I can finally commit stuff again, after spending a good hour debugging why git commit
was broken, which is pretty bad, along with finding out that the last release was two years ago.
from git-secrets.
If it is fixed in the build version, it sounds like the path forward is:
- tag a release of the software
- open a PR to upgrade the formula with that version
from git-secrets.
@mtdowling Can you tag a new release from master
when you get a moment?
from git-secrets.
I'm running into this problem as well. Would be nice to get a new version tag, so that brew
can update.
from git-secrets.
Sorry for the delay. I just tagged 1.3.0.
from git-secrets.
We're good to go in Homebrew. 🎉
$ brew info git-secrets
git-secrets: stable 1.3.0 (bottled), HEAD
Prevents you from committing sensitive information to a git repo
https://github.com/awslabs/git-secrets
/usr/local/Cellar/git-secrets/1.3.0 (8 files, 65.7KB) *
Poured from bottle on 2019-02-12 at 09:58:51
From: https://github.com/Homebrew/homebrew-core/blob/master/Formula/git-secrets.rb
==> Options
--HEAD
Install HEAD version
==> Analytics
install: 828 (30 days), 2,016 (90 days), 6,453 (365 days)
install_on_request: 805 (30 days), 1,991 (90 days), 6,403 (365 days)
build_error: 0 (30 days)
from git-secrets.
Related Issues (20)
- Support for mirrorred repositories
- AWS patterns seem to match everything HOT 1
- Provide a warning and remediation suggestion when NO secret patterns are defined
- Add support for a configuration file that can contain the patterns, etc. and be included in the repo is desired. HOT 1
- Github Actions HOT 2
- grep: warning: stray \ before - HOT 1
- Error : Custom secret provider detection patterns aren't loaded when executing git secrets on windows. HOT 3
- Installation fails without a terminal HOT 9
- Secret rules being applied to unstaged files
- `say` command during install should be removed or made configurable by flag HOT 6
- /usr/local/bin/git-secrets: line 208: say: command not found HOT 1
- custom patterns wont work HOT 4
- Problem with file HEAD.secret HOT 1
- Can't get any response from scans HOT 4
- How to pass multiple patterns in .gitallowed file HOT 1
- `git-secrets --install` test failures without code changes
- Add a test for PRs that change README without updating the man page HOT 1
- Add *hashed* file version to .gitallowed? So future changes get caught containing secrets again HOT 1
- Java Key Store files
- How to allow aws account numbers with .gitallowed HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from git-secrets.