This the simple and easy code to read a file using linux script.
Here in the code we read all the lines and display each line :)
file="/home/system5/Desktop/negativewords/neagtivewords" #readng neg words
while IFS= read -r line
do
# display $line or do somthing with $line
printf '%s\n' "$line"
done <"$file"
Here in the code we read all the lines and display each line :)
file="/home/system5/Desktop/negativewords/neagtivewords" #readng neg words
while IFS= read -r line
do
# display $line or do somthing with $line
printf '%s\n' "$line"
done <"$file"