Skip to content

Conversation

@noxhirsch
Copy link
Contributor

@noxhirsch noxhirsch commented May 19, 2024

The info messages for opening files always show the full path. By using filemanagerutil.abbreviate, the info messages now show the shortened home folder path (only if the setting "shorten home folder" is enabled).


This change is Reviewable

@Frenzie Frenzie added this to the 2024.05 milestone May 19, 2024
@Frenzie Frenzie merged commit 3b97e29 into koreader:master May 19, 2024
@Frenzie
Copy link
Member

Frenzie commented May 19, 2024

Thanks!

@poire-z
Copy link
Contributor

poire-z commented May 19, 2024

(In my own patch, I use:

-        text = T(_("Opening file '%1'."), BD.filepath(file)),
+        text = T(_("Opening from  %1\n\n%2\n\n"), BD.dirpath(file:gsub(".*/(.+/).*", "%1")), BD.filename(file:gsub(".*/(.*)", "%1"))),

which makes focusing on the filename a little bit easier.)

@noxhirsch noxhirsch deleted the use-short-home-folder-path branch May 19, 2024 11:31
@Monirzadeh
Copy link
Contributor

i am not sure it related or not but in kindle home short adress not work anymore. (checkbox is acrivated but show full path when long press on home icon)

@noxhirsch
Copy link
Contributor Author

noxhirsch commented May 21, 2024

i am not sure it related or not but in kindle home short adress not work anymore. (checkbox is acrivated but show full path when long press on home icon)

I assume that this can't really have anything to do with it, as I only changed the info messages themselves. Are you using the nightly version of KOReader from yesterday / today and before that it worked?

@Frenzie
Copy link
Member

Frenzie commented May 21, 2024

Could be related to #11774?

@Frenzie
Copy link
Member

Frenzie commented May 21, 2024

Like if you saved it as /some/path/ and now it only returns /some/path it'll never match, or something along those general lines.

@Monirzadeh
Copy link
Contributor

Maybe.
I am not sure exactly when it happen (maybe I just notice that today) but I am sure a few week ago it work correctly as I use that couple week ago.

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.

4 participants