diff --git a/README.md b/README.md index ff07736..44ab01d 100644 --- a/README.md +++ b/README.md @@ -6,10 +6,12 @@ A pandoc LaTeX template for creating a curriculum vitae. - [Installation](#installation) - [Usage](#usage) - [Variables](#variables) + - [Docker](#docker) - [Italiano](#italiano) - [Installazione](#installazione) - [Uso](#uso) - [Variabili](#variabili) + - [Docker](#docker-1) ## English @@ -65,6 +67,29 @@ pandoc cv.yaml --template pancv -o cv.pdf - `left` (*string*) left part of the section. - `right` (*string*) right part of the section. +### Docker + +This template can also be used through a [docker](https://www.docker.com/) container. + +The first operation to do is to retrieve the [`norangebit/pandocker`](https://git.norangeb.it/norangebit/pandocker) image through the following command: + +```bash +docker pull norangebit/pandocker +``` + +after which you can run the container with the command: + +```bash +docker run --rm --volume "`pwd`:/data" --user `id -u`:`id -g` norangebit/pandocker +``` + +where instead of `` the desired pandoc command must be inserted. +For example, you can get the same result as the [previous example](#usage) through the command: + +``` +docker run --rm --volume "`pwd`:/data" --user `id -u`:`id -g` norangebit/pandocker pandoc cv.yaml --template pancv -o cv.pdf +``` + ## Italiano **Pancv** è un template per [pandoc](https://pandoc.org/) per la realizzazione di *curriculum vitae*. @@ -118,3 +143,27 @@ pandoc cv.yaml --template pancv -o cv.pdf - `items` (*list*) elementi della sezione. - `left` (*string*) parte di sinistra della sezione. - `right` (*string*) parte di destra della sezione. + +### Docker + +Questo template può essere utilizzato anche a traverso un container [docker](https://www.docker.com/). + +La prima operazione da fare è recuperare l'immagine [`norangebit/pandocker`](https://git.norangeb.it/norangebit/pandocker) attraverso il seguente comando: + +```bash +docker pull norangebit/pandocker +``` + +dopo di che è possibile eseguire il container con il comando: + +```bash +docker run --rm --volume "`pwd`:/data" --user `id -u`:`id -g` norangebit/pandocker +``` + +dove al posto di `` va inserito il comando pandoc desiderato. +Per esempio si può ottenere lo stesso risultato dell'[esempio precedente](#uso) attraverso il comando: + +``` +docker run --rm --volume "`pwd`:/data" --user `id -u`:`id -g` norangebit/pandocker pandoc cv.yaml --template pancv -o cv.pdf +``` +