Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # generate the 2 basic files
- cat /dev/urandom | tr -dc 'a-f0-9' | fold -w 32 | head -n 30 > random1.csv
- cat /dev/urandom | tr -dc 'a-f0-9' | fold -w 32 | head -n 30 > random2.csv
- # generate common lines
- cat /dev/urandom | tr -dc 'a-f0-9' | fold -w 32 | head -n 3 > common.csv
- # mix the common lines into the 2 files
- cat random1.csv common.csv | shuf > random11.csv
- cat random2.csv common.csv | shuf > random22.csv
- $ cat common.csv
- 8b1df61042e621bb3cd3ba43942b5ada
- 71b2368e90c6eb038e84ef29446c0dec
- 56697847ec43cc181a556625ec880d85
- # select one common line and look for it in the 2 files
- $ grep -n 8b1df61042e621bb3cd3ba43942b5ada random11.csv
- 14:8b1df61042e621bb3cd3ba43942b5ada
- $ grep -n 8b1df61042e621bb3cd3ba43942b5ada random22.csv
- 33:8b1df61042e621bb3cd3ba43942b5ada
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement