Skip to main content

nmp-notes 📝

PyPI version Python versions License: MIT

nmp-notes (imported as nmp) is a lightweight Python library and CLI tool that drops a college practical's full code into your current folder.


📦 Installation

pip install nmp-notes

Or from source:

git clone https://github.com/Sus69/nmp-notes.git
cd nmp-notes
pip install -e .

🚀 CLI Usage

1. Interactive menu (default)

nmp

Shows an arrow-key menu (up/down + Enter, type-to-filter, q to quit). Pick one and its .py file is created in the current folder. Falls back to a numbered prompt when piped.

2. List practicals

nmp list

3. Create directly

nmp create 1a-bfs
nmp create 3-decision-tree -o my_tree.py

Generated files land in the current folder and are never overwritten silently — you'll be asked first (create prompts; the Python API needs force=True).

Practical 1a/1b/2a/2b also copy a shared RMP.py helper next to the file (never overwritten).


🐍 Python API Usage

import nmp
from nmp.mk import TemplateNotFoundError, TargetFileExistsError

print(nmp.mk.available_templates())  # ['10-tensorflow-demo', '1a-bfs', ...]

nmp.mk.file("1a-bfs")                            # ./bfs.py (+ ./RMP.py)
nmp.mk.file("3-decision-tree", filename="t.py")  # custom name
nmp.mk.file("5-svm", output_dir="./labs")        # custom dir
nmp.mk.file("5-svm", force=True)                 # overwrite

➕ Adding New Templates

  1. Drop the file in src/nmp/templates/ (e.g. kmeans.py).
  2. Register it in src/nmp/mk.py → PRACTICALS (slug → title + filename).
  3. If it needs a shared helper, add it to EXTRA_FILES.
  4. Reinstall.

📄 License

MIT — see the LICENSE file for details.

Metadata

Release files for nmp-notes 0.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for nmp-notes 0.2.0
File Size Uploaded
nmp_notes-0.2.0.tar.gz 13.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for nmp-notes 0.2.0
File Interpreter ABI Platform
nmp_notes-0.2.0-py3-none-any.whl Python 3 none any Details

Total release size: 30.7 kB

Release files / nmp_notes-0.2.0.tar.gz

Download URL nmp_notes-0.2.0.tar.gz
Size 13.8 kB
Tags Source
SHA-256 checksum
How to use checksums
5b6e8b689da9df1e1804b50f6bbdbca63f49364e5bd1625c2c28d3c31e092acc
BLAKE2b-256 checksum
How to use checksums
f73b438458f078556d87b25190e6dfc05269afa88bf68260bb8c314a50f3094f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / nmp_notes-0.2.0-py3-none-any.whl

Download URL nmp_notes-0.2.0-py3-none-any.whl
Size 16.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b92c5fcbb6739ad000a0e15243e64cd64febab46765760b97d27d627beb22544
BLAKE2b-256 checksum
How to use checksums
7efbeb1c1eebb7a518b363137a4f989465ebcbe45f760706867f569b625465ed
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release history Release notifications | RSS feed

This release

0.2.0 This release

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page