Simple Python library to return your shell history or dump to a nicely formatted JSON file.
Project description
Shhistory
Simple Python library to return your shell history or dump to a JSON file.
You can install this library via pip:
pip install shhistory
Example
A quick example to print the JSON data to stdout:
# test.py
from shhistory import ShellHistory
print(ShellHistory.get_shell_history())
You can also create a quick bash utility with this library by piping to jq
for nicer formatting:
python3 test.py | jq
If you would like to analyze the data more securely, you can also dump to a file:
from shhistory import ShellHistory
print(ShellHistory.dump_shell_history())
NOTE: Windows is not currently supported. This may be added in a future update.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
shhistory-0.1.9.tar.gz
(2.8 kB
view hashes)
Built Distribution
Close
Hashes for shhistory-0.1.9-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 95e527fd6a8d8bae6b611ac939d72ee18420f98624b34d87c2591dc6954f42e6 |
|
MD5 | b43d24709b649a610076415a5de74c45 |
|
BLAKE2b-256 | 3970791c3cc90420a666c30763108164dddcf4bf1f5e9a7a6b2c13895f06fa32 |