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

Specifying a directory in staticpaths shouldn't migrate files one by one #166

Open
alex-way opened this issue Nov 9, 2021 · 1 comment

Comments

@alex-way
Copy link

alex-way commented Nov 9, 2021

When specifying a directory in staticpaths, staticjinja should copy the entire directory, and all sub files in one operation. Currently the files in the directory are copied one by one, which for a large number of files can be extremely slow.

@NickCrews
Copy link
Collaborator

This is true. Can you be more specific as to "extremely slow"? How long for how many files?

Doing them all at once would require a larger re-structuring, it is nice how right now the code only operates on a template-by-template basis, and we don;t have to worry about bulk operations.

Perhaps another solution would be to use async/await, I believe that copying files would be a good application for that, and it might need less refactoring.

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