Answers for "loop through a file in bash"

8

loop file bash

while read p; do
  echo "$p"
done <peptides.txt
Posted by: Guest on April-06-2020
-2

for loop in bash for files

#!/bin/bash
FILES=/path/to/*
for f in $FILES
do
  echo "Processing $f file..."
  # take action on each file. $f store current file name
  cat $f
done
Posted by: Guest on September-07-2020

Code answers related to "Shell/Bash"

Browse Popular Code Answers by Language