Search Results

Search found 1 results on 1 pages for 'jasonhorner'.

Page 1/1 | 1 

  • Oneliner to count the number of tabs in each line of a file

    - by JasonHorner
    I have a file that is tab delimited. I would like a powershell script that counts the number of tabs in each line. I came up with this: ${C:\tabfile.txt} |% {$_} | Select-String \t | Measure-Object | fl count it yields 3, Which is the number of lines in the file. any pointers to what I'm doing wrong? I would like it to print a single number for each line in the file.

    Read the article

1