mergething
App over syncthing that takes care merging things
Install using pip install mergething
ipython/jupyter
Currently supports merging ipython/jupyter history files.
mergething will give each ipython/jupyter session it's own history file, so in contrast to vanilla ipython, you can run multiple ipython sessions at the same time without worrying about corruption. You can even use mergething on a single machine in order to get this benefit.
When a session is closed, its history file is marked "completed", and once it is incorporated into a new session, it will be deleted (only ever by the same device).
IPython/jupyter History Sync
1. Configure Syncthing
Set up Syncthing to sync a directory across your machines (e.g., ~/syncthing/ipython_history).
2a. Configure IPython using CLI tool
The following line will copy your exisiting history file to the directory and add lines to you ipython_config.py file to use mergething:
mergething init ~/syncthing/ipython_history
2b. Configure IPython manually
Alternatively, you can add these lines to the end of your IPython configuration file manually (~/.ipython/profile_default/ipython_config.py):
try:
from mergething.ipython import sync_and_get_hist_file
c.HistoryManager.hist_file = sync_and_get_hist_file("~/syncthing/ipython_history", verbose=False)
except Exception:
print("mergething: Error syncing and getting history file, using default ipython behavior")
You can also pass the hostname you want files to use, this is useful when multiple devices have the same hostname:
c.HistoryManager.hist_file = sync_and_get_hist_file("~/syncthing/ipython_history", verbose=False, hostname="mydevice")
For Android/Termux users where the hostname is always "localhost", you can specify a custom hostname:
try:
from mergething.ipython import sync_and_get_hist_file
c.HistoryManager.hist_file = sync_and_get_hist_file("~/syncthing/ipython_history", verbose=False, hostname="my_phone")
except Exception:
print("mergething: Error syncing and getting history file, using default ipython behavior")
Merging existing files
You can use the CLI tool to merge existing files:
mergething merge history1.sqlite history2.sqlite ... historyn.sqlite merged_history.sqlite
Metadata
Release files for mergething 0.1.4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| mergething-0.1.4.tar.gz | 8.4 kB | Without provenance | Details for mergething-0.1.4.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| mergething-0.1.4-py3-none-any.whl | Python 3 | none | any | Details for mergething-0.1.4-py3-none-any.whl |
Total release size: 18.3 kB
Release files / mergething-0.1.4.tar.gz
| Download URL | mergething-0.1.4.tar.gz |
|---|---|
| Size | 8.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
55f41d8662d0b637d72fb811a30dee32baab9cd00bcb08163e9889150a376a82
|
|
BLAKE2b-256 checksum How to use checksums |
eab4754ae2c54a8ba16df096d94b22049b1f5cccf006eca2e163b16c0a379910
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.12
|
Release files / mergething-0.1.4-py3-none-any.whl
| Download URL | mergething-0.1.4-py3-none-any.whl |
|---|---|
| Size | 9.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
823fda715201ea3252c74e1d753424adf4b6fa1b6816a96bb54c193df98147dc
|
|
BLAKE2b-256 checksum How to use checksums |
aca54b4b20027a1d3566d38b4c79c694c2206cc20899c805e4b53f7af523b946
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.12
|
Security for mergething 0.1.4
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.