Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

What is the maximum history size? #510

Closed
itpropaul opened this issue Feb 16, 2022 · 3 comments
Closed

What is the maximum history size? #510

itpropaul opened this issue Feb 16, 2022 · 3 comments
Assignees

Comments

@itpropaul
Copy link

In addition to sharing the default, please also state the maximum history size.

https://docs.microsoft.com/en-us/windows/terminal/customize-settings/profile-advanced#history-size

@mattwojo
Copy link
Collaborator

mattwojo commented Mar 8, 2022

@zadjii-msft -- Do you know the answer here?

@zadjii-msft
Copy link
Contributor

Sorry, I CANNOT find the email rule that's filtering out mails from the docs repo 😫 hopefully I just added another to snipe them from whatever rule I already had set.


As far as the max goes - the max size of the entire buffer is SHRT_MAX. That includes the scrollback AND the current viewport size. It's a bit of a complicated answer, that depends on how big the Terminal currently is.

If you set historySize to any value where (historySize + viewport height) would be greater than SHRT_MAX, we'll just clamp the buffer length to SHRT_MAX. I suppose that's a sensible enough max value to list?

@nguyen-dows
Copy link
Collaborator

Hi @itpropaul, I just added the maximum history size to the docs! Our maximum history size is 32767 (which is similar to the value of SHRT_MAX)
With that, I'll be closing this issue :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants