2022-12-05 23:05:28 +00:00
|
|
|
---
|
2022-12-15 01:05:11 +00:00
|
|
|
title: Interface hilbish.history
|
2022-12-05 23:05:28 +00:00
|
|
|
description: command history
|
2022-12-15 01:05:11 +00:00
|
|
|
layout: doc
|
|
|
|
menu:
|
|
|
|
docs:
|
|
|
|
parent: "API"
|
2022-12-05 23:05:28 +00:00
|
|
|
---
|
|
|
|
|
|
|
|
## Introduction
|
|
|
|
The history interface deals with command history.
|
|
|
|
This includes the ability to override functions to change the main
|
|
|
|
method of saving history.
|
|
|
|
|
2022-12-05 23:20:36 +00:00
|
|
|
## Functions
|
|
|
|
### add(cmd)
|
|
|
|
Adds a command to the history.
|
|
|
|
|
|
|
|
### clear()
|
|
|
|
Deletes all commands from the history.
|
|
|
|
|
|
|
|
### get(idx)
|
|
|
|
Retrieves a command from the history based on the `idx`.
|
|
|
|
|
|
|
|
### size()
|
|
|
|
Returns the amount of commands in the history.
|
|
|
|
|