diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..9f8414c --- /dev/null +++ b/.gitignore @@ -0,0 +1,9 @@ +# OS +.DS_Store +Thumbs.db + +# Editor +.idea/ +.vscode/ +*.swp +*.swo diff --git a/CLAUDE.md b/CLAUDE.md new file mode 100644 index 0000000..717876b --- /dev/null +++ b/CLAUDE.md @@ -0,0 +1,35 @@ +# CLAUDE.md + +This file provides context for AI agents (Claude Code) working in this repository. + +## Repository Purpose + +This is the `labrats-work/.github` special repository. It contains: +- Organization profile README (`profile/README.md`) +- Reusable workflow templates (`workflow-templates/`) +- Workflows for CI on this repository itself (`.github/workflows/`) + +## Key Files + +| File | Purpose | +|------|---------| +| `profile/README.md` | Org profile shown at github.com/labrats-work — keep it current with active projects and tech stack | +| `workflow-templates/repo-info.yml` | Example workflow template demonstrating repo info output | +| `workflow-templates/repo-info.properties.json` | Metadata for the repo-info template | +| `.github/workflows/repo-info.yml` | CI workflow for this repository (runs on push/PR to main) | + +## Conventions + +- Workflow templates must have a matching `.properties.json` file +- The `properties.json` `iconName` must reference a valid GitHub icon +- Templates use `$default-branch` as a placeholder; the live workflow pins to `main` +- Commit messages follow conventional commits: `feat:`, `fix:`, `docs:`, `chore:` + +## Agent Roles + +This repository uses the `labrats-work` multi-agent system. Agents are triggered by @mentions in issue and PR comments: +- `ai-developer` — implements changes, creates PRs +- `ai-reviewer` — reviews PRs +- `ai-docs` — documentation reviews and improvements + +See the [agent directory](https://github.com/labrats-work/.github/blob/main/profile/README.md) for the full list. diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..505fad7 --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2024 labrats-work + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..04cb0b6 --- /dev/null +++ b/README.md @@ -0,0 +1,45 @@ +# labrats-work/.github + +Organization-wide GitHub configuration repository for [labrats-work](https://github.com/labrats-work). + +## Purpose + +This repository provides default community health files and shared configurations for all repositories in the `labrats-work` organization. Files placed here are automatically used by repositories that do not have their own versions. + +Contents: +- **Organization profile** — The public-facing README shown on the organization's GitHub page +- **Workflow templates** — Reusable GitHub Actions workflow templates available to all org repositories +- **Community health files** — Default CONTRIBUTING, CODE_OF_CONDUCT, SECURITY, and SUPPORT documents (when present) + +## Structure + +``` +.github/ + workflows/ # Workflows for this repository itself +profile/ + README.md # Organization profile shown at github.com/labrats-work +workflow-templates/ + *.yml # Workflow templates available to all org repositories + *.properties.json # Metadata for each workflow template +docs/ + workflow-templates.md # Documentation for available workflow templates +``` + +## Quick Start + +### Using a Workflow Template + +1. In any `labrats-work` repository, go to **Actions** > **New workflow** +2. Select a template from the **labrats-work** section +3. Customize the template for your repository's needs + +### Adding a New Workflow Template + +1. Add a `.yml` file to `workflow-templates/` +2. Add a matching `.properties.json` with `name`, `description`, `iconName`, and `categories` +3. Open a PR — templates are available to the org once merged to `main` + +## Related Repositories + +- [actions.common](https://github.com/labrats-work/actions.common) — Reusable GitHub Actions workflows +- [apps.github-ai-agents](https://github.com/labrats-work/apps.github-ai-agents) — AI automation service powering this org's agents diff --git a/docs/workflow-templates.md b/docs/workflow-templates.md new file mode 100644 index 0000000..34cb0e4 --- /dev/null +++ b/docs/workflow-templates.md @@ -0,0 +1,36 @@ +# Workflow Templates + +This directory contains GitHub Actions workflow templates available to all repositories in the `labrats-work` organization. + +## Available Templates + +### repo-info + +**File:** `workflow-templates/repo-info.yml` + +Prints repository metadata and the full GitHub context at workflow runtime. Useful as a starting point for understanding available context variables or for debugging GitHub Actions workflows. + +**Triggers:** Push and pull requests to the default branch + +**Steps:** +1. Checkout the repository +2. Print the repository name, workspace disk usage, and full `github` context as JSON + +**Usage:** Select "Repo Info Workflow" from the Actions template picker in any org repository. + +## Adding a New Template + +Each template requires two files in `workflow-templates/`: + +1. **`.yml`** — The workflow definition. Use `$default-branch` instead of hardcoded branch names. +2. **`.properties.json`** — Metadata with the following fields: + +| Field | Description | +|-------|-------------| +| `name` | Human-readable name shown in the template picker | +| `description` | Short description of what the workflow does | +| `iconName` | GitHub Octicon name (e.g., `check-square`, `rocket`) | +| `categories` | Array of category strings for filtering | +| `filePatterns` | Optional array of file glob patterns that trigger the suggestion | + +See [GitHub docs on workflow templates](https://docs.github.com/en/actions/writing-workflows/using-workflow-templates) for full details.