Created
June 6, 2012 22:48
-
-
Save jarretgabel/2885311 to your computer and use it in GitHub Desktop.
Takes a txt file with a list and adds quotes before and after each line with a comma seperator
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 | |
echo -n "Enter target filename and press [ENTER]: " | |
read target | |
echo -n "Enter destination filename and press [ENTER]: " | |
read destination | |
touch $destination | |
echo -e "" > $destination | |
while read line | |
do | |
echo -e \"$line\"\, >> $destination; | |
done < $target |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment