# Kakhist: persist command history, history UI

**URL:** <https://discuss.kakoune.com/t/kakhist-persist-command-history-history-ui/1795>\
**Category:** Plugins\
**Created:** [June 26, 2021, 6:59am UTC](https://discuss.kakoune.com/t/kakhist-persist-command-history-history-ui/1795 "2021-06-26T06:59:18Z")\
**Posts on this page:** 1\
**Showing post:** 6

<div class="post-metadata">

**Author:** ![Screwtapello](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/screwtapello/32/12_2.png) [@Screwtapello](https://discuss.kakoune.com/u/Screwtapello)\
**Post date:** [June 27, 2021, 11:34pm UTC](https://discuss.kakoune.com/t/kakhist-persist-command-history-history-ui/1795/6 "2021-06-27T23:34:36Z")

</div>

> [@almr](#):
>
> haven’t been able to find conclusive limitations for environment var size

When the kernel creates a new process, it reserves space in the memory map for the “aux area”, which contains information like the effective user and group IDs (see `getauxval(3)` as well as the command line and environment. The size of this area is platform-dependent, but if you have GNU xargs installed it will tell you:

```auto
$ echo | xargs --show-limits
Your environment variables take up 2228 bytes
POSIX upper limit on argument length (this system): 2092876
POSIX smallest allowable upper limit on argument length (all systems): 4096
Maximum length of command we could actually use: 2090648

```

On my Linux system, the maximum space available to command-line arguments and environment variables is 2,092,876 bytes, but on some systems could be as little as 4,096 bytes.

In particular, I believe macOS has a notably smaller aux area than Linux.

---

_[View the full topic](https://discuss.kakoune.com/t/kakhist-persist-command-history-history-ui/1795)._
