by asicsp · 5y ago · 0 comments
I was working on a script to provide cut like syntax using awk, mainly for awk's default field separation and regexp delimiters. It isn't ready, but I just created a repo with what I have so far: https://github.com/learnbyexample/regexp-cut
```$ echo "words are far apart" | xargs```
Although, it does have its caveats. https://stackoverflow.com/a/12973694
I use `cut` precisely when I want this behaviour. If something actually is tab-separated, I don't want `cut -f3` to give me the 4th column just because the value in column 1 was the empty string.