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

Incorrect path insertion - can't find template.tmpl #11

Open
sh4d0wl3ss opened this issue Jul 12, 2023 · 2 comments
Open

Incorrect path insertion - can't find template.tmpl #11

sh4d0wl3ss opened this issue Jul 12, 2023 · 2 comments

Comments

@sh4d0wl3ss
Copy link

HI,

Struggling with what's wrong here. Problem one is that I'm running a Windows machine and your script is for a bash shell. I have git-bash but it is not working. Somehow, though the template is in the same folder as the shell script when the script runs it is seeking for the template in a path it creates that's no good. Any ideas? The actual path to the script and the template.tmpl files is D:\Documents\evernote-notebooks\dmuthconverter. Thanks for any help you can provide.

$ ./convert-evernote-to-markdown.sh evernote-notebooks/2022Journal.enex

Yarle already installed...

logfilepath: C:\Users\adamp\AppData\Roaming\yarle-evernote-to-md\conversion.log
clearing log: C:\Users\adamp\AppData\Roaming\yarle-evernote-to-md\conversion.log
Loading config from D:\Documents\evernote-notebooks\dmuthconverter/./config.json
clearing log: C:\Users\adamp\AppData\Roaming\yarle-evernote-to-md\conversion.log
node:fs:601
handleErrorFromBinding(ctx);
^

Error: ENOENT: no such file or directory, open '/d/Documents/evernote-notebooks/dmuthconverter/template.tmpl'
at Object.openSync (node:fs:601:3)
at Object.readFileSync (node:fs:469:35)
at setOptions (C:\Users\adamp\anaconda3\node_modules\yarle-evernote-to-md\dist\yarle.js:81:71)
at Object.dropTheRope (C:\Users\adamp\anaconda3\node_modules\yarle-evernote-to-md\dist\yarle.js:191:5)
at Object.run (C:\Users\adamp\anaconda3\node_modules\yarle-evernote-to-md\dist\dropTheRopeRunner.js:59:47)
at Object. (C:\Users\adamp\anaconda3\node_modules\yarle-evernote-to-md\dist\dropTheRope.js:30:19)
at Module._compile (node:internal/modules/cjs/loader:1254:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1308:10)
at Module.load (node:internal/modules/cjs/loader:1117:32)
at Module._load (node:internal/modules/cjs/loader:958:12) {
errno: -4058,
syscall: 'open',
code: 'ENOENT',
path: '/d/Documents/evernote-notebooks/dmuthconverter/template.tmpl'
}

Node.js v18.16.0

@dmuth
Copy link
Owner

dmuth commented Jul 12, 2023

I'm not running Windows so I can't troubleshoot directly, but it looks like this happened to someone else and the way the path was formatted was an issue:

#9 (comment)

See if that works for you.

Thanks,

-- Doug

@sh4d0wl3ss
Copy link
Author

Hi Doug, No joy. I did as the other user did and hardcoded the paths everywhere there was a $DIR$ variable
./convert-evernote-to-markdown.sh evernote-notebooks

Yarle already installed...

logfilepath: C:\Users\adamp\AppData\Roaming\yarle-evernote-to-md\conversion.log
clearing log: C:\Users\adamp\AppData\Roaming\yarle-evernote-to-md\conversion.log
Loading config from D:\Documents\evernote-notebooks\dmuthconverter/./config.json
undefined:3
"D:\Documents\evernote-notebooks\dmuthconverter\evernote-notebooks"
^

SyntaxError: D:\Documents\evernote-notebooks\dmuthconverter\config.json: Unexpected token D in JSON at position 35
at parse ()
at Module._extensions..json (node:internal/modules/cjs/loader:1322:39)
at Module.load (node:internal/modules/cjs/loader:1117:32)
at Module._load (node:internal/modules/cjs/loader:958:12)
at Module.require (node:internal/modules/cjs/loader:1141:19)
at require (node:internal/modules/cjs/helpers:110:18)
at Object.run (C:\Users\adamp\anaconda3\node_modules\yarle-evernote-to-md\dist\dropTheRopeRunner.js:47:53)
at Object. (C:\Users\adamp\anaconda3\node_modules\yarle-evernote-to-md\dist\dropTheRope.js:30:19)
at Module._compile (node:internal/modules/cjs/loader:1254:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1308:10)

Node.js v18.16.0

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