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

Output to current directory #214

Open
jamesdeluk opened this issue Oct 20, 2024 · 2 comments
Open

Output to current directory #214

jamesdeluk opened this issue Oct 20, 2024 · 2 comments

Comments

@jamesdeluk
Copy link

Is there a way to output the results.json directly to the current directory?

For example, currently:

C:\ > surya_ocr --results_dir . image.png

saves to C:\image\results.json

Can it simply be C:\results.json?

@snowfluke
Copy link

You could chain the command

C:\ > surya_ocr --results_dir . image.png && move image\result.json . && rmdir /s /q image

@jamesdeluk
Copy link
Author

The issue is the image isn't actually called image.png, it's a long, complex string (think base64) that changes every time. I guess I could do some kind of Get-ChildItem, save the name to a variable, and do more chaining... But a simple "dump in same folder" option would be very useful 😄

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