From c80eec632c4510f5e2ecbdf8df0ea051250f7a13 Mon Sep 17 00:00:00 2001 From: Ade Attwood Date: Mon, 28 Dec 2020 20:51:00 +0000 Subject: [PATCH] fix(core): fix bat install When installing bat from the Ubuntu repo the executable name is `catbat`. After updating to 20.04 the executable `bat` is not there. This links catbat -> bat so bat works as expected --- site-modules/core/manifests/packages.pp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/site-modules/core/manifests/packages.pp b/site-modules/core/manifests/packages.pp index 4e38300..47723e2 100644 --- a/site-modules/core/manifests/packages.pp +++ b/site-modules/core/manifests/packages.pp @@ -14,6 +14,7 @@ class core::packages { 'offlineimap', 'silversearcher-ag', 'tmux', + 'bat', 'urlscan', 'vim', 'zsh', @@ -31,6 +32,14 @@ class core::packages { ensure => absent } + exec { 'Link catbat to bat': + command => 'ln -s /usr/bin/batcat /usr/bin/bat', + onlyif => 'test -e /usr/bin/batcat', + creates => '/usr/bin/bat', + path => '/bin:/usr/bin', + provider => 'shell', + } + # core::packages::npm { [ # 'grunt', # 'intelephense',