From 1c5646bbc7b1da2297f1c6f59b14edc5569807f4 Mon Sep 17 00:00:00 2001 From: Scott Wallace Date: Sun, 13 Jan 2019 10:44:46 +0000 Subject: [PATCH] Add some font shizzle to the Linux desktop install process --- .../roles/linux_desktop/tasks/software.yaml | 30 +++++++++++++++++++ .ansible/roles/linux_desktop/vars/main.yaml | 1 + 2 files changed, 31 insertions(+) diff --git a/.ansible/roles/linux_desktop/tasks/software.yaml b/.ansible/roles/linux_desktop/tasks/software.yaml index 9091fe1..2b87000 100644 --- a/.ansible/roles/linux_desktop/tasks/software.yaml +++ b/.ansible/roles/linux_desktop/tasks/software.yaml @@ -22,3 +22,33 @@ command: "snap install {{ item }}" with_items: "{{ linux_apps }}" become: true + +- name: Installing fonts + tags: install + block: + - name: Create temporary file for Modern Pictograms font + tempfile: + state: file + suffix: ".zip" + register: fontzip + + - name: Download Modern Pictograms font + get_url: + url: https://www.fontsquirrel.com/fonts/download/modern-pictograms + dest: "{{ fontzip.path }}" + force: true + register: fetchurl + + - name: Unzip Modern Pictograms font + unarchive: + src: "{{ fontzip.path }}" + dest: "~/.local/share/fonts" + exclude: "*.txt" + + - name: Remove temporary file + file: + path: "{{ fontzip.path }}" + state: absent + + - name: Refresh font cache + command: "fc-cache -f" diff --git a/.ansible/roles/linux_desktop/vars/main.yaml b/.ansible/roles/linux_desktop/vars/main.yaml index 521e2f0..9a9d567 100644 --- a/.ansible/roles/linux_desktop/vars/main.yaml +++ b/.ansible/roles/linux_desktop/vars/main.yaml @@ -30,6 +30,7 @@ linux_packages: - resilio-sync - screen - sonos-controller-unofficial + - ttf-mscorefonts-installer - units - vim - wireshark-qt