~fabionatali/quote-generator

Emacs-Org-LaTeX-based solution to generate PDF price quotations
-*- mode: org -*-

* Quote generator

A small system to produce company quotes. Based on Emacs, Org Mode, and LaTeX.

** Installation

You should have received this file as part of a larger repository. In order to
use the software, just create a local copy of the repository.

All software dependencies are listed in the =manifest.scm= file at the root of
this repository, make sure they are all available in your system. If you are on
a [[https://guix.gnu.org/][Guix]] system, a working environment can be instantiated by:

#+begin_src shell
guix shell --pure --manifest=manifest.scm
#+end_src

** Usage

Edit the =main.org= file and run =make=. A PDF copy of the quote will be saved
in the =build= directory.

#+ATTR_HTML: :width 50%
[[./assets/example-quote.pdf][file:./assets/example-quote.jpg]]

** Misc

*** Direnv

Optionally, an example =.envrc= file is provided for use in combination with
[[https://direnv.net/][direnv]].

If direnv is installed and if the =.envrc= file is enabled via =direnv allow=, a
Guix environment will be activated automatically when =cd=-ing into the project
folder.

*** PDF to JPEG

Incidentally, the following [[https://imagemagick.org/][ImageMagick]] command is how the provided [[file:assets/example-quote.pdf][example PDF
quote]] can be made into a [[file:assets/example-quote.jpg][JPEG image]], e.g. to be included in this README file.

#+begin_src bash
convert \
    -density 300 \
    -compress jpeg \
    example-quote.pdf \
    -background gray50 \
    -splice 10x0+0+0 \
    -gravity Center \
    +append \
    +gravity \
    -chop 10x0+0+0 \
    -bordercolor gray50 \
    -border 10 \
    example-quote.jpg
#+end_src

** Authors

- Fabio Natali, me@fabionatali.com

** License

Quote Generator is free software. You can redistribute it and/or modify it under
the terms of the GNU General Public License version 3 or later. See [[file:COPYING][COPYING]] for
the full text of the license.