Skip to content
Snippets Groups Projects
Commit 45a4479f authored by nimrod's avatar nimrod
Browse files

Pretty much it.

parent 257a8c26
No related branches found
No related tags found
No related merge requests found
.git/
.gitignore
.dockerignore
*.md
*.dot
*.pdf
example/
*.swp
Dockerfile
~*
*~
*.sw[op]
*.py[cod]
.DS_Store
__pycache__/
.vagrant/
vendor/
Thumbs.db
*.retry
.svn/
.sass-cache/
*.log
*.out
*.so
node_modules/
.npm/
nbproject/
*.ipynb
.idea/
*.egg-info/
*.[ao]
.classpath
.cache/
bower_components/
*.class
*.[ewj]ar
secring.*
.*.kate-swp
.swp.*
.directory
.Trash-*
build/
_build/
dist/
.tox/
*.pdf
*.exe
*.dll
*.gz
*.tgz
*.tar
*.rar
*.zip
*.pid
*.lock
*.env
.bundle/
FROM golang:1.9-alpine as on-change
RUN apk --update add git && \
rm -rf /var/cache/apk/* && \
/usr/local/go/bin/go get github.com/spelufo/on-change
FROM debian:stretch-slim
COPY --from=on-change /go/bin/on-change /usr/local/bin
RUN DEBIAN_FRONTEND=noninteractive apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
graphviz \
lmodern \
make \
pandoc \
sudo \
texlive-extra-utils \
texlive-fonts-recommended \
texlive-font-utils \
texlive-latex-base \
texlive-latex-extra \
texlive-luatex && \
rm -rf /tmp/* /var/tmp/* /var/lib/apt/lists/* /var/cache/apt/archives/*
VOLUME /project
WORKDIR /project
COPY entrypoint /entrypoint
ENTRYPOINT ["/entrypoint"]
CMD ["on-change", ".", "make"]
MIT License
Copyright (c) 2017 Adar Nimrod
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
# Presentation
A Dockerized presentation toolkit for building presentation from markup (like
Markdown or DOT).
## Usage
`docker run -itv "$PWD:/project" adarnimrod/presentation`
Will watch the current directory and run `make` whenever a file changes. One can
add a shell alias `alias presentation='docker run -itv "$PWD:/project"
adarnimrod/presentation'` for easier use.
See the example folder for more details.
## Contains
- [Pandoc](http://pandoc.org/)
- [Graphviz](www.graphviz.org/)
- [GNU Make](https://www.gnu.org/software/make/)
- [LuaTex](http://luatex.org/)
- [LaTeX](http://www.latex-project.org/)
- [on-change](https://github.com/spelufo/on-change)
## License
This software is licensed under the MIT license (see `LICENSE.txt`).
## Author Information
Nimrod Adar, [contact me](mailto:nimrod@shore.co.il) or visit my [website](
https://www.shore.co.il/). Patches are welcome via [`git send-email`](
http://git-scm.com/book/en/v2/Git-Commands-Email). The repository is located
at: <https://www.shore.co.il/git/>.
#!/bin/sh
set -eu
uid="$(stat . --format '%u')"
gid="$(stat . --format '%g')"
sudo -Eu "#$uid" -g "#$gid" -- "$@"
*.pdf
.PHONY: all clean
all: presentation.pdf
presentation.pdf: diagram.pdf
pandoc -t beamer presentation.md -o presentation.pdf
diagram.pdf: diagram.dot
dot diagram.dot -Tpdf > diagram.pdf
clean:
- rm *.pdf
# Example presentation
An example presentation written in Markdown and DOT.
## Usage
To watch the current directory and build the presentation whenever a change
occurs
`docker run -tv "$PWD:/project" adarnimrod/presentation`
To build the presentation and exit
`docker run -tv "$PWD:/project" adarnimrod/presentation make`
digraph Diagram {
"Point A" -> "Point B" [label="Route"]
}
---
title: Presentation
author: Your name here
...
# Section
## Heading
- Bullet point.
- Another bullet point.
## Diagram
![Diagram](diagram.pdf)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment