feat: more atuin tricks

main
sudo pacman -Syu 2024-03-12 03:39:44 +07:00
parent 35847e63c9
commit cb84081302
2 changed files with 19 additions and 1 deletions

View File

@ -427,7 +427,15 @@ rsync -avzP src/ dst</pre>
<span class="pl-k">from</span> history
<span class="pl-k">where</span> id not <span class="pl-k">in</span> (<span class="pl-k">select</span> <span class="pl-c1">max</span>(id)
<span class="pl-k">from</span> history
<span class="pl-k">group by</span> command);</pre>
<span class="pl-k">group by</span> command);
<span class="pl-k">delete</span>
<span class="pl-k">from</span> history
<span class="pl-k">where</span> length(command) <span class="pl-k">&gt;</span> <span class="pl-c1">128</span>;</pre>
</div>
<p>Remove shell history:</p>
<div class="highlight highlight-source-shell">
<pre>cat /dev/null <span class="pl-k">&gt;</span> <span class="pl-k">~</span>/.zsh_history</pre>
</div>
<div class="markdown-heading">
<h2 class="heading-element">

View File

@ -305,6 +305,16 @@ from history
where id not in (select max(id)
from history
group by command);
delete
from history
where length(command) > 128;
```
Remove shell history:
```sh
cat /dev/null > ~/.zsh_history
```
## [F2](https://github.com/ayoisaiah/f2)