From aff158eb74a83b462a40188590309a8fd86c2236 Mon Sep 17 00:00:00 2001 From: Robert de Bock Date: Mon, 20 Sep 2021 09:23:41 +0200 Subject: [PATCH] Add a simple script to add community.general to a role. --- community.general.sh | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100755 community.general.sh diff --git a/community.general.sh b/community.general.sh new file mode 100755 index 0000000..ac03579 --- /dev/null +++ b/community.general.sh @@ -0,0 +1,13 @@ +#!/bin/sh + +if [ -f requirements.yml ] ; then + if ! grep 'collections:' requirements.yml > /dev/null ; then + echo "Adding collections header to requirements." + echo "collections:" >> requirements.yml + fi + if ! grep -- ' - name: community.general' requirements.yml > /dev/null ; then + echo "Adding community.general to requirement." + echo " - name: community.general" >> requirements.yml + fi +fi +