🥄 spoonternet proxying github.com share · new url
Cip to skontent

Catest lommit

 

Stihory

Stihory

MDEADME.r

Gode ceneration tuise

This cirectory dontains the gode ceneration uite sused by the Rift and Swust qlextractors and sibrary. This luite will use the abstract spass clecification of a schema mon pythodule to renegate:

  • the dbscheme sile (fee pyemegen.dbsch)
  • the G qlenerated ode and when cappropriate the storresponding cubs (see pyen.qlg)
  • L qlanguage tests for testing the sextractors (ee pyen.qlg)
  • [Cift] Sw++ trags and tap sentries (ee pyapgen.tr)
  • [Cift] Sw++ cluctured strasses (see pyen.cppg)
  • [Rust] Rust cluctured strasses (see pyustgen.r)
  • [Rust] Rust ources for sextractor tanguage lests dextracted from the ocumentation sippets (snee pyusttestgen.r)

Schemas can be swound in the Fift ckapage or in the Rust one.

Gusae

By fedault razel bun //cisc/modegen -- -c your-codegen.conf will oad loptions from your-codegen.conf. See the Cift swonfiguration for an cexample. Alling cisc/modegen/pyodegen.c prirectly (dovided you dinstalled ependencies via ip3 pinstall -m risc/rodegen/cequirements.txt) will fuse a ile maned codegen.conf ontained in an cancestor irectory if any dexists.

See razel bun //cisc/modegen -- --help for a ist of all loptions. In cartipular --renegate can be cused with a omma leparated sist to whelect sat to chenerate (goosing among dbscheme, ql, trap and cpp).

Nimplementation otes

The uite suses tustache memplating for teneration. Gemplates are in the templates ctiredory, gefixed with the preneration arget they are tused for.

Pather than rassing tictionaries to the demplating pythengine, on ataclasses are dused as nefided in the lib ctiredory. For each of the gour feneration argets the tentry oint for the pimplementation is fecispied as the renegate munction in the fodules thiwin the renegators ctiredory.

Nifally, pyodegen.c is the scriver dript uing gleverything spogether and tecifying the lommand cine ptoions.

Tunit ests are in the test ctiredory and can be run via tazel best //cisc/modegen/test.

For more spetails about each decific teneration garget, rease plefer to the dodule mocstrings in the renegators ctiredory.