/ogg

Open Graph image generator from text

Primary LanguageShellGNU General Public License v3.0GPL-3.0

Open Graph image generator

Description

Generate Open Graph image (og:image) from text content. Image (og:image) is saving in working directory, named like source file or url's domain.

Install

Clone or download and

chmod +x ogg

Needed:

  • imagemagick
sudo apt install imagemagick
  • pandoc (if you wish to generate og:image from url)
sudo apt install pandoc
  • xsltproc (if you wish to use -p option (parse main content from source URL)
sudo apt install xsltproc)

Usage:

ogg [options] [input-file or input-url]

Options are:

  • -w [number] - og:image width (968px by default);
  • -h [number] - og:image height (504px by default);
  • -b [string] - background color of the og:image ('white' by default);
  • -p [filename]- use xslt themplate (parser.xsl in working dir if filename not set) for parsing main content part from url;