Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .claude/skills/docs/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: docs
description: Use for auditing template_python for doc/AI-config drift after changes and fixing anything stale — READMEs, .github/instructions/, AGENTS.md, CLAUDE.md, and the synced command dirs. Equivalent to /docs.
description: Use for auditing template_ai_python for doc/AI-config drift after changes and fixing anything stale — READMEs, .github/instructions/, AGENTS.md, CLAUDE.md, and the synced command dirs. Equivalent to /docs.
---

# Docs Drift Audit Workflow
Expand Down
2 changes: 1 addition & 1 deletion .claude/skills/fix/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: fix
description: Use for template_python auto-fix requests — run ruff check --fix and ruff format. Equivalent to /fix.
description: Use for template_ai_python auto-fix requests — run ruff check --fix and ruff format. Equivalent to /fix.
---

# Fix Workflow
Expand Down
2 changes: 1 addition & 1 deletion .claude/skills/setup/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: setup
description: Use for initial template_python project setup — creates the uv virtual environment and installs dependencies. Equivalent to /setup.
description: Use for initial template_ai_python project setup — creates the uv virtual environment and installs dependencies. Equivalent to /setup.
---

# Setup Workflow
Expand Down
2 changes: 1 addition & 1 deletion .claude/skills/test/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: test
description: Use for running all template_python tests and linters — ruff, pylint, yamllint, actionlint, check_agents. Equivalent to /test.
description: Use for running all template_ai_python tests and linters — ruff, pylint, yamllint, actionlint, check_agents. Equivalent to /test.
---

# Test Workflow
Expand Down
2 changes: 1 addition & 1 deletion .claude/skills/update/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: update
description: Use for checking template_python dependency, Python, and workflow-action versions against latest releases and updating version locks — read-only, never installs or upgrades. Equivalent to /update.
description: Use for checking template_ai_python dependency, Python, and workflow-action versions against latest releases and updating version locks — read-only, never installs or upgrades. Equivalent to /update.
---

# Update Workflow
Expand Down
2 changes: 1 addition & 1 deletion .claude/skills/upgrade/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: upgrade
description: Use for upgrading template_python's Python version and/or dependencies. Equivalent to /upgrade.
description: Use for upgrading template_ai_python's Python version and/or dependencies. Equivalent to /upgrade.
---

# Upgrade Workflow
Expand Down
15 changes: 8 additions & 7 deletions .github/instructions/repos.instructions.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,16 @@ Rules for the `repos` key in `properties.yml` — the map of GitHub repos relate
## Purpose
`properties.yml`'s `repos` key records which other GitHub repos are part of this repo's family
(grouped by org), plus a `lineage` sub-key recording parent → child template-stamping
relationships — e.g. `LevonBecker/template_ai_vault: LevonBecker/template_python` means
`template_ai_vault` was stamped from `template_python`.
relationships — e.g. `LevonBecker/template_ai_python: LevonBecker/template_python` means
`template_ai_python` was stamped from `template_python`.

It's built additively, tier by tier, from `modules/setup/templates/properties/*.yml` — one fragment
file per repo in the lineage, each named after itself. This repo (`template_python`) is the root:
its own fragment, `template_python.yml`, holds just its own `repos` entry (no lineage edge, since it
has no parent). Each fragment contributes only its own org/repo + the lineage edge to its parent; a
repo only ever ends up knowing its own ancestor chain, never a sibling branch it isn't descended
from. See `modules/setup/README.md` for the build mechanism.
file per repo in the lineage, each named after itself. This repo (`template_ai_python`) forked from
`template_python`, the root: its own fragment, `template_ai_python.yml`, holds its own `repos` entry
plus the lineage edge to `template_python`; the inherited `template_python.yml` fragment (no lineage
edge, since it has no parent) sits alongside it. Each fragment contributes only its own org/repo +
the lineage edge to its parent; a repo only ever ends up knowing its own ancestor chain, never a
sibling branch it isn't descended from. See `modules/setup/README.md` for the build mechanism.

## "Related Repos" Trigger
When the user says **"related repos"**, **"the repos"**, **"other repos"**, **"all of the repos"**,
Expand Down
11 changes: 6 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
# Template Python
[![Tests](https://github.com/LevonBecker/template_python/actions/workflows/tests.yml/badge.svg)](https://github.com/LevonBecker/template_python/actions/workflows/tests.yml)
# Template AI Python
[![Tests](https://github.com/LevonBecker/template_ai_python/actions/workflows/tests.yml/badge.svg)](https://github.com/LevonBecker/template_ai_python/actions/workflows/tests.yml)

Skeleton setup for a repository that uses Python invoke tasks, reusable modules, uv for
environment/dependency management, and AI Copilot prompts and instructions. Drop this into any
project to get a consistent git workflow and linting out of the box.
environment/dependency management, and AI Copilot prompts and instructions. Forks
[`template_python`](https://github.com/LevonBecker/template_python) and adds the AI-agent layer on
top. Drop this into any project to get a consistent git workflow and linting out of the box.

## Setup
```bash
Expand Down Expand Up @@ -132,7 +133,7 @@ See [modules/README.md](modules/README.md) for full details.
## Addons
Optional, project-specific extensions live under `addons/<name>/` and mirror the root layout
(`modules/`, `tasks/`, `.github/`, `.claude/`). They are **not** usable from inside
`template_python` — they only work once their files are copied into the consuming repo's
`template_ai_python` — they only work once their files are copied into the consuming repo's
actual root, merged with what's already there, because they:
- Import via root-relative paths (e.g. `from modules.dawn import list`)
- Have `applyTo` instruction globs written for a root-level path (e.g. `modules/dawn/**`)
Expand Down
2 changes: 1 addition & 1 deletion modules/common/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Common Utilities Module

Shared utilities and helper functions used across all modules in the template_python repository.
Shared utilities and helper functions used across all modules in the template_ai_python repository.

## Overview

Expand Down
12 changes: 7 additions & 5 deletions modules/setup/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,12 @@ the repo, renaming it, or pointing it at a new fork), delete or rename `properti
run again.

On first run, assembles it from every tier fragment under `modules/setup/templates/properties/*.yml`
— one file per repo in the lineage, each named after itself. This repo (template_python) is the
root: its own fragment, `template_python.yml`, holds just `repo`, `template`, and its own `repos`
entry (no lineage edge, since it has no parent). Descendant repos add their own same-named fragment
on top when they fork from this template or a domain template descended from it.
— one file per repo in the lineage, each named after itself. This repo (template_ai_python) forked
from `template_python`, the root: its own fragment, `template_ai_python.yml`, holds its own `repos`
entry plus the lineage edge to `template_python`; the inherited `template_python.yml` fragment
(`repo`, `template`, and its own `repos` entry, no lineage edge since it has no parent) sits
alongside it. Descendant repos add their own same-named fragment on top when they fork from this
template or a domain template descended from it.

`repos` (the GitHub org/repo map + template lineage) is built additively rather than concatenated:
each fragment's own `repos:` block contributes just its own org/repo + the lineage edge to its
Expand All @@ -25,7 +27,7 @@ knowing its own ancestor chain, never a sibling branch it isn't descended from.

Detects this repo's actual path on disk and its git `origin` remote (if any), and stamps
`repo.local`, `repo.remote`, and `screenshots.location` (if a `screenshots` section is present —
generic to that section, not something this root repo declares) with those values. Auto-detects
generic to that section, not something this repo declares) with those values. Auto-detects
`template.*` (the parent template repo for `/template`) via GitHub's generated-from link, falling
back to an interactive prompt.

Expand Down
13 changes: 7 additions & 6 deletions modules/setup/properties.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,13 @@

properties.yml is gitignored. It's assembled from every tier fragment under
`modules/setup/templates/properties/*.yml` — one file per repo in the lineage, each named after
itself. This repo (template_python) is the root: its own fragment, `template_python.yml`, holds
just `repo`, `template`, and its own `repos` entry (no lineage edge, since it has no parent).
Descendant repos add their own same-named fragment on top when they fork from this template or a
domain template descended from it — see `.github/instructions/repos.instructions.md`. `repo.local`,
`repo.remote`, and `screenshots.location` (if present) are then stamped in with values detected at
creation time.
itself. This repo (template_ai_python) forked from template_python, the root: its own fragment,
`template_ai_python.yml`, holds its own `repos` entry plus the lineage edge to `template_python`;
the inherited `template_python.yml` fragment (`repo`, `template`, its own `repos` entry, no lineage
edge since it has no parent) sits alongside it. Descendant repos add their own same-named fragment
on top when they fork from this template or a domain template descended from it — see
`.github/instructions/repos.instructions.md`. `repo.local`, `repo.remote`, and
`screenshots.location` (if present) are then stamped in with values detected at creation time.

template.* (this repo's parent template repo, used by /template) is
auto-detected from GitHub's generated-from link when possible, with an
Expand Down
14 changes: 14 additions & 0 deletions modules/setup/templates/properties/template_ai_python.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
repos:
LevonBecker:
- template_ai_python
lineage:
LevonBecker/template_ai_python: LevonBecker/template_python

repo:
local: "$HOME/path/to/this/repo"
remote: "github.com/<your-username>/<your-repo-name>"

template:
local: "$HOME/path/to/your/template/repo"
remote: "github.com/<your-username>/<your-template-repo>"
1 change: 1 addition & 0 deletions modules/setup/templates/properties/template_python.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
repos:
LevonBecker:
- template_python
Expand Down
4 changes: 2 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ dependencies = [
packages = []

[project.urls]
homepage = "https://github.com/LevonBecker/template_python"
repository = "https://github.com/LevonBecker/template_python"
homepage = "https://github.com/LevonBecker/template_ai_python"
repository = "https://github.com/LevonBecker/template_ai_python"

[tool.ruff]
line-length = 120
Expand Down
Loading