Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

bash get value sended to pipe

stdin=$(cat)

echo "$stdin"
Comment

bash script get value from piped input

#!/bin/bash
if [[ -p /dev/stdin ]]
    then
    PIPE=$(cat -)
    echo "PIPE=$PIPE"
fi
echo "ARGS=$@"
Comment

PREVIOUS NEXT
Code Example
Shell :: dev/random dev/urandom bash 
Shell :: apt sources.list amd64 only 
Shell :: create necxt app 
Shell :: laravel view.engine.resover not exists 
Shell :: partager le wifi de son pc ubuntu a son telephone 
Shell :: jscore 
Shell :: upgrade pip error 
Shell :: github push master 
Shell :: heroku restart 
Shell :: linux replace string in all files 
Shell :: date linux minus 1 day 
Shell :: untar gz file 
Shell :: docker purge all 
Shell :: apagar raspberry desde terminal 
Shell :: vim plug 
Shell :: install jq command 
Shell :: batch delete folder 
Shell :: qcow2 to vdi 
Shell :: linux search for line in file 
Shell :: How to Block apache Ports 
Shell :: No repository for "Api Log Entity" was found. 
Shell :: find a file in all subdirectories in linux 
Shell :: discord components python install 
Shell :: how to install metasploit in ubuntu 
Shell :: jq to windows 
Shell :: change folder owner recursively linux 
Shell :: disable pre commit hook 
Shell :: docker run restart on boot 
Shell :: linux show which serial ports are in use 
Shell :: how to install eclipse in ubuntu 
ADD CONTENT
Topic
Content
Source link
Name
2+6 =