Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

bash loop lines in file

#!/bin/bash
filename='peptides.txt'
echo Start
while read p; do 
    echo $p
done < $filename
Comment

bash read file line by line

#!/bin/bash
while read line
do
  echo $line
done < /path/to/file
Comment

bash for each line of file

while read p; do
  echo "$p"
done <peptides.txt
Comment

read file line loop in bash

for word in $(cat peptides.txt); do echo $word; done
Comment

PREVIOUS NEXT
Code Example
Shell :: rails reset gemfile.lock 
Shell :: boost volume in ubuntu 18.04 
Shell :: enable ssh linux 
Shell :: git add file without commit 
Shell :: chmod add execute permission to useer 
Shell :: how to check pyqt version 
Shell :: ssh key 
Shell :: configure static ip address linux 
Shell :: camelcase python installing 
Shell :: git compare two branches 
Shell :: install visual studio on ubuntu 
Shell :: size folder command line 
Shell :: how to search the memory for the address of bin/sh 
Shell :: bash inline countdown 
Shell :: ssh permission denied publickey 
Shell :: ignore file git 
Shell :: storage setup in termux 
Shell :: powershell array 
Shell :: kill process using cmd 
Shell :: make changes to a previous commit 
Shell :: vmd in terminal 
Shell :: git merge branch to master 
Shell :: how to add color in shell script 
Shell :: install drush on ubuntu 
Shell :: how to ignore folder in gitignore duplicate 
Shell :: read all test in golang 
Shell :: check go is installed mac 
Shell :: create empty file command prompt cmd 
Shell :: how to check the list of all applications in ubuntu 
Shell :: How to stop a service with systemctl command 
ADD CONTENT
Topic
Content
Source link
Name
2+3 =