Re: Tcl source command directory



I tend to build up and use the absolute pathname instead of relative
ones.
In each called script, put:

set scriptName [file tail [set scriptPath [info script]]]
set basedir [file dirname $scriptPath]
source [file join $basedir <your-libname-here>]

.



Relevant Pages

  • SUID/GUID files search !
    ... the given script line not displaying the SUID / SGID files in /usr/bin directory. ... Another important thing is that please tell me how can i get the Absolute pathname of the files of above command. ...
    (Fedora)
  • Re: Brightness issue with my laptop - Ubuntu 8.10
    ... but the same sad story. ... It simply refuses to work, ... You could modify /etc/sudoers so that script runs without a password. ... (use an absolute pathname for the script) ...
    (comp.unix.shell)
  • Re: Tcl source command directory
    ... In each called script, put: ... set basedir [file dirname $scriptPath] ... The above code produces a relative path not an absolute one. ...
    (comp.lang.tcl)
  • Re: Brightness issue with my laptop - Ubuntu 8.10
    ... xinit/xinitrc.d/foo.sh with permissions of 755. ... I actually don't have xinitrc.d directory, but I put the script (with ... 755 perm. ... (use an absolute pathname for the script) ...
    (comp.unix.shell)