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
Portable version that saves the database and settings inside the executable folder #545
Comments
I see a "portable" download (Notes_2.1.0-Qt5.15.2-x64-Windows-Portable.zip) but that still seems to store the database in I see a setting for the path, but that seems a hard coded path while relative should be better for portable use Some portable apps simply look for a text file in the current folder, something as simple as |
Hi! Currently, we don't support this, but when we'll, you'll hear about it here. |
I also would love to see a fully portable version, where settings and database are stored in a relative-path manner, in the same folder where the . exe resides. |
I wonder if we can easily give Thanks, @Stefanoko, I'll keep you posted here for changes. EDIT: Seems like it's pretty easy using |
It's not exactly what folks here are asking for but we released Notes Portable at PortableApps.com. It includes the 64-bit Qt6 and (optionally) 32-bit Qt5 variants and will automatically use the right one on each PC. Your notes.db will remain within the app on your portable device. Settings will be moved to and from APPDATA\Awesomeness, backing up and restoring any existing files, and adjusting the paths so that your notes.db is pointed to as the paths change. |
Hey @JohnTHaller , that's awesome. Care to send a PR? It will be great to have a CMAKE flag for this, if possible, then we'll just add it to our CI. @guihkx, what do you think? |
Notes itself is entirely unchanged. The NotesPortable.exe launcher handles moving the files around and adjusting paths. It's done with a simple config file: [Launch] [DirectoriesMove] [FileWrite1] [FileWrite2] [FileWrite3] [FileWrite4] And a bit of custom code to force Windows 7/8 to run the 32-bit Qt5 version: Var CustomBits ${SegmentFile} ${Segment.OnInit}
!macroend ${SegmentInit} Happy to have you distribute as well or instead of us and us linking to your builds. Or somewhere in between (we do all variants for various devs). On a related note: Currently linking to your Patreon for the Donation link in help.html, within the app for the PA.c Plaftform to pick up, and from the portable app's homepage. Have you thought about having a single /donation page on get-notes.com that links to everything? That would make it so we don't have to pick just one. |
Oh that's great, thanks for sharing. I'll wait for @guihkx reply about integrating it to our build process. Regarding donations, I just created a page here: https://www.get-notes.com/donation. Thanks for letting me know! |
Cool. Switched the portable app homepage to the new link (cache will update shortly). Will have it included in the next package as well. |
Thank you @JohnTHaller, I've used a lot of apps from your website back in my Windows days. :) Though I'm a bit confused here, @nuttyartist: Do we actually need to do something else on our part? It seems like the build on PortableApps.com works independently from us. |
@guihkx - If you're happy with us building and hosting, you're good. You can link to us for the builds and/or add them on to your releases here on github if you'd like. |
I'd be fine with that, though @nuttyartist has the last word on it. But in my opinion, this issue needs to be solved on our side, maybe via a build flag that'd allow us to control, at build time, the portability of the settings and notes database... Or, maybe even better: At runtime. By simply by asking users if they prefer to keep the settings and the notes database stored in the same directory as the main executable... |
I think, ideally, you'll want to support it internally within your code base. We can make use of that for our package as we do with many projects. But you could point to or distribute our Notes Portable package in the meantime. As for how to expose it, many projects detect the settings in the same folder. So you'd look for Settings.ini alongside Notes.exe and use that. Hopefully also storing the path to the database relatively within Settings.ini. Or by having a trigger directory like Settings or similar in the same place. |
My thoughts as well. I prefer if the entire build process of the binaries our users use (wherever they download it from) will go through a transparent build process by us. We just saw what happened with xz. Both a runtime toggle or a separate binary sounds good to me. |
Some people asked if there are portable versions of Notes for Windows (there are) that can save the database and settings file in the same directory the app is running from. They said "It makes it a valuable tool to have on a USB key, without worrying about User system or leaving traces".
The text was updated successfully, but these errors were encountered: