I've read numerous awk & sed liners to try and perform what I need and none seem to work. What I am trying to do is simply count the number of CR/LF breaks in my Linux file. This file has plain LF newlines as well, I just need to know how many true records I'm importing.
One such awk line I've tried is
awk '/^M$/{n++}; END { print n+0 }' my_file
or some such. This did not work. Any help would be great. I'm not an awk guru so please go easy.