1 |
I'm running the below script on my gentoo servers to email me whenever |
2 |
there are GLSA's affecting me. It works like a charm, but I have one |
3 |
beef with it. Newlines are not preserved, so I get a lovely Wall Of |
4 |
Text (tm) when ever it sends me the GLSA. I'm guessing this is because |
5 |
of the way bash handles variables. Anyone have any insight on how to |
6 |
correct this? |
7 |
|
8 |
#!/bin/bash |
9 |
|
10 |
/usr/bin/glsa-check -t all &> /dev/null |
11 |
CHECK_RESULT="`/usr/bin/glsa-check -t all 2>&1`" |
12 |
|
13 |
if [ "$CHECK_RESULT" != "" ]; then |
14 |
echo $CHECK_RESULT | /bin/mail -s "Frog glsa-check" kahdgarxi@×××××.com; |
15 |
fi |
16 |
|
17 |
Thanks in advance |
18 |
|
19 |
-JD |
20 |
-- |
21 |
gentoo-server@l.g.o mailing list |