Question:
How do I know the space s in a file are white spaces or tabs in UNIX?
Answer:
Method 1:
Use vi or vim,
After opening the file, type :set list, all the tabs will shown as “^I”
$ vi abc This file^Icontains some spacesĀ and^I^Itabs.$ Do you^I see any ^I ^I tab?$ ~
Method 2:
Use cat command with -vt flags.
$ cat -vt abc This file^Icontains some spacesĀ and^I^Itabs. Do you^I see any ^I ^I tab?
