homepage: http://github.com/j1r1k/merge-bash-history#readme
changelog-type: ''
hash: 6854070723b8270a365703d48966c40c8156db7106cefa9359edb0aa55eb8041
test-bench-deps:
  merge-bash-history: -any
  base: -any
maintainer: jiri.marsicek@gmail.com
synopsis: Initial project template from stack
changelog: ''
basic-deps:
  merge-bash-history: -any
  base: ! '>=4.7 && <5'
  text: ! '>=1.2'
  attoparsec: ! '>=0.12'
  optparse-applicative: ! '>=0.11'
  errors: ! '>=2'
  data-ordlist: ! '>=0.4'
all-versions:
- '0.1.0.0'
author: Jiri Marsicek
latest: '0.1.0.0'
description-type: markdown
description: ! '# merge-bash-history


  Utility to be used with unison (http://www.cis.upenn.edu/~bcpierce/unison/) to merge
  `.bash_history` file accross multiple machines.


  # Installation


  Clone the repository


  ```

  git clone https://github.com/j1r1k/merge-bash-history.git

  ```


  Install using stack

  ```

  cd merge-bash-history

  stack install

  ```


  # Example configuration in unison preferences file


  Assuming you have root set to your home directory and `merge-bash-history` is in
  your $PATH


  Add following to your unsion .prf file


  ```

  merge = Name .bash_history -> merge-bash-history CURRENT1 CURRENT2 > NEW

  backupcurrent = Name .bash_history

  ```


  # Manual usage


  ```

  merge-bash-history [INPUT-FILE1] [INPUT-FILE2] > [MERGED-FILE]

  ```


  # Limitations

  - Does not support line deletion (e.g. manual removal of lines from .bash_history
  file)


  # Warnings

  - Sorts .bash_history file by timestamp if not sorted

  - removes duplicates (comparing timestamp and command)


  # Recommended Bash settings


  ```

  shopt -s histappend

  PROMPT_COMMAND="${PROMPT_COMMAND};history -a"

  ```


  From Pawel Hajdan (http://phajdan-jr.blogspot.de/2015/03/more-reliable-handling-of-bash-history.html)

'
license-name: BSD3

Update from Hackage at 2016-06-25T13:22:46+0000
Update from Hackage at 2016-06-25T13:22:46+0000
