Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
oh-my-zsh
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
github
oh-my-zsh
Commits
643bb25a
Commit
643bb25a
authored
Dec 13, 2014
by
Marc Cornellà
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Organize history.zsh file and improve comments
parent
94baa9ea
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
13 deletions
+14
-13
history.zsh
lib/history.zsh
+14
-13
No files found.
lib/history.zsh
View file @
643bb25a
## Command history configuration
[
-z
"
$HISTFILE
"
]
&&
HISTFILE
=
"
$HOME
/.zsh_history"
HISTSIZE
=
10000
SAVEHIST
=
10000
## History wrapper
function
omz_history
{
# Delete the history file if `-c' argument provided.
...
...
@@ -23,11 +18,17 @@ case $HIST_STAMPS in
*
)
alias history
=
'omz_history'
;;
esac
setopt append_history
setopt extended_history
setopt hist_expire_dups_first
setopt hist_ignore_dups
# ignore duplication command history list
setopt hist_ignore_space
setopt hist_verify
setopt inc_append_history
setopt share_history
# share command history data
## History file configuration
[
-z
"
$HISTFILE
"
]
&&
HISTFILE
=
"
$HOME
/.zsh_history"
HISTSIZE
=
10000
SAVEHIST
=
10000
## History command configuration
setopt append_history
# append history to HISTFILE on session exit
setopt extended_history
# record timestamp of command in HISTFILE
setopt hist_expire_dups_first
# delete duplicates first when HISTFILE size exceeds HISTSIZE
setopt hist_ignore_dups
# ignore duplicated commands history list
setopt hist_ignore_space
# ignore commands that start with space
setopt hist_verify
# show command with history expansion to user before running it
setopt inc_append_history
# add commands to HISTFILE in order of execution
setopt share_history
# share command history data
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment