Hi there
newbie here, i am trying to get the following script to work, but for the life of me, i cannot get it working.
Note: the <results> </results> are required. This is for JSS Extension Attribute.
Code:
#!/bin/bash
DIR=/Desktop/OneDrive - Name of Company
if [ ! -d $DIR ]; then
echo <results> "Directory exists" </results>
else
echo <results> "Incorrect" </results>
fi
i have success in doing something similar for Applications but not folder. Below is just an example of what i am trying to achieve
Code:
#!/bin/sh
# Identify App Store vs non App Store.
if [ -e /Applications/Numbers.app ]; then
if [ -e /Applications/Numbers.app/Contents/_MASReceipt/ ]; then
echo "<result>Apple</result>"
else
echo "<result>BCGS</result>"
fi
else
echo "<result>Not Installed</result>"
fi
And yes i have tried playing around with where the <result> tag is put as well. Where the result tag is in " "
Thanks in advance

please be gentle lol