Possibly handy piping of commands…
cut -d" " -f7 D*.txt|sort|uniq>gates.txt
This:
- takes all files matching “D*.txt”
- cut -d” ” -f7 gets the 7th column, using the space character as a delimiter
- sorts the values ascending
- gets all unique values
- pipes into output file gates.txt