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

will add subcommand add --all? #619

Closed
ghost opened this issue Nov 14, 2020 · 2 comments
Closed

will add subcommand add --all? #619

ghost opened this issue Nov 14, 2020 · 2 comments

Comments

@ghost
Copy link

ghost commented Nov 14, 2020

What are the steps to reproduce this issue?

  1. Now git secret add file will add one file, how can use command to add all files in the current repo directory to encrypt?

  2. I wish add one subcommand : git secret add --all
    ==
    find . ! -path "./.gitignore/*" ! -path "./.git/*" ! -path "./.gitsecret/*" ! -path "./.gitignore" ! -path "./.git" ! -path "./.gitsecret" -exec git secret add {} \;

Well, I have used shell script to make it.

Thank you.

@joshrabinowitz
Copy link
Collaborator

joshrabinowitz commented Nov 19, 2020

@sobolevn do you think we should add an -a feature to 'git secret add` that adds all the relevant files in the repo dir to git?

On one hand, it seems like overkill; on the other hand (and someone explicitly asking for this feature shows there's some demand), I can see it being useful for people who are using a git repo specifically to use git-secret on every file in the repo.

@sobolevn
Copy link
Owner

I think that -a is an overkill for git secret add

find . ! -path "./.gitignore/*" ! -path "./.git/*" ! -path "./.gitsecret/*" ! -path "./.gitignore" ! -path "./.git" ! -path "./.gitsecret" -exec git secret add {} \;

This does not seem like a big deal for me, because it is:

  • a rare case
  • a command that you only need to run once
  • might be customized by other use-cases

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