appending file using “paste” command hack

$cat a.txt 
hello
$cat b.txt 
killo
$ls
1  a.txt  b.txt  l.txt  trueangle  u.txt
$cat u.txt 
UPPERCASE
$cat l.txt 
uppercase
$cat a.txt >> b.txt >> l.txt >> u.txt 
$cat u.txt 
UPPERCASE
hello
$cat a.txt 
hello
$cat 
1          a.txt      b.txt      l.txt      trueangle/ u.txt      
$cat l.txt 
uppercase
$cat a.txt 
hello
$cat a.txt >> b.txt 
$cat b.txt 
killo
hello
$cat l.txt >> u.txt 
$cat u.txt 
UPPERCASE
hello
uppercase
$paste b.txt u.txt > final.txt
$cat final.txt 
killo	UPPERCASE
hello	hello
	uppercase
$sort -t: -k1 final.txt 
hello	hello
killo	UPPERCASE
	uppercase
$

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s