diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md new file mode 100644 index 0000000..c834909 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -0,0 +1,35 @@ +--- +name: Bug report +about: Report a reproducible bug in Context Drift +title: "[Bug]: " +labels: bug +--- + +## Summary + +Describe the bug in one or two sentences. + +## Steps to Reproduce + +1. +2. +3. + +## Expected Behavior + +What did you expect to happen? + +## Actual Behavior + +What happened instead? + +## Environment + +- OS: +- Node version: +- Command: +- Relevant branch or commit: + +## Additional Context + +Add logs, screenshots, or other details that help reproduce the issue. diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md new file mode 100644 index 0000000..f6ee934 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -0,0 +1,26 @@ +--- +name: Feature request +about: Suggest a focused improvement for Context Drift +title: "[Feature]: " +labels: enhancement +--- + +## Summary + +Describe the feature or improvement you want. + +## Problem Statement + +What issue does this solve? + +## Proposed Behavior + +What should the tool do? + +## Scope + +Keep the request focused on one problem. If there are follow-up ideas, list them separately. + +## Additional Context + +Add examples, mockups, or references if useful. diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md new file mode 100644 index 0000000..d4da274 --- /dev/null +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -0,0 +1,20 @@ +## Summary + +Briefly describe the issue this PR solves. + +## Related Issue + +Link the issue this PR closes or references. + +## What Changed + +- + +## Validation + +- + +## Notes + +- Keep this PR focused on one issue. +- If other work surfaced during implementation, open a follow-up PR instead of bundling it here. diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..016c59d --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,35 @@ +name: CI + +on: + push: + branches: + - main + pull_request: + branches: + - main + +jobs: + test: + runs-on: ubuntu-latest + + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Setup Node.js + uses: actions/setup-node@v4 + with: + node-version: 20 + cache: npm + + - name: Install dependencies + run: npm ci + + - name: Build + run: npm run build + + - name: Test + run: npm test + + - name: Typecheck + run: npm run typecheck diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..d67c342 --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,24 @@ +# Changelog + +All notable changes to this project will be documented in this file. + +## [Unreleased] + +### Added + +- MIT `LICENSE` file for the project. +- `SECURITY.md` with a private vulnerability reporting path. +- `docs/architecture.md` and `docs/checks.md` for repository context. +- GitHub issue and pull request templates under `.github/`. +- A GitHub Actions CI workflow for build, test, and typecheck verification. +- Contributor guidance for keeping pull requests focused and low-noise. +- A pull request template in `CONTRIBUTING.md`. +- README contribution steps for local validation and PR preparation. + +## [0.1.0] - 2026-06-03 + +### Added + +- Initial CLI foundation for scanning supported source files. +- Git-based changed-file detection through `check --base`. +- Naming-style summary reporting for repository files. diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000..082f0dd --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,56 @@ +# Contributing + +Thanks for helping improve Context Drift. + +Keep changes focused, reviewable, and easy to verify. + +## Principles + +- Open one issue per pull request. +- Avoid noisy PRs that mix unrelated fixes, refactors, or formatting changes. +- Keep the scope small enough that a reviewer can understand the change quickly. +- Include validation steps in every PR. +- Use the repository PR template at [`.github/PULL_REQUEST_TEMPLATE.md`](./.github/PULL_REQUEST_TEMPLATE.md). + +## Before You Open a PR + +1. Create a branch for the specific issue you are solving. +2. Make the smallest change that fully addresses that issue. +3. Run the relevant checks: + - `npm run build` + - `npm test` + - `npm run typecheck` +4. Confirm the diff contains only the files that belong in the PR. +5. Open the PR with a clear title and a short explanation of the change. + +## Pull Request Template + +Use this template when opening a PR: + +```md +## Summary +Briefly describe the issue and the fix. + +## Related Issue +Link the issue this PR closes or references. + +## What Changed +- List the user-visible or behavior changes. +- Keep this focused on the single issue the PR solves. + +## Validation +- List the commands or tests you ran. +- Mention any manual checks if they matter. + +## Notes +- Call out anything a reviewer should know. +- Mention follow-up work separately instead of bundling it here. +``` + +## Good PR Shape + +- One problem. +- One solution. +- One review path. + +If a change starts to expand, split it into a follow-up PR instead of letting the current one become noisy. diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..10c36b6 --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2026 Context Drift contributors + +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 index dc4ba04..b912d6a 100644 --- a/README.md +++ b/README.md @@ -1,16 +1,61 @@ -# Context Drift +
+
+
+
+
+ Context Drift scans supported source files, summarizes their naming styles, and highlights the files that changed relative to git or an explicit file list. +
+ +| + +**What it checks** + +- `**/*.ts` +- `**/*.tsx` +- `**/*.js` +- `**/*.jsx` + +**What it ignores** + +- `node_modules` +- `.git` +- `.next` +- `dist` +- `build` +- `coverage` + + | +