-t, --tabs
Have tabs N characters apart instead of 8 (enables -a), or use comma separated list of explicit tab positions.
An option of unexpandx.
Usage
unexpandx -t N, LIST [FILE]...
unexpandx --tabs=N, LIST [FILE]...Details
| Short | Long | Value | Default | Meaning |
|---|---|---|---|---|
-t | --tabs | N, LIST | have tabs N characters apart instead of 8 (enables -a), or use comma separated list of explicit tab positions |
Examples
Convert 4-space indentation and alignment to tabs
unexpandx -t 4 main.goRetab a Go file for gofmt, leaving alignment inside lines alone
unexpandx -t 4 --first-only main.goRetab a report laid out in fixed columns
unexpandx -t 10,20,40 report.txtEdit with spaces, then hand the file back with tabs
expandx -t 4 a.go | unexpandx -t 4 --first-only > b.goRestore the tabs a Makefile needs after an editor turned them into spaces
unexpandx -t 8 spaces.mk > MakefileHelp in the terminal
gnux help unexpandx --tabs