bash - Parsing text file to variables -
$ cat file.txt example1@domain1-username
i'd parse file.txt
, export contents variables like:
var1=example1@domain1 var2=username
var1=$(cut -d "-" -f 1 file.txt) var2=$(cut -d "-" -f 2 file.txt)
Comments
Post a Comment