Skip to main content

Analyze the history of a shell

Project description

Usage

# Get the history file
$ history > history.txt

# Install
$ pip install shell_history_analysis

# You have to know which shell you have
# This is important, because the `history` command has different outputs in
# different shells.
# Fish shell has only the command itself as an output.
$ python analyze.py history.txt --shell bash

History of Commands

Grouping and Anonymization

You can provide a grouping.yaml file to group commands together. The default is the following:

'CLI Programs':
  - aspell
  - ffmpeg
  - ffprobe
  - dot
  - neato
  - fdp
  - circo
  - convert
  - md5sum
  - curl
  - wget
  - jq
  - netstat
'CLI Utils':
  - mv
  - cd
  - ..
  - ...
  - ls
  - rm
  - grep
  - cat
  - cp
  - mkdir
  - head
  - tail
  - chmod
  - chown
  - watch
  - open
  - xdg-open
  - file
  - history
  - tree
  - touch
  - find
  - locate
  - ping
  - man
  - ln
  - wc
  - df
  - du
  - pwd
  - ll
Databases:
  - mysql
  - psql
Dev-Tools:
  - make
  - meld
  - diff
  - cookiecutter
  - cloc
Docker:
  - docker
  - docker-compose
Editor(s):
  - sublime
  - subl
  - vim
  - vi
  - spyder
  - spyder3
  - nano
Java:
  - mvn
  - java
  - javac
JS:
  - npm
  - node
  - ntl
  - yarn
  - nvm
  - lerna
Cloud:
  - az
  - aws
LaTeX:
  - pdflatex
  - tlmgr
Python:
  - python
  - python2
  - python3
  - pip
  - pip2
  - pip3
  - virtualenv
  - venv
  - black
  - isort
  - pylint
  - mypy
  - pytest
  - flask
  - pyenv
  - coverage
  - tox
  - flake8
  - twine
  - pydocstyle
  - pip-compile
  - pylama
  - pybabel
  - pep8
  - piprot
  - jupyter
  - alembic
Remote:
  - scp
  - ssh
  - ssh-keygen
Rust:
  - cargo
'Shell Scripting':
  - for
  - date
'System Management':
  - kill
  - killall
  - echo
  - export
  - env
  - ps
  - top
  - htop
  - atop
  - systemctl
  - sysctl
  - ip
  - ifconfig
  - which
  - sysbench
  - service
  - dmesg
'System Package Manager':
  - apt
  - apt-get
  - apt-cache
  - update-alternatives
  - dpkg
  - add-apt-repository
  - brew
  - mas
'Web Development':
  - ab
  - http
  - ng
git:
  - git
  - git-fame

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for shell-history-analysis, version 0.1.1
Filename, size File type Python version Upload date Hashes
Filename, size shell_history_analysis-0.1.1-py3-none-any.whl (7.3 kB) File type Wheel Python version py3 Upload date Hashes View hashes
Filename, size shell_history_analysis-0.1.1.tar.gz (5.3 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page