To count the number of lines in the output from a command, enter count after the pipe symbol. For example:
user@host> show configuration | count
Count: 269 lines