Skip to content

Overwrite all HTML files recursively keeping the directory structure #207

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

Open
royfrancis opened this issue Feb 7, 2025 · 1 comment
Open

Comments

@royfrancis
Copy link
Contributor

My understanding is that -d . can be used to specify that files should be overwritten. For single files that seems to work

staticrypt index.html -d . -p mylongpassword

For multiple files, it works too

staticrypt index.html index2.html -d . -p mylongpassword

But, I cannot see a way to make it work for a nested structure.

|- index1.html
|- index2.html
\- folder/
   \- index3.html

I have tried -r, but

# outputs to a separate folder
staticrypt . -r -p mylongpassword

# still outputs to a different folder
staticrypt . -r -d . -p mylongpassword

This brings the nested files out into the root.

staticrypt $(find . -type f -name "*.html") -d . -p mylongpassword

I must be missing something. In short, how do I encrypt all html files recursively in a directory structure and overwrite them exactly where they are?

staticrypt 3.5.1

@royfrancis
Copy link
Contributor Author

Based on #196, this seems to be the solution:

staticrypt * -r -d . -p mylongpassword

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

1 participant