From de5ca8054342e37359854ace6f9b7487173bffe6 Mon Sep 17 00:00:00 2001 From: Vincent Batts Date: Fri, 18 May 2012 12:41:09 -0400 Subject: [PATCH] adding to the notes --- README | 6 ++++-- bash_history.rb | 4 ++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/README b/README index 5b4af98..263e38a 100644 --- a/README +++ b/README @@ -14,14 +14,16 @@ and set in ~/.bashrc: == USAGE See the --help also, - Usage: bash_history [options] +Usage: bash_history [options] --inspect inspect the data + -h, --history FILE use bash_history FILE instead of the default (~/.bash_history) + -d, --db FILE use database FILE instead of the default (~/.bash_history.db) -l, --list list history --fix fix times + --format FORMAT specify a different strftime format. (default is "%F %T") -f, --find PAT find a command with pattern PAT - == LICENSE Copyright (c) 2012 Vincent Batts, Raleigh, NC, USA diff --git a/bash_history.rb b/bash_history.rb index ab84d46..fdc1990 100755 --- a/bash_history.rb +++ b/bash_history.rb @@ -64,10 +64,10 @@ if $0 == __FILE__ opts.on('--inspect','inspect the data') do |o| options[:inspect] = o end - opts.on('--history FILE','use bash_history FILE instead of the default (~/.bash_history)') do |o| + opts.on('-h','--history FILE','use bash_history FILE instead of the default (~/.bash_history)') do |o| bh_options[:file] = o end - opts.on('--db FILE','use database FILE instead of the default (~/.bash_history.db)') do |o| + opts.on('-d','--db FILE','use database FILE instead of the default (~/.bash_history.db)') do |o| bh_options[:archive_file] = o end opts.on('-l','--list','list history') do |o|