delorie.com/archives/browse.cgi | search |
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: | <CAAVSQ3tkg3es-uBn+yFroysi5xAOtNqW5hTs2yAWQfo47rUaVQ@mail.gmail.com> |
References: | <CAAVSQ3vnFZkWdWn=LCbf+WSM0vOx9pwW+OaeTs47EdO8nfmC_w AT mail DOT gmail DOT com> <20111130211002 DOT 32B5081F6275 AT turkos DOT aspodata DOT se> <CAAVSQ3tkg3es-uBn+yFroysi5xAOtNqW5hTs2yAWQfo47rUaVQ AT mail DOT gmail DOT com> |
Comments: | In-reply-to Luigi Salvatore Palese <ultrabit AT gmail DOT com> |
message dated "Thu, 01 Dec 2011 16:02:56 +0100." | |
Mime-Version: | 1.0 |
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 |
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
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |