[brlcad-commits] CVS: brlcad/src/tclscripts/archer Archer.tcl, 1.41, 1.42
Open Source Solid Modeling CAD
Brought to you by:
brlcad
From: Sean M. <br...@us...> - 2007-10-01 05:37:40
|
Update of /cvsroot/brlcad/brlcad/src/tclscripts/archer In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv8719/tclscripts/archer Modified Files: Archer.tcl Log Message: restructure to allow uninstalled source directory invocations, as well as not making failure to find/load plugins fatal. Index: Archer.tcl =================================================================== RCS file: /cvsroot/brlcad/brlcad/src/tclscripts/archer/Archer.tcl,v retrieving revision 1.41 retrieving revision 1.42 diff -w -u -r1.41 -r1.42 --- Archer.tcl 18 May 2007 13:05:24 -0000 1.41 +++ Archer.tcl 1 Oct 2007 05:37:43 -0000 1.42 @@ -12324,8 +12324,17 @@ set pwd [::pwd] # developer & user plugins -# foreach plugindir [list [file join $env(ARCHER_HOME) $brlcadDataPath plugins archer]] - foreach plugindir [list [file join $brlcadDataPath plugins archer]] { + set pluginPath [file join [bu_brlcad_data "plugins"] archer] + if { ![file exists $pluginPath] } { + # try a source dir invocation + set pluginPath [file join [bu_brlcad_data "src"] archer plugins] + } + if { ![file exists $pluginPath] } { + # give up on loading any plugins + return + } + + foreach plugindir [list $pluginPath] { ::cd $plugindir pluginLoadCWDFiles } |