I need to concatenate a text file with a couple of lines. This one is my situation:
USER abc
PASS 123
USER efg
PASS 456
USER hil
PASS 789
and so on...
I need an output like this:
USER abc PASS 123
USER efg PASS 456
USER hil PASS 789
I tried solutions like:
awk 'NR % 2 == 1 { o=$0 ; next } { print o "<sep>" $0 } END { if ( NR % 2 == 1 ) { print o } }' INPUTFILE
sed -rn 'N;s/\n/ /;p' yourFile
cat file | paste -d' ' - -
What I recieved as output was:
USER abc
_PASS 123
USER efg
_PASS 456
Where _
is a simple space.