You are looking at historical revision 32807 of this page. It may differ significantly from its current revision.
Outdated egg!
This is an egg for CHICKEN 3, the unsupported old release. You're almost certainly looking for the CHICKEN 4 version of this egg, if it exists.
If it does not exist, there may be equivalent functionality provided by another egg; have a look at the egg index. Otherwise, please consider porting this egg to the current version of CHICKEN.
nest-tool
Introduction
The nest-tool egg provides both an extension and a command-line tool to parse and extract information from eggs repository listings.
Author
Mario Domenech Goulart
License
BSD
Requirements
Parameters and procedures
'''parameter:''' nest-tool:repository
Path or URL (HTTP) for the repository data file. Default is http://www.call-with-current-continuation.org/eggs/repository.
'''procedure:''' (nest-tool:raw)
Returns the data read from (nest-tool:repository)
'''procedure:''' (nest-tool:egg-name egg)
Returns the egg name from EGG (an item (a list) from (nest-tool:repository)).
'''procedure:''' (nest-tool:egg-date egg)
Returns the release date from EGG (an item (a list) from (nest-tool:repository)).
'''procedure:''' (nest-tool:egg-file egg)
Returns the egg filename from EGG (an item (a list) from (nest-tool:repository)).
'''procedure:''' (nest-tool:egg-dependencies egg)
Returns the list of dependencies from EGG (an item (a list) from (nest-tool:repository)).
'''procedure:''' (nest-tool:names #!optional raw)
Returns a list of eggs names from (nest-tool:raw). If RAW (a list) is provided, it is used instead of (nest-tool:raw).
'''procedure:''' (nest-tool:dates #!optional raw)
Returns an alist '((eggname . release-date) ...) from (nest-tool:raw). If RAW (a list) is provided, it is used instead of (nest-tool:raw).
'''procedure:''' (nest-tool:files #!optional raw)
Returns an alist '((eggname . filename) ...) from (nest-tool:raw). If RAW (a list) is provided, it is used instead of (nest-tool:raw).
'''procedure:''' (nest-tool:dependencies #!optional raw)
Returns a list ''((eggname dep1 dep2 ... depn) ...) from (nest-tool:raw). If RAW (a list) is provided, it is used instead of (nest-tool:raw).
'''procedure:''' (nest-tool:search-names pattern #!optional raw)
Searches for PATTERN (a regex object or a string representing a regex) in eggs names from (nest-tool:raw). If RAW (a list) is provided, it is used instead of (nest-tool:raw).
'''procedure:''' (nest-tool:search-dependencies pattern #!optional raw)
Searches for PATTERN (a regex object or a string representing a regex) in eggs dependencies lists from (nest-tool:raw). If RAW (a list) is provided, it is used instead of (nest-tool:raw).
Examples
csi> (nest-tool:search-names "meta.*") ((metakit ((date "200610211943")) "metakit.egg") (meta-setup ((date "200706181512")) "meta-setup.egg" tool format-modular http topological-sort) (metaphone ((date "200705190012")) "metaphone.egg" miscmacros misc-extn)) csi> (nest-tool:dependencies (nest-tool:search-names "meta.*")) ((metakit) (meta-setup tool format-modular http topological-sort) (metaphone miscmacros misc-extn))
The eggs which depend on spiffy
csi> (nest-tool:names (nest-tool:search-dependencies "spiffy")) (ajax phoghorn web-scheme spiffy-utils)
The number of eggs in the repository:
csi> (length (nest-tool:raw)) 303
The command line tool
$ chicken-nest-tool -h usage: chicken-nest-tool [OPTION | ARGUMENT] ... Provides operations on CHICKEN extensions repository listings Options: -h --help show this message -d --omit-date omit release date -D --omit-deps omit dependencies -f --omit-file omit egg filename -s --search ARGUMENT search eggs names -S --search-deps ARGUMENT search eggs dependencies -R --repository ARGUMENT specify a repository file (HTTP URLs are also accepted)
Examples
Searching for GTK eggs:
$ chicken-nest-tool.scm "gtk.*" gtk2 200702201349 gtk2.egg tinyclos gtk2-glade 200704170601 gtk2-glade.egg gtk2-gobject gtk2-gobject 200702201349 gtk2-gobject.egg
The same, but omitting the egg filename:
$ chicken-nest-tool -f -s "gtk.*" gtk2 200702201349 tinyclos gtk2-glade 200704170601 gtk2-gobject gtk2-gobject 200702201349
The same, showing only the egg name and the corresponding dependencies:
$ chicken-nest-tool -fd -s "gtk.*" gtk2 tinyclos gtk2-glade gtk2-gobject gtk2-gobject
Searching for eggs which depend on SRFIs that are provided as eggs, omitting the release date and egg filename:
$ chicken-nest-tool -fd -S "srfi.*" SO31 syntax-case,srfi-42,srfi-4-comprehensions args srfi-37 tool srfi-37 remote-launch openssl,tcp-server,srfi-37,mathh,args,misc-extn,miscmacros,synch,lookup-table,job-worker,osprocess html-plots srfi-40,stream-ext,html-stream html-stream srfi-40,stream-ext,stream-parser check syntax-case,srfi-42 stream-base64 srfi-40,stream-ext stream-ldif srfi-40,stream-ext,stream-base64 stream-wiki srfi-40,stream-ext,html-stream,stream-parser,sandbox,format-modular,stream-sections matcher syntax-case,srfi-57 srfi-4-comprehensions syntax-case,srfi-42 stream-htpasswd srfi-40,stream-ext testbase vector-lib,syntax-case,rlimit,srfi-37,args,testbase-results,testbase-driver srfi-19 numbers,miscmacros,locale,misc-extn,lookup-table,srfi-29 stream-parser srfi-40,stream-ext,format-modular mat5-lib testeez,eggdoc,syntax-case,datatype,endian-port,iset,srfi-40,srfi-47,z3 array-lib srfi-42,miscmacros,misc-extn rgraph srfi-40 stream-cgi srfi-40,stream-ext,content-type stream-ext srfi-40,format-modular stream-sections srfi-40,stream-ext,stream-parser testbase-driver syntax-case,rlimit,srfi-37,args,testbase,numbers,vector-lib,testbase-results,lookup-table,misc-extn stream-flash srfi-1,srfi-40,stream-ext,utils stream-httplog srfi-40,stream-ext,url scheme-dissect html-stream,srfi-40,stream-ext,stream-wiki,stream-sections,stream-parser,format-modular format-modular srfi-29 date-literals srfi-19
Version History
- 1.4
- Uses the release 3 repository file.
- 1.3
- Bug fix: doesn't break when a dependency is not a valid egg
- 1.2
- Dependencies graph generation.
- 1.1
- Category change to egg-tools (iraikov)
- 1.0
- initial release