Skip to main content

Strip personal annotations from code before committing

Project description

GhostNotes

Version: 1.0.2 | Last Updated: April 23, 2026

A Git tool that strips tagged comments before committing.


Installation

pip install ghostnotes

Then initialize in any git repo:

cd your-project
ghostnotes init

What it does

GhostNotes lets you leave personal notes in your code using a tag (default: GN:). Before every commit, it automatically strips them out so they never reach your repository.

x = some_function() # GN: this is how you assign the output from a function in Python (embarrassing to not know)

This comment line gets stripped before the commit so it looks like:

x = some_function()

Your local file stays untouched.


Commands

Command Description
ghostnotes init Initialize GhostNotes in the current project
ghostnotes status Show all GhostNotes in the current project
ghostnotes set-tag --tag <tag> Change the default comment tag
ghostnotes add-lang --ext <.ext> --symb <symbol> Add support for a new language
ghostnotes pull Git pull that safely strips and re-applies your ghostnotes

Configuration

Edit .ghostnotes to tune how notes are detected. Under [settings], space_mode controls the spacing between the comment symbol and the tag:

Mode Matches
space (default) # GN: only
nospace #GN: only
both # GN: and #GN:

Supported Languages

Language Extension Comment Symbol
Python .py #
Java .java //
JavaScript .js //
TypeScript .ts //
C .c //
C++ .cpp //
C# .cs //
Go .go //
Rust .rs //
Swift .swift //
Kotlin .kt //
Ruby .rb #
Shell .sh #
YAML .yaml / .yml #
R .r #
PHP .php //
Lua .lua --
SQL .sql --
Scala .scala //
Dart .dart //
Zig .zig //
Perl .pl #
Elixir .ex #
Haskell .hs --

Need a language not listed? Add it with ghostnotes add-lang --ext <.ext> --symb <symbol>.

Project details


Download files

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

Source Distribution

ghostnotes-1.0.2.tar.gz (9.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ghostnotes-1.0.2-py3-none-any.whl (8.5 kB view details)

Uploaded Python 3

File details

Details for the file ghostnotes-1.0.2.tar.gz.

File metadata

  • Download URL: ghostnotes-1.0.2.tar.gz
  • Upload date:
  • Size: 9.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for ghostnotes-1.0.2.tar.gz
Algorithm Hash digest
SHA256 ff5a996431bcb72d8fe6d5f644f96b19a7814a5ab9fe4b75dcca005b7614ef52
MD5 aa43d3b414d155720d0c20d5c7c87e81
BLAKE2b-256 049a007851153265ccf322fc749a7c6a4626d257269dbaffd09c9cfd7628e16e

See more details on using hashes here.

File details

Details for the file ghostnotes-1.0.2-py3-none-any.whl.

File metadata

  • Download URL: ghostnotes-1.0.2-py3-none-any.whl
  • Upload date:
  • Size: 8.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for ghostnotes-1.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 1e7de67db3977afc94c59325c6117bd2bad242170e6dbd305fbf3657be70dcb0
MD5 7efeb3d5ec2502b114d9b1e51a74cffa
BLAKE2b-256 9c61ba59c6ea5d188724035b0c678ea1b41f673f5a1997c5c3add9e75775ad72

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page