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

Monitor data directory on portable mode #1209

Merged
merged 2 commits into from
Sep 17, 2024
Merged

Monitor data directory on portable mode #1209

merged 2 commits into from
Sep 17, 2024

Conversation

sgourdas
Copy link
Collaborator

@sgourdas sgourdas commented Sep 13, 2024

This simplifies the creation of a portable USB by automatically monitoring the data directory in portable mode. This way we allow the user to just place needed .zim files in the data folder and the app will handle the rest.

  • Adds also immutability to the monitor and download paths through settings on portable mode

Fixes #461

Copy link
Collaborator

@kelson42 kelson42 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM from user perspective
@veloman-yunkan ready for the code review

@kelson42
Copy link
Collaborator

@sgourdas Might that be that settings UI about monitoring directory should be greyed, as any value will be overriden at start by the code?

@sgourdas
Copy link
Collaborator Author

@kelson42 sure, but should that be the case only for the monitor directory?

@kelson42
Copy link
Collaborator

@sgourdas Yes, I think so... because whatever this settings is set it will be reseted at start right? For the other settings, the user can change them and they will be kept!

@sgourdas
Copy link
Collaborator Author

sgourdas commented Sep 16, 2024

@sgourdas Yes, I think so... because whatever this settings is set it will be reseted at start right? For the other settings, the user can change them and they will be kept!

@kelson42 no, that is not the case at the moment per this commit. Monitor and download directory are currently hardcoded to the data directory on every portable start.

What would the desired behavior be?

@kelson42
Copy link
Collaborator

@sgourdas Yes, I think so... because whatever this settings is set it will be reseted at start right? For the other settings, the user can change them and they will be kept!

@kelson42 no, that is not the case at the moment per this commit. Monitor and download directory are currently hardcoded to the data directory on every portable start.

What would the desired behavior be?

Then I guess both should be greyed in portable mode (only).

@sgourdas
Copy link
Collaborator Author

@sgourdas Yes, I think so... because whatever this settings is set it will be reseted at start right? For the other settings, the user can change them and they will be kept!

@kelson42 no, that is not the case at the moment per this commit. Monitor and download directory are currently hardcoded to the data directory on every portable start.
What would the desired behavior be?

Then I guess both should be greyed in portable mode (only).

@kelson42 I added immutability on these two in portable mode. It includes grayed out text, disabled buttons and tooltip to explain the disabling.

@kelson42
Copy link
Collaborator

@sgourdas LGTM, please rebase so we can proceed with merging.

resources/i18n/en.json Show resolved Hide resolved
src/settingsview.cpp Outdated Show resolved Hide resolved
@kelson42 kelson42 merged commit 7f039ee into main Sep 17, 2024
3 of 6 checks passed
@kelson42 kelson42 deleted the feature/simplify-usb branch September 17, 2024 13:32
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

Successfully merging this pull request may close these issues.

Simplification of portable USB creation
3 participants