Commit 44700424 authored by Darko Poljak's avatar Darko Poljak

Merge branch '__update_alternatives_with_explorer' into 'master'

__update_alternatives: add state explorer

See merge request ungleich-public/cdist!848
parents c09165d1 a3bc8f94
Pipeline #916 passed with stage
in 1 minute
#!/bin/sh -e
path="$(cat "$__object/parameter/path")"
name="$__object_id"
link="$(readlink "/etc/alternatives/$name")"
if [ "$path" = "$link" ]
then echo present
else echo absent
fi
......@@ -17,9 +17,10 @@
# You should have received a copy of the GNU General Public License
# along with cdist. If not, see <http://www.gnu.org/licenses/>.
#
#
# Setup alternative - no standard way to create, always set
#
if [ "$(cat "$__object/explorer/state")" = 'present' ]
then exit 0
fi
path="$(cat "$__object/parameter/path")"
name="$__object_id"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment