From be90587e4819b357b8b8fba8c3e9990f7fa861d9 Mon Sep 17 00:00:00 2001 From: Dirk Eddelbuettel Date: Mon, 18 May 2015 18:13:26 -0500 Subject: [PATCH 1/3] updated Dockerfile - moved to contrib/ as it is not strictly needed at top-level - standardized Dockerfile to what Docker recommends as best practices: each RUN command creates a new AUFS layer so it is best to pool commands --- Dockerfile | 22 ---------------------- contrib/Dockerfile | 28 ++++++++++++++++++++++++++++ 2 files changed, 28 insertions(+), 22 deletions(-) delete mode 100644 Dockerfile create mode 100644 contrib/Dockerfile diff --git a/Dockerfile b/Dockerfile deleted file mode 100644 index cd2571a..0000000 --- a/Dockerfile +++ /dev/null @@ -1,22 +0,0 @@ -FROM ubuntu:trusty -ENV DEBIAN_FRONTEND noninteractive - -RUN apt-get update -q -RUN apt-get install -qy texlive-full -RUN apt-get install -qy python-pygments -RUN apt-get install -qy gnuplot - -RUN apt-get install wget - -RUN mkdir -p /usr/share/fonts/truetype/FiraSans -RUN mkdir -p /usr/share/fonts/opentype/FiraSans -RUN wget "dev.carrois.com/wordpress/wp-content/uploads/downloads/fira_3_1/FiraMono3106.zip" -RUN wget "dev.carrois.com/wordpress/wp-content/uploads/downloads/fira_3_1/FiraSans3106.zip" -RUN unzip FiraSans3106.zip -RUN unzip FiraMono3106.zip -RUN sudo cp /Fira*/WEB/*.ttf /usr/share/fonts/truetype/FiraSans/ -RUN sudo cp /Fira*/OTF/Fira* /usr/share/fonts/opentype/FiraSans/ -RUN sudo fc-cache -f -v - -WORKDIR /data -VOLUME ["/data"] diff --git a/contrib/Dockerfile b/contrib/Dockerfile new file mode 100644 index 0000000..c20a947 --- /dev/null +++ b/contrib/Dockerfile @@ -0,0 +1,28 @@ + +## Contributed by Walter Schulze (@awalterschulze) +## Simpliefied by Dirk Eddelbuettel (@eddelbuettel) + +FROM ubuntu:trusty +ENV DEBIAN_FRONTEND noninteractive + +RUN apt-get update -q \ + && apt-get install -qy \ + gnuplot \ + python-pygments \ + texlive-full \ + wget + +RUN cd /tmp \ + && mkdir -p /usr/share/fonts/truetype/FiraSans \ + && mkdir -p /usr/share/fonts/opentype/FiraSans \ + && wget "dev.carrois.com/wordpress/wp-content/uploads/downloads/fira_3_1/FiraMono3106.zip" \ + && wget "dev.carrois.com/wordpress/wp-content/uploads/downloads/fira_3_1/FiraSans3106.zip" \ + && unzip FiraSans3106.zip \ + && unzip FiraMono3106.zip \ + && cp Fira*/WEB/*.ttf /usr/share/fonts/truetype/FiraSans/ \ + && cp Fira*/OTF/Fira* /usr/share/fonts/opentype/FiraSans/ \ + && fc-cache -f -v \ + && rm -rf Fira* + +WORKDIR /data +VOLUME ["/data"] From 103c26d697ae174c08789633892edf7c0c2b8ca3 Mon Sep 17 00:00:00 2001 From: Dirk Eddelbuettel Date: Mon, 18 May 2015 18:15:25 -0500 Subject: [PATCH 2/3] add contributed script to install Fira Font on Ubuntu --- contrib/getFiraFont.sh | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 contrib/getFiraFont.sh diff --git a/contrib/getFiraFont.sh b/contrib/getFiraFont.sh new file mode 100644 index 0000000..6f3ff5e --- /dev/null +++ b/contrib/getFiraFont.sh @@ -0,0 +1,20 @@ +#!/bin/bash + +## cf from http://programster.blogspot.com/2014/05/ubuntu-14-desktop-install-fira-sans-and.html + +cd /tmp + +# install unzip just in case the user doesn't already have it. +sudo apt-get install unzip -y +wget "http://dev.carrois.com/wordpress/wp-content/uploads/downloads/fira_3_1/FiraSans3106.zip" +wget "http://dev.carrois.com/wordpress/wp-content/uploads/downloads/fira_3_1/FiraMono3106.zip" + +unzip FiraMono3106.zip +unzip FiraSans3106.zip + +sudo mkdir -p /usr/share/fonts/truetype/FiraSans +sudo mkdir -p /usr/share/fonts/opentype/FiraSans +sudo cp Fira*/WEB/*.ttf /usr/share/fonts/truetype/FiraSans/ +sudo cp Fira*/OTF/Fira* /usr/share/fonts/opentype/FiraSans/ + +sudo fc-cache -fv From 6dd155c4b973af1ac955bfdfa46e1117d7326d70 Mon Sep 17 00:00:00 2001 From: Dirk Eddelbuettel Date: Mon, 18 May 2015 18:17:03 -0500 Subject: [PATCH 3/3] add short note about contrib/ to README.md --- README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index c0fc0b4..2a844c5 100644 --- a/README.md +++ b/README.md @@ -20,7 +20,8 @@ and the section indicator are hardcoded into the theme. For the demo you need Depending on the Linux distribution, the packaged name of Fira Sans might be `Fira Sans OT` instead of `Fira Sans`. In that case, you may have to edit -`beamerfontthememetropolis.sty`. +`beamerfontthememetropolis.sty`. You may also need to install Fira Sans; see +the `contrib/` directory for more ### Usage