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
5 changes: 5 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
out/
node_modules/
coverage/
src/__mocks__/
*.vsix
33 changes: 33 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
{
"root": true,
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaVersion": 2022,
"sourceType": "module"
},
"plugins": ["@typescript-eslint"],
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/recommended",
"prettier"
],
"env": {
"node": true,
"es2022": true
},
"rules": {
"@typescript-eslint/no-explicit-any": "error",
"no-constant-condition": ["error", { "checkLoops": false }],
"@typescript-eslint/no-unused-vars": [
"error",
{ "argsIgnorePattern": "^_" }
],
"no-console": "off"
},
"overrides": [
{
"files": ["**/*.test.ts"],
"env": { "jest": true }
}
]
}
24 changes: 11 additions & 13 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:
workflow_dispatch:

jobs:
# Wait for other CI workflows to complete
# Wait for the Tests workflow to pass before publishing
wait-for-ci:
name: Wait for CI to Complete
runs-on: ubuntu-latest
Expand All @@ -16,15 +16,7 @@ jobs:
uses: lewagon/wait-on-check-action@v1.3.4
with:
ref: ${{ github.sha }}
check-name: 'Test'
repo-token: ${{ secrets.GITHUB_TOKEN }}
wait-interval: 10

- name: Wait for build workflow
uses: lewagon/wait-on-check-action@v1.3.4
with:
ref: ${{ github.sha }}
check-name: 'Build'
check-name: 'test'
repo-token: ${{ secrets.GITHUB_TOKEN }}
wait-interval: 10

Expand All @@ -46,11 +38,17 @@ jobs:
- name: Install Dependencies
run: npm ci

- name: Lint
run: npm run lint

- name: Run Unit Tests
run: npm run test:unit

- name: Compile Extension
run: npm run compile

- name: Install vsce
run: npm install -g @vscode/vsce
- name: Install vsce and ovsx
run: npm install -g @vscode/vsce ovsx

- name: Publish to VS Code Marketplace
env:
Expand All @@ -61,5 +59,5 @@ jobs:
- name: Publish to Open VSX Registry
env:
OVSX_PAT: ${{ secrets.OVSX_PAT }}
run: vsce publish --no-yarn --target linux-x64 --packagedExtensionPath extension.vsix
run: ovsx publish --pat "$OVSX_PAT"
if: env.OVSX_PAT != ''
3 changes: 3 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ jobs:
- name: Install dependencies
run: npm ci

- name: Lint
run: npm run lint

- name: Compile TypeScript
run: npm run compile

Expand Down
5 changes: 5 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
out/
node_modules/
coverage/
package-lock.json
*.vsix
7 changes: 7 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"semi": true,
"singleQuote": false,
"trailingComma": "all",
"printWidth": 80,
"tabWidth": 2
}
22 changes: 19 additions & 3 deletions .vscodeignore
Original file line number Diff line number Diff line change
@@ -1,7 +1,23 @@
.vscode/**
.github/**
src/**
tsconfig.json
**/*.map
**/*.ts
coverage/**
node_modules/**
**/*.ts
**/*.map
out/**/*.test.js
out/test/**
out/__mocks__/**
tsconfig.json
tsconfig.test.json
jest.config.js
.mocharc.json
.vscode-test.json
.eslintrc.json
.eslintignore
.prettierrc
.prettierignore
.gitignore
**/*.vsix
TESTING.md
PUBLISHING.md
68 changes: 68 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
# Changelog

All notable changes to the **Nuvo Commit** extension are documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [1.0.0] - 2026-05-22

First stable release. No new features compared to `0.1.x` — this release hardens
the extension for production use.

### Added

- `Nuvo Commit: Set API Key` command — stores cloud provider API keys in VS Code's
encrypted `SecretStorage` instead of plaintext settings.
- `nuvoCommit.requestTimeoutMs` setting — provider requests now abort after a
configurable timeout (default 30s) instead of hanging indefinitely.
- ESLint + Prettier configuration and a `lint` step in CI.
- Unit tests for git diff retrieval and provider configuration.
- `CHANGELOG.md`.

### Changed

- API keys are migrated automatically from the deprecated `nuvoCommit.apiKey`
setting into secure storage and removed from `settings.json`.
- The provider config shape is now decided by the selected provider. Choosing a
cloud provider without an API key now shows a clear, actionable error.

### Fixed

- Publish workflow waited on non-existent CI checks (`Test`/`Build`), which could
stall releases indefinitely.
- `tsc` build and Jest unit tests failed because the `tsconfig` `types` field
excluded the test type definitions.
- Removed unsafe `as any` casts in provider registration.

### Security

- Cloud provider API keys are no longer stored as plaintext in `settings.json`.

## [0.1.1] - 2026-05

### Added

- Multi-provider documentation and cloud configuration examples.
- `order` metadata for settings so they render in a sensible order in the
Settings UI.

### Changed

- Updated publishing and testing documentation.

## [0.1.0] - 2026-05

### Added

- Initial release: AI-generated commit messages from staged (or working
directory) git diffs.
- Multi-provider support: Ollama (local), OpenAI, and Anthropic.
- Diff optimization that skips lock files, generated files, and build output.
- Conventional Commits enforcement with sanitization and a safe fallback.
- `Nuvo Commit: Select Model` command with automatic model discovery for Ollama.
- `autoAccept` and `autoCommit` settings.

[1.0.0]: https://github.com/nuvocode/nuvo-commit/releases/tag/v1.0.0
[0.1.1]: https://github.com/nuvocode/nuvo-commit/releases/tag/v0.1.1
[0.1.0]: https://github.com/nuvocode/nuvo-commit/releases/tag/v0.1.0
77 changes: 32 additions & 45 deletions PUBLISHING.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,72 +2,59 @@

## GitHub Secrets Configuration

Bu workflow'un çalışması için aşağıdaki GitHub secrets'ları ayarlamanız gerekiyor:

### 1. VS Code Marketplace (vsce) Personal Access Token

1. https://marketplace.visualstudio.com/manage adresine gidin
2. Sol menüden "Security" sekmesine tıklayın
3. "New Personal Access Token" butonuna tıklayın
4. Token'a bir isim verin (örn: `nuvo-commit-ci`)
5. "All accessible organizations" seçin
6. Oluşturulan token'ı kopyalayın
7. GitHub repository'nizde:
1. Go to https://marketplace.visualstudio.com/manage
2. Click "Security" in the left menu
3. Click "New Personal Access Token"
4. Name it (e.g., `nuvo-commit-ci`)
5. Select "All accessible organizations"
6. Copy the generated token
7. In your GitHub repository:
- Settings → Secrets and variables → Actions
- "New repository secret" butonuna tıklayın
- Click "New repository secret"
- Name: `VSCE_PAT`
- Value: Kopyaladığınız token

### 2. Open VSX Registry Token (Opsiyonel)
- Value: Paste the token

Eğer Open VSX Registry'ye de publish etmek isterseniz:
### 2. Open VSX Registry Token (Optional)

1. https://open-vsx.org/user-settings/tokens adresine gidin
2. "Create New Token" butonuna tıklayın
3. Token'ı kopyalayın
4. GitHub repository'nizde:
1. Go to https://open-vsx.org/user-settings/tokens
2. Click "Create New Token"
3. Copy the token
4. In your GitHub repository:
- Settings → Secrets and variables → Actions
- "New repository secret" butonuna tıklayın
- Click "New repository secret"
- Name: `OVSX_PAT`
- Value: Kopyaladığınız token
- Value: Paste the token

## Workflow Akışı
## Workflow Flow

1. **Master branch'e push** yapıldığında workflow tetiklenir
2. **CI beklemesi**: Diğer test ve build workflow'larının tamamlanmasını bekler
3. **Build**: Extension derlenir ve paketlanır
4. **Publish**: VS Code Marketplace'e otomatik olarak publish edilir
1. **Push to master** triggers the workflow
2. **CI wait**: Waits for test and build workflows to complete
3. **Build**: Compiles and packages the extension
4. **Publish**: Automatically publishes to VS Code Marketplace

## Manuel Tetikleme
## Manual Trigger

Workflow'u manuel olarak da tetikleyebilirsiniz:
- GitHub repository → Actions → "Publish VS Code Extension" → "Run workflow"

## Version Yönetimi
## Version Management

Her publish işleminden önce `package.json` dosyasındaki `version` alanını güncellemeyi unutmayın:
Update the `version` field in `package.json` before each publish:

```json
{
"version": "0.1.1" // Minor veya patch versiyonunu artırın
"version": "0.1.1" // Increment minor or patch version
}
```

## Gerekli CI Workflow'ları

Bu workflow, aşağıdaki check'lerin tamamlanmasını bekler:
- `Test` - Test workflow'u
- `Build` - Build workflow'u

Eğer farklı isimlerde CI workflow'larınız varsa, `publish.yml` dosyasındaki `check-name` değerlerini güncelleyin.

## Troubleshooting

### Workflow CI'yi bekliyor ama CI yoksa
- Eğer henüz CI workflow'ları oluşturmadıysanız, `wait-for-ci` job'unu kaldırabilirsiniz
- Veya check-name değerlerini mevcut workflow'larınıza göre güncelleyin
### Workflow waiting for CI but no CI exists
- Remove the `wait-for-ci` job if you haven't created CI workflows yet
- Or update `check-name` values to match your workflow names

### Publish hatası alıyorsanız
- VSCE_PAT secret'ının doğru ayarlandığından emin olun
- Token'ın süresinin dolmadığını kontrol edin
- Publisher adının (`nuvocode`) marketplace'te kayıtlı olduğunu doğrulayın
### Publish errors
- Verify VSCE_PAT secret is set correctly
- Check token hasn't expired
- Confirm publisher name (`nuvocode`) is registered on marketplace
Loading
Loading