python-substack GEMINI.md

Maintainer instructions for a Python library and command-line tool that creates and manages Substack drafts from Markdown. Substack is a publishing platform, and Markdown is a plain-text way to format writing.

In plain words
What is it for?
Use them when developing, testing, fixing bugs, changing behavior, updating documentation, or preparing releases for python-substack.
Why use it?
They reduce the risk of breaking public interfaces, tests, releases, credentials, or compatibility while changing the project.

Instructions file for Gemini CLI

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add instructions/ma2za/python-substack/gemini-md
Clone the repo
git clone --depth 1 https://github.com/ma2za/python-substack

Made for: Gemini CLI.

Per session 642 This file is loaded in full into every session.
When invoked 642 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00642 $0.00642
Opus 5 $0.00321 $0.00321
Sonnet 5 $0.00128 $0.00128
Haiku 4.5 $0.00064 $0.00064

Measured yesterday against content hash 6d8fe192e37f, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

python-substack GEMINI.md scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

GEMINI.md · 57 lines

How it starts

The opening of the file, as written. The whole thing — 57 lines — stays where its author put it; the contents beside it link to each section on GitHub.

python-substack maintainer instructions

Project

This repository is a Python 3.10+ library, CLI, and optional MCP server for creating and managing Substack drafts from Markdown. Poetry owns dependencies, packaging, scripts, and the lock file. The public package is python-substack.

Read the relevant implementation, tests, and documentation before editing. Keep changes focused and preserve existing public interfaces, defaults, JSON keys, environment variables, console scripts, and MCP tool signatures through the 1.x series as required by docs/compatibility.md.

Development

  • Use the existing style and the simplest working implementation.
  • Add a regression test for every bug fix and offline tests for new behavior.
  • Update user-facing documentation and CHANGELOG.md for behavior changes.
  • Do not edit poetry.lock unless dependency declarations change.
  • Never expose or commit .env contents, passwords, cookies, credentials, tokens, captured request headers, or local service-account files.
  • Preserve user changes in a dirty worktree. Do not reset, restore, or delete unrelated work.
  • Testing Standards: Never fake coverage. Tests must exercise actual logic. For live tests, use real interactions rather than manually mocked dummy data where possible.
  • Adversarial Testing: Include extremely hard, adversarial edge cases (e.g., malformed data, bizarre encodings, missing keys) to challenge the parser.
  • Environment Notes: Use python -m <module> instead of direct .exe bin shims (like pytest.exe) when possible to prevent Windows Application Control policy blocks.

Install and validate with:

poetry install --all-extras
poetry run pytest -q -m "not live" --strict-markers
poetry run pre-commit run --all-files

Live tests call Substack and create disposable drafts. Run them only after the maintainer explicitly authorizes the live operation and confirms suitable test credentials. Live tests must never publish, and their drafts must be removed.

Read the full file on GitHub · 57 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 57 lines · 642 tokens per session scan A 6d8fe192e37f

Subscribe to this mod's changes

python-substack GEMINI.md is an instructions file published in the GitHub repository ma2za/python-substack (166 stars, last pushed 6d ago), licensed MIT. It adds 642 tokens to every session, about $0.0032 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other instructions, from other repositories

substack-mcp CLAUDE.md

Instructions for marcomoauro/substack-mcp, covering claude.md, language, commands, distribution and releases and layout.

marcomoauro/substack-mcp · 12,303 tokens

substack-mcp AGENTS.md

AGENTS.md instructions for damienbenveniste/substack-mcp, covering agent instructions, project orientation, working style, delegation and external context and typescript tooling.

damienbenveniste/substack-mcp · 1,203 tokens

substack-mcp AGENTS.md

AGENTS.md instructions for sandraschi/substack-mcp, covering substack mcp — agents.md, quick reference, key modules and development commands.

sandraschi/substack-mcp · 399 tokens

substack-mcp CLAUDE.md

Claude Code instructions for sandraschi/substack-mcp, covering claude.md — substack-mcp development directives, port allocation, commands, backend dev server and frontend webapp dev server.

sandraschi/substack-mcp · 338 tokens

deepagents AGENTS.md

Instructions for langchain-ai/deepagents, covering global development guidelines for the deep agents monorepo, corridor security analysis, development workflow, suppressing ruff rules and pr conventions.

langchain-ai/deepagents · 2,268 tokens

autoharness AGENTS.md

Instructions for tigerless-labs/autoharness: This repo uses Open Knowledge — collaborative markdown via MCP. .open-knowledge/config.yml (with optional /.open-knowledge/config.yml; CLI/env may override) is the path contract: content.dir is the root for relative paths; content.include lists globs that add markdown…

tigerless-labs/autoharness · 2,201 tokens