|
Hi,
I\'m writing a script for amaroK which needs some data read from files. I create the .amarokscript.tar as described in the wiki with my script and my data. Installation is ok, but when the script is started, the cwd is set to ~/.kde/.../script-data/ so I cannot open my data files stored in script/ Can I install some files in script-data ? if yes how ? Thanks JJL |
KDE Developer
|
Your scripting language should have some facility to lookup what the filename of the running script is. You can use this to derive what directory the script was installed in.
Amarok Developer
|
|
Ok, so i\'ll do this way.
For information in python I get it using : [code:1]os.path.expanduser(\"~/.kde/share/apps/amarok/scripts/\"«») + os.path.basename(sys.argv[0])[:-3][/code:1] with a script named scriptname.py Thank you |
Registered users: bancha, Bing [Bot], daret, Evergrowing, Google [Bot], lockheed, sandyvee, Sogou [Bot]