Skip to content
Closed
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
23 changes: 23 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
---
name: Bug report
description: Report a problem with Primer
labels: [bug]
---

## Description

## Steps to reproduce

1.
2.
3.

## Expected behavior

## Actual behavior

## Environment

- OS:
- Node version:
- Primer version:
5 changes: 5 additions & 0 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
blank_issues_enabled: false
contact_links:
- name: Questions
url: https://github.com/pierceboggan/primer/discussions
about: Ask questions and discuss ideas here.
13 changes: 13 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
---
name: Feature request
description: Suggest an enhancement for Primer
labels: [enhancement]
---

## Summary

## Problem statement

## Proposed solution

## Additional context
10 changes: 10 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
## Summary

- [ ] What changed
- [ ] Why it changed

## Checklist

- [ ] Tests added or updated
- [ ] Lint/typecheck pass
- [ ] Docs updated if needed
34 changes: 34 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: CI

on:
push:
branches: [main]
pull_request:

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 20
cache: npm
- name: Install
run: npm ci
- name: Lint
run: npm run lint
- name: Typecheck
run: npm run typecheck
- name: Test
run: npm run test:coverage
- name: Build
run: npm run build
- name: Upload coverage
uses: actions/upload-artifact@v4
with:
name: coverage
path: coverage
if-no-files-found: ignore
19 changes: 19 additions & 0 deletions .github/workflows/release-please.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: Release Please

on:
push:
branches: [main]

permissions:
contents: write
pull-requests: write

jobs:
release-please:
runs-on: ubuntu-latest
steps:
- name: Release
uses: google-github-actions/release-please-action@v4
with:
config-file: release-please-config.json
manifest-file: release-please-manifest.json
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ node_modules/

# Build output
dist/
coverage/

# IDE
.vscode/
Expand Down
5 changes: 5 additions & 0 deletions .prettierrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"singleQuote": false,
"trailingComma": "none",
"printWidth": 100
}
12 changes: 12 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# Changelog

All notable changes to this project will be documented in this file.

## [Unreleased]

- Readiness report with monorepo support and fix-first checklist.
- CI workflow with lint, typecheck, tests, and build steps.
- Release automation via release-please.
- ESLint, Prettier, and Vitest tooling plus starter tests.
- Added contributing, security, and issue/PR templates.
- Added examples folder with sample configs.
1 change: 1 addition & 0 deletions CODEOWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
* @pierceboggan
34 changes: 34 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# Contributing

Thanks for contributing to Primer.

## Quick start

1. Fork and clone the repo.
2. Install dependencies: npm install
3. Build locally: npm run build
4. Run lint/typecheck/tests before opening a PR:
- npm run lint
- npm run typecheck
- npm run test

## Development workflow

- Create a feature branch from main.
- Use clear, conventional commit messages (e.g. feat: add readiness report).
- Keep PRs focused and include context in the description.
- Add or update tests when behavior changes.

## Code style

- ESLint + Prettier are enforced in CI.
- Prefer small, composable functions with clear types.

## Reporting issues

- Use GitHub Issues for bugs and feature requests.
- Provide steps to reproduce and expected behavior.

## Releasing

Releases are automated with release-please when changes are merged to main.
21 changes: 21 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2026 Primer

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.
76 changes: 53 additions & 23 deletions PLAN.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,29 +16,34 @@ Make any repository "AI-ready" with a single command — generating optimal conf
- Detect language(s), frameworks, and project structure
- Identify existing AI configurations
- Analyze package managers, build tools, and testing frameworks
- Detect monorepo vs single-project structure
- Detect monorepo vs single-project structure (workspace-aware)

### 2. **Configuration Generation**
### 2. **Readiness Report**
- Score AI readiness across key pillars
- Provide fix-first checklists and maturity levels
- Support monorepos with app-scoped checks

### 3. **Configuration Generation**

| Config Type | Description |
|-------------|-------------|
| **Custom Instructions** | `.github/copilot-instructions.md` generated via Copilot SDK |
| **MCP Server Config** | `.vscode/mcp.json` for Model Context Protocol servers |
| **VS Code Settings** | `.vscode/settings.json` with AI-optimized workspace settings |

### 3. **GitHub Integration**
### 4. **GitHub Integration**
- Authenticate via GitHub CLI (`gh auth`) or OAuth device flow
- List and select from accessible repositories
- Clone repos temporarily for analysis
- **Auto-create PRs** with generated configurations
- Support for GitHub Enterprise

### 4. **Local Repository Support**
### 5. **Local Repository Support**
- Detect local Git repositories
- Work offline with local-only mode
- Push changes to remote when ready

### 5. **Interactive & Non-Interactive Modes**
### 6. **Interactive & Non-Interactive Modes**
- Beautiful TUI with prompts and previews
- CI/CD-friendly `--yes` flag for automation
- JSON output for scripting
Expand Down Expand Up @@ -99,6 +104,9 @@ primer pr owner/repo
# Analyze repo without making changes
primer analyze

# Readiness report
primer readiness

# Update existing configurations
primer update

Expand All @@ -107,6 +115,18 @@ primer templates

# Configure CLI settings
primer config

# Generate instructions
primer instructions

# Run evaluations
primer eval primer.eval.json

# Run TUI
primer tui

# Batch processing
primer batch
```

---
Expand Down Expand Up @@ -370,23 +390,33 @@ primer/
│ ├── index.ts # Entry point
│ ├── cli.ts # Commander setup
│ ├── commands/
│ │ ├── init.ts
│ │ ├── generate.ts
│ │ ├── analyze.ts
│ │ ├── batch.tsx
│ │ ├── config.ts
│ │ ├── eval.ts
│ │ ├── generate.ts
│ │ ├── init.ts
│ │ ├── instructions.tsx
│ │ ├── pr.ts
│ │ └── config.ts
│ │ ├── readiness.ts
│ │ ├── templates.ts
│ │ ├── tui.tsx
│ │ └── update.ts
│ ├── services/
│ │ ├── github.ts # GitHub API interactions
│ │ ├── analyzer.ts # Repo analysis logic
│ │ ├── azureDevops.ts # Azure DevOps integration
│ │ ├── evaluator.ts # Eval runner
│ │ ├── generator.ts # Config generation
│ │ └── git.ts # Local git operations
│ │ ├── git.ts # Local git operations
│ │ ├── github.ts # GitHub API interactions
│ │ └── instructions.ts # Copilot SDK integration
│ ├── ui/
│ │ ├── prompts.ts # Inquirer prompts
│ │ ├── spinner.ts # Loading indicators
│ │ └── preview.ts # File previews
│ │ ├── AnimatedBanner.tsx
│ │ ├── BatchTui.tsx
│ │ ├── BatchTuiAzure.tsx
│ │ └── tui.tsx
│ └── utils/
│ ├── fs.ts # File system helpers
│ ├── detection.ts # Language/framework detection
│ └── logger.ts # Styled console output
├── package.json
├── tsconfig.json
Expand Down Expand Up @@ -476,24 +506,24 @@ Create example repos for each major stack:
# Install dependencies
npm install

# Development with watch mode
npm run dev

# Build for production
npm run build

# Run tests
npm test

# Lint and format
npm run lint
npm run format

# Type check
npm run typecheck

# Run tests
npm run test

# Coverage
npm run test:coverage

# Link globally for testing
npm link

# Create standalone binaries
npm run package
```

---
Expand Down
Loading
Loading