Commit Graph

127 Commits

Author SHA1 Message Date
Ochan Kwon
b0378617e2
bug fix for 'reveal' in a subdir (#903) (#905) 2022-07-19 13:42:24 +03:00
Josh Rabinowitz
77c0b27006
have hide -v show output from gnupg (#888)
* also document bug #834 and improve comments
2022-06-12 13:56:02 -04:00
Josh Rabinowitz
549cd9aa24
Issue 706 decrypt errors (#831)
* check for encrypted version of file before decrypting, for #706
* improve error messages, verbose output and non-verbose output
* in tests, prefix output from git init with 'git: '
* 'clean' options only remove added files, for #833
* update changelog
2022-04-19 17:14:55 -04:00
Josh Rabinowitz
120edded4f
Cleanups 2022 04 (#824)
* change file desc we use to pass gnupg info
* improve content and phrasing in docs
* improve docs about locations of private/public keys
* update changelog
2022-04-14 19:07:52 -04:00
Nikita Sobolev
a97dd7ffa8
SECRETS_TEST_VERBOSE can be 0 (#816)
* `SECRETS_TEST_VERBOSE` can be `0`

* Update _git_secret_tools.sh
2022-04-02 18:01:15 +03:00
Josh Rabinowitz
db03c638d5
in verbose mode, show some gnupg perm warnings (#812)
* set git-secret keys dir to 700 perms, for #811
* update changelog
* test improvements
* clean up comments
* remove unused code
* update git-secret-init man page
* document change to git-secret-init
2022-04-01 15:35:30 -04:00
Josh Rabinowitz
563ae4ec82
improve testing gitignore, add verbose test on osx (#800)
* Improve testing of .gitignore contents
* add an automated verbose output test on osx
* rename variables, comment improvements
2022-03-26 14:49:11 -04:00
Josh Rabinowitz
eefa10623a
changes to .gitignore usage and testing in response to #789 (#791)
* test .gitignore has expected line count, for #792
* let 'add' append filenames to .gitignore in tests
* add comments related to #789
* fix test to allow for more output from 'add'
* improve error message output
* allow for extra output from 'add' in test
* tweaks as per shellcheck lint
* improve comments, cleanup code
* update changelog
* describe test better
2022-03-23 14:13:53 -04:00
Josh Rabinowitz
50734fd364
cleanups and renames (#784)
* rename _append_* functions to _prepend_*
* improve code flow
* be more standard with shellcheck disables
2022-02-27 08:30:27 -05:00
Josh Rabinowitz
ba1dc04f3d
show and fix 'style' complaints from shellcheck (#779) 2022-02-20 10:39:37 -05:00
joshr
5bce23ac87 move test to correct test file 2022-01-17 10:01:15 -05:00
Josh Rabinowitz
bf45916088
add test by Emily-RoseSteyn, for #636 (#757) 2022-01-17 09:54:18 -05:00
Josh Rabinowitz
84d1f85c56
fix for #710, using cat from a subdir (#751)
* fix for #710, using cat from a subdir
* also fix using reveal with named files from a subdir
2022-01-15 14:54:22 -05:00
Josh Rabinowitz
23acae1265
Issue 630 hide armored2 (#661)
* use gpg --armor when hiding/encrypting files

* update changelog

* Adds SECRETS_GPG_ARMOR env variable

* Fixes lint

* One more test

* Addresses review

Co-authored-by: sobolevn <mail@sobolevn.me>
2021-06-26 16:24:26 +03:00
Pedro Sobota
ac3b77a5bc
Newline not added to .gitignore entry on add (#645)
* Fix Newline not added to .gitignore entry on add (#643)
* Updates to CHANGELOG.md
* Add tests
2021-06-23 18:31:26 -04:00
Jeppe Fihl-Pearson
fae00fac3d
Rename killperson to removeperson (#685)
* Rename the "killperson" command to "removeperson"

"killperson" is unnecessarily hostile so change the command name to
"removeperson".

Fixes #684.

* Re-generate man pages

* Update contribution guide

There's no longer any pre-commit hooks so don't mention them.

* Add alias from `killperson` pointing at `removeperson`

* Update git_secret_removeperson.sh

Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
2021-06-16 10:31:58 +03:00
Nikita Sobolev
19941f91f4
Adds release-ci script to test installation (#664)
* Adds release-ci script to test installation

* Fixes CI

* Fixes CI

* Renames some variables to follow the same SECRETS_ convention
2021-05-05 15:59:28 +03:00
sobolevn
5fc8ecbdde Adds hadolint, re-enables shellcheck 2021-05-04 13:01:41 +03:00
sobolevn
28dbdf3fde Adds fedora testing 2021-05-04 13:01:41 +03:00
sobolevn
22d994c372 Adds alpine tests 2021-05-04 13:01:41 +03:00
sobolevn
8f7b9c51de [WIP] New CI 2021-05-04 13:01:41 +03:00
Josh Rabinowitz
ee592b8ede
Issue 634 tell duplicate emails (#637)
* support asserting named keyring is missing email(s)
* improve error if git-secret keyring missing email
* new test for telling same email twice
* update tell manpage regarding duplicate emails
* regenerate man pages
* update changelog
2021-01-17 09:24:33 -05:00
Sasha Friedenberg
39ab72f866
add bash string escaping to _add_ignored_file (#626) 2020-11-21 22:37:58 +03:00
Bertjan Broeksema
fc51d6f15f
More precise feedback about added files (#614)
* More precise feedback about added files

This adapts the output of the add command in order to report exactly
how many files have been added. Specially with wildcard patterns, this
makes it easier to verify that expected files are added.

With the verbose option, the add command will also tell which files
have been added.

By @bbroeksema bbroeksema
2020-10-04 15:19:56 -04:00
Josh Rabinowitz
bdc3560897
Issue 607 fix expired test key (#608)
* updated fixture key for user3, fixes #607
* update tests/fixtures/gpg/README.md
* mention fix of #607 and #609 in changelog
* use shellcheck 0.7.1, not 'latest' for #609
2020-09-20 09:21:13 -04:00
Josh Rabinowitz
a0a176fa5d
Issue 552 508 revoked keys (#553)
* warn about 'tell' on expired/revoked/invalid keys
* error if 'tell' used on email with multiple keys
* improve test of 'tell' with subdirs
2020-03-07 14:07:03 -05:00
Josh Rabinowitz
2830ce2ff7
Issue 579 reveal clobbers (#580)
* Don't let reveal clobber secret files, for #579
2020-01-24 17:04:02 -05:00
Josh Rabinowitz
9348cd32e2
Revert "Issue 554 show gpg commands (#556)" (#559)
This reverts commit 9e8438236c.
2019-10-09 14:05:31 -04:00
Josh Rabinowitz
9e8438236c
Issue 554 show gpg commands (#556)
* show most gpg commands used for 'hide', 'reveal', 'tell' and 'killperson (#554)
* fix hang when using ctrl-c during tests (#558)
2019-10-09 13:39:59 -04:00
Josh Rabinowitz
2a1600f2f6
cleanup output when we clean up tmp files (#532)
* cleanup output when we clean up tmp files
2019-09-07 00:10:45 -04:00
Josh Rabinowitz
525305d985
Issue 527 key with comment (#528)
* add key fixture with no email, and 2 word comment
* tests for key without email and with comment
* handle comments in public key uids
* fix tests, you have to use email address
* fix text
* confirm that email addresses contain an @ symbol
* improve comments about keys/fixtures
2019-09-06 20:21:50 -04:00
Josh Rabinowitz
68b64f4aac
make correction to comments (#525) 2019-08-30 13:17:53 -04:00
Josh Rabinowitz
9ff559ca8c
Issue 478 tests in busybox (#523)
* use busybox by not installing coreutils on alpine
* changes for busybox version of ps and stat
* add function to check if exe is from busybox
* update changelog
* cleanup comments, code, and commented out code
* improve comment in alpine Dockerfile
* include platform-specific funcs so we can test perms
2019-08-30 09:35:47 -04:00
Josh Rabinowitz
baf6c4113b
Add SECRETS_PINENTRY env var and docs (#490)
* Add SECRETS_PINENTRY env var 

* add docs and tests for SECRETS_PINENTRY

* improve diagnostic output

* fix regex example for bats-core diagnostics
2019-08-16 16:53:57 -04:00
Josh Rabinowitz
10fa2a7be2
Tempfile and temp directory cleanups (#473)
* Tempfile and temp directory cleanups
    Add comments about mktemp on different platforms
    Be more careful about tempfile cleanups
    Don't use find to locate files to cleanup
    Use shorter SECRETS_EXTENSION and SECRETS_DIR env settings in tests
    Set TMPDIR in tests again
    Show DESTDIR used when testing git-secret install
    Change filename passed to mktemp -t in tests
2019-05-21 12:06:51 -04:00
Simon Massey
10879e2253
fix for git secret hide -m doesn't work on first use #466 (#469) 2019-05-09 06:23:02 +01:00
Josh Rabinowitz
44a8745e02
remove duplicate test (#458) 2019-04-01 15:00:42 -04:00
Josh Rabinowitz
bbb4d9d3e5
Tmp cleanups (#457)
* Only show 'cleaning up temp file' messages if one
  of SECRETS_VERBOSE or SECRETS_TEST_VERBOSE is set.
* Adjust tests to reflect the change.
* Add note about suppressing 'cleaning up' msgs to CHANGELOG.md and reorder entries
* add comments showing examples of tmpfiles returned
2019-04-01 12:53:19 -04:00
Josh Rabinowitz
24bfc86b74
Fail on extra params (#448)
* fail if user passes unexpected filenames or unknown params
* mention fix of #390
2019-03-30 20:13:54 -04:00
Josh Rabinowitz
2341d1433b
Temp dir fixes (#449)
* perform our test install into TMPDIR
* fix typo
* remove duplicate entry in CHANGELOG.md
* improve commenting
2019-03-29 18:11:52 -04:00
Josh Rabinowitz
cb1636a6dc
experimental SECRETS_TEST_VERBOSE shows debug info during tests (#446)
* add a travis target using SECRETS_TEST_VERBOSE=1
* Document SECRETS_TEST_VERBOSE as experimental
* note experimental feature may change or be removed
2019-03-28 07:41:07 -04:00
Josh Rabinowitz
8334d7beef
Reveal verbose (#447)
* add -v option to reveal, for #395
* update reveal man page
* shellcheck exception
* changelog update for 'reveal -v'
2019-03-25 11:37:24 -04:00
Josh Rabinowitz
07af0c19b6
Varnames output and typos (#441)
* rename variable, fix typo, improve comments and output
* fix directory removal after testing
* mention improved user messaging in CHANGELOG.md
2019-03-23 19:48:08 -04:00
Josh Rabinowitz
be88da4c0c
test 'DESTDIR=/dir/here make install' support (#438) 2019-03-21 21:32:36 -04:00
Josh Rabinowitz
ce8c6b3ae0
Change 'add' to add to .gitignore by default. (#429)
* Change 'add' to add to .gitignore by default.
Also add _message() function and improve output from 'git-secret-add',
alter tests for new code behavior, and update docs.
* change tests since 'add' always adds to .gitignore
* improve output: prepend more message with 'git-secret:'.
* update man page for git-secret-add
2019-03-20 08:03:28 -04:00
Jonas Karlsson
54f74ede6a Fix for windows (#375)
* add test for travis-ci windows support
* Make 'ps' command options platform specific *nix/windows
* Add _clean_path for windows,  apply to all homedir input arguments
* export GITSECRET_DIST="windows" in git hook if running windows
* Bash lint fixes
2019-03-09 18:49:45 -05:00
Josh Rabinowitz
8adb7d5741
Revert "use pgrep & kill $pid, not ps+gawk+regex+system+kill (#400)" (#405)
This reverts commit a2a9bd32ba.
2019-03-09 13:14:44 -05:00
Josh Rabinowitz
a2a9bd32ba
use pgrep & kill $pid, not ps+gawk+regex+system+kill (#400)
* use pgrep & kill, not ps+gawk+regex+system+kill
* install shellcheck and enable lint on macos/brew.
* add shellcheck fixes and exception
* reorder CHANGELOG entries
2019-03-09 10:14:47 -05:00
Josh Rabinowitz
22fe1ed2d4
Add support for SECRETS_VERBOSE env var (#393)
* Support SECRETS_VERBOSE env var in addition to -v
* don't use --quiet when decrypting in verbose mode
* show output of gpg encryption in verbose mode
* add tests for SECRETS_VERBOSE env var set to 0 and 1
* update changelog, reorder entries.
* add tests for 'cat' and 'hide' with SECRETS_VERBOSE=1
2019-03-07 17:46:51 -05:00
Josh Rabinowitz
c4331693f3
use 'kill', not 'kill -9' (#379) 2019-03-07 15:17:51 -05:00