• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

help understanding this command

bwanaaa

Senior member
in terminal:

pdftotext filename.pdf -|grep -v grep|grep AAAAA -A 1000|tr -d '\014'|sed -e '/^$/d'|base64 -d > test.zip

OK, it takes a pdf file and converts it to text. but after that there are a bunch of greps that are throwing me. I get that it searches for AAAAA but also do not understand what follows.

tnx.
 
grep -v grep : print all lines that don't contain 'grep'
grep AAAAA -A 1000 : then print all lines that contain AAAAA and also the next 1000 lines from each matching line
tr -d '\014' : remove any 'form feed' characters
sed -e '/^$/d' : delete all blank lines
base64 -d : decode from base64
> test.zip : store the resulting data in test.zip
 
Back
Top