Created
March 26, 2017 22:06
-
-
Save jjsahalf/86ea0ecebd48930db20eca21abc22ec2 to your computer and use it in GitHub Desktop.
stream editor (sed) and basic string operations
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
ls | grep _logs |sed 's/_logs//g' | while read line | |
do | |
echo $line | |
v1="${line}_logs/${line}_white_list" | |
v2="${line}_logs/${line}_class_white_list" | |
if [ -f $v1 ]; then | |
echo "${v1} exists" | |
else | |
echo "${v1} does not exist!" | |
fi | |
if [ -f $v2 ]; then | |
echo "${v2} exists" | |
else | |
echo "${v2} does not exist!" | |
fi | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment