X-Authentication-Warning: delorie.com: mail set sender to geda-user-bounces using -f X-Recipient: geda-user AT delorie DOT com X-Mailer: exmh version 2.7.2 01/07/2005 (debian 1:2.7.2-18) with nmh-1.3 X-Exmh-Isig-CompType: repl X-Exmh-Isig-Folder: inbox To: geda-user AT delorie DOT com Subject: Re: [geda-user] Dynamic loading personal components (with subfolder) into the search component tree of gschem In-reply-to: References: <20111130211002 DOT 32B5081F6275 AT turkos DOT aspodata DOT se> Comments: In-reply-to Luigi Salvatore Palese message dated "Thu, 01 Dec 2011 16:02:56 +0100." Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Message-Id: <20111203133340.E09A181D541B@turkos.aspodata.se> Date: Sat, 3 Dec 2011 14:33:40 +0100 (CET) From: karl AT aspodata DOT se (Karl Hammar) X-Virus-Scanned: ClamAV using ClamSMTP Reply-To: geda-user AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: geda-user AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk Luigi: > your script looks good but you have to manage the growing of the gafrc file. Yes, I know. > Following your way, i'm making the scheme in attachment. Great. > Now the needed lines to start the guile script from gafrc are only as > follow: > ; > (define geda-rchome-path (build-path (getenv "HOME") ".gEDA")) > (load (build-path geda-rchome-path "local-symbols-library.scm")) It seems I can reduce thoose two lines to: (load "local-symbols-library.scm") ////// Appearantly, I can load stuff from my .gEDA dir without any special magic, nice: $ tail -1 .gEDA/gafrc (load "hello.scm") $ cat .gEDA/hello.scm (display "Hello World!\n") $ gschem Hello World! ^C $ Even better, if I do: (load-scheme-dir (build-path (getenv "HOME") ".gEDA/gafrc.d")) in my gafrc, gschem will load all my files in ~/.gEDA/gafrc.d. ////// > ; > ; > (component-library-add-tree "personal" "/usr/local/share/symbols") Adding: (component-library-add-tree "cvs" "$HOME/Net/cvs/cvs.gedasymbols.org/www/user") to my .gafrc didn't do any difference to the library browser, hmm. > ; > ; > > At this point the folder name will be used as description in the tree: > > +Generic\ capacitors/ > cap-1.sym > +AVX\ Capacitors/ > idc.sym > > I notice an interesting feature if the subfolders are named like: > Generic\ capacitors/ > Generic\ capacitors - AVX/ > Generic\ capacitors - AVX - IDC/ > > The items will be displayed sequentially in the tree. Why not make the string look like "prefix/dir/subdir/.../", i.e., in the example above it could be shown as: "personal/Generic capacitors" "personal/Generic capacitors/AVX Capacitors" Regards, /Karl Hammar ----------------------------------------------------------------------- Aspö Data Lilla Aspö 148 S-742 94 Östhammar Sweden +46 173 140 57