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

Question: Why use cat file | instead of < file? #44

Closed
seyfahni opened this issue May 24, 2022 · 3 comments
Closed

Question: Why use cat file | instead of < file? #44

seyfahni opened this issue May 24, 2022 · 3 comments

Comments

@seyfahni
Copy link

The Readme suggests using cat archive | docker ... - to restore backups, but that is another process call, wouldn't it be more efficient to just use docker ... - <archive instead?
While it does work (I only tested with small backups) I'm not quite sure myself if there are major downsides to it.

@loomchild
Copy link
Owner

Yes, you are right, it probably would be more efficient. I wrote it with cat out of habit and for readability. Would you be able to prepare a benchmark to illustrate that there's a difference?

@loomchild
Copy link
Owner

Never mind, I think it will be even more readable with < at the end, since it's similar to normal restore syntax and backup syntax. I will change it when I have a bit of time. Thanks for your suggestion.

@loomchild
Copy link
Owner

I have made the changes to README and tested them. Thank you!

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