2018-08-12 02:14:46 +08:00
# HSTR
2018-04-27 15:30:08 +08:00
[![Current release ](https://img.shields.io/github/release/dvorka/hstr.svg )](https://github.com/dvorka/hstr/releases)
[![GitHub issues ](https://img.shields.io/github/issues/dvorka/hstr.svg?maxAge=360 )](https://github.com/dvorka/hstr/issues)
[![All releases downloads ](https://img.shields.io/github/downloads/dvorka/hstr/total.svg )](https://github.com/dvorka/hstr/releases)
2019-12-08 05:44:28 +08:00
[![License ](https://img.shields.io/github/license/dvorka/hstr?color=%23fe0000 )](https://github.com/dvorka/hstr/blob/master/LICENSE)
2018-04-27 15:30:08 +08:00
2019-12-17 05:29:54 +08:00
Easily view, navigate and search your **command history** with shell history suggest box for
[bash ](https://www.gnu.org/software/bash/ ) and [zsh ](CONFIGURATION.md#zsh-history-settings ).
2013-12-03 06:47:51 +08:00
2018-08-27 23:23:10 +08:00
[![Shell History Suggest Box ](doc/hstr-v2.gif "Shell History Suggest Box @ YouTube" )](http://www.youtube.com/watch?v=sPF29NyXe2U)
2013-12-03 06:55:33 +08:00
2018-08-12 02:14:46 +08:00
## Description
2014-12-20 17:43:36 +08:00
Are you looking for a command that you used **recently** ? Do you
want to avoid the need to write **long commands** over and over
2018-10-04 13:28:31 +08:00
again? Are you looking for a tool that is able to manage your
2018-03-18 01:03:16 +08:00
**favorite** commands?
2014-04-20 14:00:16 +08:00
2019-12-17 05:41:55 +08:00
HSTR (**H**i**ST**o**R**y) is a command line utility that brings improved `bash` /`zsh` command completion
2014-12-20 17:43:36 +08:00
from the history. It aims to make completion **easier** and more **efficient**
2019-12-17 05:34:15 +08:00
than < kbd > Ctrl-r< / kbd > .
2013-12-03 06:55:33 +08:00
2018-03-18 01:03:16 +08:00
HSTR can also **manage** your command history (for instance you can remove
2018-10-04 13:28:31 +08:00
commands that are obsolete or contain a piece of sensitive information)
2018-08-25 15:40:01 +08:00
or **bookmark** your favorite commands.
2014-04-13 16:02:25 +08:00
2018-08-28 13:42:55 +08:00
<!-- Check [video ](http://www.youtube.com/watch?v=sPF29NyXe2U ) tutorial. -->
2013-12-16 15:15:11 +08:00
2014-01-10 08:21:21 +08:00
2018-08-12 02:14:46 +08:00
## Installation
Install:
2018-08-11 14:37:17 +08:00
2015-02-18 13:38:27 +08:00
* [Ubuntu ](INSTALLATION.md#ubuntu )
2021-12-12 15:21:40 +08:00
* [Debian ](INSTALLATION.md#debianmint )
* [Mint ](INSTALLATION.md#debianmint )
2018-09-06 22:26:05 +08:00
* [Fedora ](INSTALLATION.md#fedorarhelcentosscientific )
* [CentOS ](INSTALLATION.md#fedorarhelcentosscientific )
* [RHEL ](INSTALLATION.md#fedorarhelcentosscientific )
* [Scientific Linux ](INSTALLATION.md#fedorarhelcentosscientific )
2021-12-12 15:21:40 +08:00
* [openSUSE ](INSTALLATION.md#opensuse )
* [Gentoo ](INSTALLATION.md#gentoo )
* [Alpine Linux ](INSTALLATION.md#alpine-linux )
* [Arch ](INSTALLATION.md#archmanjaro-linux )
* [Manjaro Linux ](INSTALLATION.md#archmanjaro-linux )
* [FreeBSD ](INSTALLATION.md#freebsd )
* [Slackware Linux ](INSTALLATION.md#slackware )
* [Void Linux ](INSTALLATION.md#void-linux )
* [Milis Linux ](INSTALLATION.md#milis-linux )
2018-08-30 21:12:53 +08:00
* [Haiku OS ](INSTALLATION.md#haiku-os )
2018-08-11 14:48:25 +08:00
* [macOS ](INSTALLATION.md#macos )
2018-10-04 13:28:31 +08:00
* [nix package manager ](INSTALLATION.md#nix-package-manager )
2022-01-09 19:06:32 +08:00
* [Guix package manager ](INSTALLATION.md#guix-package-manager )
2022-01-09 19:02:19 +08:00
* [MPR ](INSTALLATION.md#MPR )
2014-01-17 11:46:12 +08:00
2018-08-12 02:14:46 +08:00
Build:
2014-01-17 11:46:12 +08:00
2018-08-12 02:14:46 +08:00
* [build on any Linux distro ](INSTALLATION.md#build-on-any-linux-distro )
2018-08-13 06:09:10 +08:00
* [build snap ](INSTALLATION.md#snap )
2018-08-12 02:14:46 +08:00
* [build on Ubuntu ](INSTALLATION.md#build-on-ubuntu )
* [build on Debian ](INSTALLATION.md#build-on-debian )
* [build on Fedora ](INSTALLATION.md#build-on-fedora )
2018-08-12 05:36:07 +08:00
* [build on Windows Subsystem for Linux (WSL) ](INSTALLATION.md#build-on-wsl )
2018-08-12 02:14:46 +08:00
* [build on Cygwin ](INSTALLATION.md#build-on-cygwin )
2018-08-25 15:40:01 +08:00
* [build on macOS ](INSTALLATION.md#build-on-macos )
2018-08-12 02:14:46 +08:00
Tarball:
* [build and install tarball ](INSTALLATION.md#build-and-install-tarball )
2021-12-04 01:45:59 +08:00
Check also [packages ](https://pkgs.org/search/?q=hstr ) for Linux and Unix.
2019-01-06 02:22:55 +08:00
2018-08-12 02:14:46 +08:00
## Configuration
2018-08-14 12:41:34 +08:00
Configure HSTR just by running:
2018-08-25 15:40:01 +08:00
2014-01-27 02:30:09 +08:00
```bash
2019-12-08 05:44:28 +08:00
# bash
2018-08-25 15:40:01 +08:00
hstr --show-configuration >> ~/.bashrc
2019-12-08 05:44:28 +08:00
# zsh
hstr --show-configuration >> ~/.zshrc
2014-01-27 01:27:28 +08:00
```
2018-08-25 15:40:01 +08:00
For detailed HSTR configuration documentation please refer to [Configuration ](CONFIGURATION.md ).
2014-01-13 14:23:02 +08:00
2021-12-12 15:40:45 +08:00
## In the News
Read about HSTR in [LinuxMagazine ](http://www.linux-magazine.com/Issues/2014/164/Bash-History-on-Steroids ), [UbuntuGeek ](http://www.ubuntugeek.com/tag/hstr-bash-history ), [DebianAdmin ](http://www.debianadmin.com/hstr-easily-view-navigate-search-and-use-your-command-history-with-shell-history.html ), [Tuxdiary ](http://tuxdiary.com/2015/02/17/hstr/ ), [Softpedia ](http://linux.softpedia.com/get/Terminals/BASH-Command-History-Completion-103155.shtml ) and [OSTechNix ](https://www.ostechnix.com/hstr-easily-view-navigate-search-manage-commandline-history/ ).
2018-08-12 02:14:46 +08:00
## Documentation
2018-08-25 15:40:01 +08:00
Check man page:
2018-08-12 02:14:46 +08:00
2014-02-01 02:46:18 +08:00
```bash
2018-08-25 15:40:01 +08:00
man hstr
2014-01-27 01:27:28 +08:00
```
2014-01-27 01:14:47 +08:00
2021-06-27 15:08:25 +08:00
User videos: [Zack ](https://www.youtube.com/watch?v=Qd75pIeQkH8 ), [Dvorka ](https://www.youtube.com/watch?v=sPF29NyXe2U ) and [Yu-Jie Lin ](https://www.youtube.com/watch?v=Qx5n_5B5xUw ).
2018-08-12 02:14:46 +08:00
## Bugs
2013-12-03 15:54:19 +08:00
https://github.com/dvorka/hstr/issues