Created
March 9, 2015 17:15
-
-
Save srbmiy/a19d9e92403fee2bf506 to your computer and use it in GitHub Desktop.
This file contains 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/sh | |
#export WORKDIR=/cygdrive/c/Users/tmiy/Desktop | |
#export RE="<a href=\".*\"" | |
#export FILTERED=./testdata.txt | |
## main ## | |
cd /cygdrive/c/Users/tmiy/Desktop/Apple_files ## | |
grep -irho "<a href=\".*\"" ./ > ../testdata.txt ## | |
sed -e "s/\"//g" ../testdata.txt | sed -e "s/<A HREF=//g" > ../testdata2.txt ## | |
##cat ../testdata.txt ## | |
##cat ../testdata2.txt ## | |
cat ../testdata2.txt | while read line; do if [[ -f "../${line}" ]]; then echo ok; else echo No such file : "../${line}"; fi; done ## |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment