[FEATURE] Initial folder
[FEATURE] Initial folder
Hi,
It would be very useful to define a starting directory to display when I click the "Load" button.
Thanks.
It would be very useful to define a starting directory to display when I click the "Load" button.
Thanks.
Re: [FEATURE] Initial folder
"Load" will restore whatever folder you loaded last time. That being said, using drag-and-drop tends to be far more efficient if you want to load files into some application.
@see https://www.youtube.com/watch?v=RRq2_Pjyko8
@see https://www.youtube.com/watch?v=RRq2_Pjyko8
Re: [FEATURE] Initial folder
Yes, I know. But if the folder loaded last time doesn't exist, it shows "/home/juan/.config/filebot". The idea is define an initial folder when the folder loaded last time doesn't exist.
Re: [FEATURE] Initial folder
That is indeed strange. The system default is good on Windows and Mac and on Linux it'll probably default to $HOME or $PWD depending on what the GTK file dialog does by default.
You might be able to set the working directory in the .desktop launcher and then that should be the default.
PS: This is why the sysinfo output should be included in every thread. How am i supposed to know you're on Linux? And what Linux? And what desktop environment? etc
You might be able to set the working directory in the .desktop launcher and then that should be the default.
PS: This is why the sysinfo output should be included in every thread. How am i supposed to know you're on Linux? And what Linux? And what desktop environment? etc

Re: [FEATURE] Initial folder
I didn't include the sysinfo because this wasn't a bug report. But this is the info:
I have added "Path=/dunehd/Descargado" to .desktop file but its ignored by Filebot. Filebot is a java program, it doesn't respect some desktop standards. The problem is in filebot launcher:
If the folder loaded last time doesn't exist, it loads that location: "$HOME/.config/filebot"
Code: Select all
Arch Linux 64 bits
FileBot 4.7 (r3923) / OpenJDK Runtime Environment 1.8.0_92
Code: Select all
... -Dapplication.dir=$HOME/.config/filebot ... -Duser.home=$HOME/.config/filebot
Re: [FEATURE] Initial folder
Well, that explains why none of this makes sense. It's not my code.
The AUR maintainers made their own filebot.sh startup script for Arch Linux:
https://aur.archlinux.org/packages/filebot/
I have no idea why they would override user.home but I'm sure somebody had a good reason.
The AUR maintainers made their own filebot.sh startup script for Arch Linux:
https://aur.archlinux.org/packages/filebot/
I have no idea why they would override user.home but I'm sure somebody had a good reason.

Re: [FEATURE] Initial folder
ok, I've installed your version (extracted from deb package) and now it opens my home folder, but not the folder defined in desktop file with "Path=/dunehd/Descargado".
Re: [FEATURE] Initial folder
I guess it's defaulting to your user home then. It's different for each platform.
If you really really want this, then just set -Duser.home to the folder you want as default.
If you really really want this, then just set -Duser.home to the folder you want as default.

Re: [FEATURE] Initial folder
I want define an initial folder when the folder loaded last time doesn't exist. But with your solution I change the location of filebot data too, like presets. What's the point of "-Dapplication.dir" then?rednoah wrote:If you really really want this, then just set -Duser.home to the folder you want as default.
Moreover, when I update filebot to new version, the init script will be overwritten.
Re: [FEATURE] Initial folder
application.dir is used by FileBot for all the application data files.
Preferences are managed by the Java Preferences API which stores them in a platform-specific way (e.g. Registry on Windows). On Arch Linux it's probably gonna default to some implementation that uses text files. That'll probably default to the user home, but I'm sure that this can be override with some additional system properties.
@see http://stackoverflow.com/a/21999054/1514467
Preferences are managed by the Java Preferences API which stores them in a platform-specific way (e.g. Registry on Windows). On Arch Linux it's probably gonna default to some implementation that uses text files. That'll probably default to the user home, but I'm sure that this can be override with some additional system properties.
@see http://stackoverflow.com/a/21999054/1514467
Re: [FEATURE] Initial folder
In this case, "-Djava.util.prefs.userRoot=$HOME/.config/filebot/" with "-Duser.home=/dunehd/Descargado" works. But all changes done in filebot.sh will be overwritten when I update the app. This is a workaround but not the solution.
Thank you anyway.
Thank you anyway.
Re: [FEATURE] Initial folder
You'll probably want to talk to the AUR maintainers to include a proper solution in the official package.
Also, filebot.sh will respect your JAVA_OPTS environment variable. That you can set in your user profile:
Also, filebot.sh will respect your JAVA_OPTS environment variable. That you can set in your user profile:
Code: Select all
export JAVA_OPTS="-Djava.util.prefs.userRoot=$HOME/.config/filebot/ -Duser.home=/dunehd/Descargado"
Re: [FEATURE] Initial folder
This isn't related to AUR package. It is related to official package, the program itself.rednoah wrote:You'll probably want to talk to the AUR maintainers to include a proper solution in the official package.
An environment variable is for all applications, this isn't the case.rednoah wrote:Also, filebot.sh will respect your JAVA_OPTS environment variable. That you can set in your user profile:Code: Select all
export JAVA_OPTS="-Djava.util.prefs.userRoot=$HOME/.config/filebot/ -Duser.home=/dunehd/Descargado"
Re: [FEATURE] Initial folder
The AUR maintainers probably mean to override java.util.prefs.userRoot but they do override user.home which has strange side-effects, odd initial folder for dialogs being one of them.