From b7bb5705ad376f887c54474b20273855e21a8d75 Mon Sep 17 00:00:00 2001 From: Maximilian Friedersdorff Date: Mon, 17 Jun 2019 11:51:43 +0100 Subject: [PATCH] Add colorised git alias output --- states/git/init.sls | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/states/git/init.sls b/states/git/init.sls index 84d1e59..459943c 100644 --- a/states/git/init.sls +++ b/states/git/init.sls @@ -28,13 +28,15 @@ include: 'alias.vt': 'tag -v', 'alias.tag': 'tag -s', 'alias.t': 'tag -s', + 'alias.alias': '!req=$\'\\033[0;31m=\\033[0m\'; git config --get-regexp ^alias\. | sed -e s/^alias\.// -e "s/\ /\t$req\ /"', } %} {% for var,val in git_confs.items() %} {{ var }}: git.config_set: - - value: {{ val }} + - value: >- + {{ val }} - global: True - user: {{ grains['user'] }} {% endfor %} -- 2.46.2