[sword-devel] More installmgr woes... (need for export SWORD_PATH=~/.sword )

Jonathan Marsden jmarsden at fastmail.fm
Thu Sep 3 11:49:47 MST 2009

Matthew Talbert wrote:

> One more thing. If the last step in building sword is "make config", 
> then there is no reason to set SWORD_PATH at all. (even if it isn't 
> the last step, there's no reason to, I think). SWORD will 
> automatically look in ~/.sword and whatever paths are set in 
> /etc/sword.conf without needing SWORD_PATH set.

That is a nice theory, but I can't seem to make it work in practice to 
get SWORD modules installed under ~/.sword using installmgr.

With SWORD_PATH unset, and /etc/sword.conf containing the default 
/usr/share/sword/ path, apparently installmgr finds that, and decides to 
use it for new module installs -- but fails to check whether it is 
writeable.  So even if you have a writeable ~/.sword/ containing mods.d/ 
installmgr (run as a normal non-root user) *still* tries to install into 
/usr/share/sword/ and therefore (silently!) fails.

I really think installmgr (and probably SWORD as a whole) could and 
should do more checking of "writable-ness", as well as better error 
checking overall (so it would (a) not select a directory it cannot write 
to for write operations, and (b) if it did somehow accidentally do that, 
perhaps because no other workable choices exist in its list of places to 
try, then it would fail the actual module install attempt with a sane 
error message.

For now, my swordtest.sh script is going to have to keep doing

   export SWORD_PATH=~/.sword

because that is what seems to actually work.  If you can come up with a 
way to avoid that, which works, let me know :)


More information about the sword-devel mailing list