README 826 B

1234567891011121314151617181920
  1. # clihtml
  2. Generates HTML from the CLI, using a basic syntax for constructing the document. Very trusty of user input, so beware.
  3. ## Operators
  4. + open and go into element
  5. . create an element on this level
  6. - leave current element, create new element and go into it
  7. ---- same as a single dash (-) but leaves 4 parent elements
  8. @ add attribute to currently open element, no processing done
  9. = after element name sets content directly, good for paragraphs etc.
  10. ## Sample usage
  11. clihtml '<!DOCTYPE html>' +html +head .title='cli generated' -body h1='stuff on a stick' +div '@style="background-color:red;"' @align=center +div '@style="width:50%;margin:auto;background-color:green;"' .p='I am a paragraph, look at me go!' --p 'Just backed up twice.' .p=rawr +div +img @src='https://stuff.umeahackerspace.se/kattgatan-cropped.svg'