rnote icon indicating copy to clipboard operation
rnote copied to clipboard

Allow command line argument to open a new file

Open 1over137 opened this issue 8 months ago • 2 comments

Please submit only one feature request in one issue!
Instead of reporting an error if the path specified is not found and ignoring the argument, just open the file normally and create the file at the specified path when saving.

Is your feature request related to a problem? Please describe.
I would like to integrate it with emacs org-mode to implement features that would allow inserting a new drawing into org-mode by opening rnote to create a file. To do this seamlessly, I need to ensure that the file is at a known location. Otherwise, the user will have to be prompted twice to type the correct filename, first in rnote and then in emacs when generating the link. See https://github.com/antrmn/org-rnote

Describe the solution you'd like
Allow command line argument to open a new file. It is ok if the new behavior is behind a separate argument, e.g. --create-file since this is for automated use mainly.

1over137 avatar Mar 27 '25 12:03 1over137

should we add it to rnote-cli and have it create and save a new rnote file or implement it as an optional command line argument with rnote-ui which creates and opens the new file?

Nugfle avatar Apr 19 '25 14:04 Nugfle

I think it should probably just do this without any arguments. That's what you expect from most editor programs: it opens a file, and create it on saving when it does not exist. Like vi, emacs, etc. Ignoring the argument is surprising to the user.

1over137 avatar Apr 19 '25 19:04 1over137