mirror of
https://github.com/CZ-NIC/pz.git
synced 2022-02-13 01:03:07 +03:00
suppressing quotes warning
This commit is contained in:
@@ -65,9 +65,11 @@ How does your data look when pythonized via `pz`? Which Bash programs may the ut
|
||||
Just use the `[:]` notation.
|
||||
|
||||
```bash
|
||||
echo "hello world" | pz s[6:] # hello
|
||||
echo "hello world" | pz s[6:] # world
|
||||
```
|
||||
|
||||
<sub>Note that suppressing quotes around the argument may not work (Zsh) or lead to an unexpected behaviour: `touch s1 && echo "hello" | pz s[1]` → `Exception: <class 'NameError'>`. Use `echo "hello" | pz 's[1]'` instead.</sub>
|
||||
|
||||
## Prepend to every line in a stream
|
||||
|
||||
We prepend the length of the line.
|
||||
@@ -694,4 +696,4 @@ As seen, `a` was incremented 3× times and `b` on twice because we had to proces
|
||||
### Bash completion
|
||||
1. Run: `apt-get install bash-completion jq`
|
||||
2. Copy: [extra/pz-autocompletion.bash](./extra/pz-autocompletion.bash) to `/etc/bash_completion.d/`
|
||||
3. Restart terminal
|
||||
3. Restart terminal
|
||||
|
||||
Reference in New Issue
Block a user