2022-02-14 03:22:51 +01:00
|
|
|
---
|
|
|
|
title: detect columns
|
|
|
|
layout: command
|
|
|
|
version: 0.59.0
|
|
|
|
---
|
|
|
|
|
|
|
|
splits contents across multiple columns via the separator.
|
|
|
|
|
|
|
|
## Signature
|
|
|
|
|
2022-02-20 02:13:33 +01:00
|
|
|
```> detect columns --skip --no-headers```
|
2022-02-14 03:22:51 +01:00
|
|
|
|
|
|
|
## Parameters
|
|
|
|
|
|
|
|
- `--skip {int}`: number of rows to skip before detecting
|
2022-02-20 02:13:33 +01:00
|
|
|
- `--no-headers`: don't detect headers
|
|
|
|
|
|
|
|
## Examples
|
|
|
|
|
|
|
|
Splits string across multiple columns
|
|
|
|
```shell
|
|
|
|
> echo 'a b c' | detect columns -n
|
|
|
|
```
|
|
|
|
|
|
|
|
Splits a multi-line string into columns with headers detected
|
|
|
|
```shell
|
|
|
|
> echo $'c1 c2 c3(char nl)a b c' | detect columns
|
|
|
|
```
|