Skip to content

Release 2.1.0 - #62

Merged
YagoBorba merged 43 commits into
mainfrom
release/2.1.0
Nov 25, 2026
Merged

YagoBorba merged 43 commits into
mainfrom
release/2.1.0

Conversation

@YagoBorba

Copy link
Copy Markdown
Owner

Release 2.1.0 of the StackCode CLI, core, i18n and VS Code extension.

Merged into develop since 2.0.1:

This branch also merges main (the 2.0.1 bump and hotfix) and sets @stackcode/cli, core, i18n and the extension to 2.1.0.

Closes #30
Closes #58

After merging: tag v2.1.0, publish the GitHub release with the VSIX, and merge main back into develop. Publishing to npm and the Marketplace needs the maintainer's tokens.

YagoBorba and others added 30 commits September 30, 2025 00:54
Complete migration of CLI and VS Code extension to use shared workflows from @stackcode/core.

## Core Changes
- Added centralized workflow system in packages/core/src/workflows.ts
- All operations (init, generate, commit, validate, git, release) now use shared workflows
- Standardized GitHub API integration with consistent error handling
- Enhanced type definitions and comprehensive test coverage

## CLI Modernization
- Created CLIAuthManager for secure GitHub token management
- Refactored all commands to delegate to core workflows
- Removed Configstore dependency in favor of secure file-based token storage
- Added comprehensive smoke testing script (scripts/test-cli-commands.sh)

## VS Code Extension Updates
- Updated all commands to use core workflows maintaining UI integration
- Preserved OAuth2 authentication while standardizing backend operations
- Enhanced dashboard and webview integration with shared data layer

## Benefits Achieved
- ✅ Consistent behavior across CLI and VS Code interfaces
- ✅ Single source of truth for all core operations
- ✅ Improved security with proper token management
- ✅ Comprehensive test coverage and automated validation
- ✅ Enhanced maintainability and code reuse

All tests passing. Ready for multi-interface workflow usage.
- Create shared @stackcode/github-auth package with provider-based architecture
- Add CLI and VS Code authentication providers with secure token storage
- Refactor CLI commands (github, release, ui) to use async authentication facade
- Replace VS Code GitHubAuthService with unified auth integration
- Align Octokit dependencies and TypeScript project references
- Add comprehensive tests for CLI authentication provider
- Implement file-based token storage with secure permissions
- Support optional token sharing between CLI and VS Code environments

Breaking changes:
- CLI authentication methods now async (login, logout, getSession)
- VS Code authentication service API updated for shared module integration
- Create runIssuesWorkflow() for unified GitHub issues fetching
- Add cache management functions (clear, clearExpired, clearRepository)
- Implement progress reporting hooks for UI feedback
- Add cache statistics and monitoring functions
- Export all issues workflow types and interfaces
- Update fetchRepositoryIssues() with English docstrings
- Add createGitHubRelease() docstring

This centralizes all issues business logic in @stackcode/core,
enabling consistent behavior across CLI and VS Code extension.
- Update CommitCommand to use runIssuesWorkflow() from core
- Update DashboardProvider to use runIssuesWorkflow() from core
- Simplify GitHubIssuesService to thin wrapper (marked deprecated)
- Remove GitHubIssuesService instantiation from extension.ts
- Replace service dependency with GitMonitor in commands

This eliminates code duplication and ensures consistent GitHub
issues handling between CLI and VS Code extension.
- Add comprehensive docstrings to all release.ts functions
- Remove inline comments from workflows.ts for cleaner code
- Remove Portuguese comments from vite.config.ts
- Update dashboard title from 'Dashboard' to 'StackCode Dashboard'

Improves code documentation quality and removes unnecessary
comments throughout the codebase.
- Add missing await on getAuthenticatedClient() call
- Fixes type error: Promise<Octokit> cannot be used where Octokit is expected

Resolves async/await issue preventing GitHub release creation.
- Remove Portuguese comments from github.ts command
- Remove Portuguese comments from release.ts command
- Ensure all documentation is in English

Maintains consistent English-only documentation across CLI.
- Rebuild CLI dist after documentation improvements
- Rebuild core dist after issues workflow implementation
- Rebuild VS Code extension out after service refactoring
- Remove obsolete IMPLEMENTATION.md documentation

Updates compiled artifacts to reflect all source code changes.
…k system

- Add centralized ProgressManager service for workflow progress tracking
- Create progress event types and state management system
- Implement ProgressIndicator React component for visual feedback
- Add useProgress hook for webview state management
- Integrate progress tracking in CommitCommand and ReleaseCommand
- Update DashboardProvider to implement WebviewProgressListener
- Add real-time progress updates for issues, commit, and release workflows
- Implement loading states with spinner, progress bar, and percentage
- Add i18n keys for progress messages and UI feedback
- Clean up code: remove unnecessary comments, logs, and backup files
- Add comprehensive docstrings in English for all new components

Breaking Changes:
- Commands now require ProgressManager instance
- DashboardProvider constructor signature changed to include ProgressManager

Closes: Visual integration validation task
Implements: Progress feedback for multi-UI workflow architecture
- Parallelize GitHub Actions CI jobs using matrix strategy (60% faster)
- Remove 45+ redundant comments across extension codebase
- Translate all Portuguese docstrings to English
- Fix 8 ESLint violations (prefer-const, no-useless-escape, no-empty, no-unused-vars)
- Configure Jest to exclude webview-ui from coverage collection
- Prevent mock file duplication by excluding from TypeScript compilation
- Add .prettierignore to exclude generated files (out/, coverage/, node_modules/)
- Fix empty catch blocks with proper error logging

Performance improvements:
- CI runtime reduced from ~8-10min to ~3-4min
- Tests now run cleanly without warnings

Code quality:
- All docstrings standardized in English
- ESLint: 0 errors
- Prettier: 100% formatted
- Tests: 75 passing (CLI + Core + Extension)
- Apply Prettier formatting to all packages
- Standardize code style and indentation
- Fix ESLint warnings in test files
- Update package.json formatting

Affected packages:
- @stackcode/cli
- @stackcode/core
- @stackcode/github-auth
- Recompile extension with latest changes
- Remove duplicate mock files from out/ directory
- Update source maps
- Add install-test-deps.sh for dependency installation
- Add run-extension-tests.sh for running all extension tests
- Make scripts executable
- Add packages/vscode-extension/coverage/ to .gitignore
- Prevent committing test coverage reports
…dules

- Split monolithic workflows.ts into 6 specialized modules:
  - workflows/generate.ts: Template generation workflows
  - workflows/git.ts: Git branch and commit workflows
  - workflows/init.ts: Project initialization workflows
  - workflows/release.ts: Version release workflows
  - workflows/validate.ts: Validation workflows
  - workflows/index.ts: Centralized exports
- Update index.ts to re-export from new workflow modules
- Maintain backward compatibility with existing API
- Improve maintainability and separation of concerns
- Update import paths to use new workflow module structure
- Ensure all existing functionality is properly tested
- Maintain 100% test coverage for core package (29/29 tests passing)
- Add explicit type annotations for workflow progress callbacks
- Fix implicit 'any' type errors in CommitCommand.ts and GitCommand.ts
- Ensure type safety for workflow progress reporting
- Maintain proper TypeScript strict mode compliance
- Properly restore workspace folder state in integration tests
- Fix async/await patterns for reliable test execution
- Ensure clean test isolation and proper cleanup
- Achieve 100% test coverage (24/24 tests passing) for VSCode extension
- Document new modular workflow architecture in all languages
- Update pt-BR translation with complete architecture details
- Update es translation with complete architecture details
- Explain separation of concerns across workflow modules
- Update module dependency diagrams and descriptions
- Provide clear guidance for maintaining the new structure
- Remove empty commands.integration.test.ts file
- Remove empty extension.smoke.test.ts file
- Fix Jest test suite execution errors
- Ensure clean test runs with 24/24 tests passing
Moved issues-workflow.ts into the /workflows directory to align with the new scalable architecture.

This change centralizes all workflow orchestration logic, improving consistency and maintainability across the codebase.

- Moved  to .
- Updated all relevant imports and exports to reflect the new file location.
- Ensured backward compatibility by re-exporting from the legacy path.
Fixed relative import path after moving issues workflow to the workflows directory.

Changed './github.js' to '../github.js' to properly reference the github module from the workflows subdirectory.
Fixed code style issues in workflows.ts and git.ts to comply with Prettier standards.
…tecture

Feature/multi UI workflow architecture
- Replace white overflow elements with controlled gray shades
- Update Dashboard main titles to pure white (#ffffff) for better hierarchy
- Convert quick action buttons from gradient to unified gray style
- Adjust notification panel buttons to match gray theme
- Remove all unnecessary CSS comments for cleaner code
- Define consistent text color utilities (slate-100 through slate-500)
- Apply inline styles for critical title elements
- Maintain proper contrast ratios for accessibility
…dashboard UX

- Add GitHubRemoteStatsService for real-time repository data via Octokit
- Implement AuthFlowManager for interactive GitHub authentication
- Add auto-refresh mechanism (20s interval) for stats and issues
- Implement issue redirect button to open GitHub URLs in browser
- Add three view modes (sidebar-only, full, compact) with toggle buttons
- Display actual Git branch from repository instead of hardcoded value
- Auto-dismiss welcome notification after 5 seconds
- Improve responsive layout without horizontal scroll
- Reduce console logging by setting DEBUG flag to false
- Fix acquireVsCodeApi() error by passing API via props
- Update status bar with view mode controls (PanelLeftOpen, Maximize2 icons)
… only docstrings for documentation. Improves code clarity and maintainability.
- Add refreshAuthState method to DashboardProvider for post-auth updates
- Implement blur effects on auth-dependent cards when not logged in
- Modify IssuesPanel to show blurred card instead of login prompt
- Integrate dashboard refresh with auth logout command
- Add CSS classes for card blur effects and overlays
- Remove docstring comments for cleaner codebase

Enhances user experience by providing consistent visual feedback
when GitHub authentication is required across dashboard components.
- Restore missing GitHubIssue interface in IssuesPanel component
- Remove unused LogIn import and onLogin parameter
- Fix extension.ts function structure and import order
- Remove duplicate function declarations and docstrings

Ensures clean compilation and removes lint warnings.
ci: run the pipeline on Node 22 and allow manual runs
dist/ and out/ were already in .gitignore but had been committed, so every
build changed tracked files. Packaged .vsix files are now ignored too.
The dashboard showed hard-coded numbers (23 files, 42 commits, 3
contributors, 1247 lines) and a made-up activity list. It now reads the
local Git repository (commits, branches, contributors, tracked files,
commits this week and month, and the latest commits as recent activity),
which works offline and without signing in. When the user is signed in,
GitHub data is added: stars, forks, watchers and open issues.

Brings in the GitHub statistics service from the webview branch and drops
its debug commands (Test Project Statistics, GitHub detection), the note
about resizing the sidebar and the mixed Portuguese and English labels.
…installed

The VSIX excluded node_modules, while the extension requires
@stackcode/core, @stackcode/i18n and @octokit/rest at runtime, and core is
an ES module that CommonJS cannot require. The extension is now bundled
with esbuild into dist/extension.js, with import.meta.url mapped to the
bundle and the core templates and i18n locales copied next to it.

The smoke test files were empty; the smoke test now starts VS Code with
the bundle, activates it and checks that every command is registered. CI
runs it and uploads the packaged VSIX. The package declares the MIT
license and ships the LICENSE file.
Closes #30. In GitFlow those branches receive changes through pull
requests. stc commit now warns, suggests starting a branch with
stc git start and asks for confirmation (default no). The VS Code commit
command shows the same warning with Start a new branch and Commit anyway.

@stackcode/core exports getCurrentBranch, isProtectedBranch and
DEFAULT_PROTECTED_BRANCHES, tested against a real repository. Messages
are available in English, Portuguese and Spanish.
feat(vscode-extension): real dashboard data and an installable VSIX
…branch-warning

# Conflicts:
#	packages/vscode-extension/src/commands/CommitCommand.ts
feat: warn before committing directly on main, master or develop
Bring the 2.0.1 release and hotfix from main, set every package to 2.1.0
(github-auth stays at 1.0.0) and drop the old educational mode test
backup in favour of test/commands/educational-mode.test.ts.
@YagoBorba
YagoBorba merged commit 175d6a9 into main Nov 25, 2026
5 checks passed
@YagoBorba
YagoBorba deleted the release/2.1.0 branch November 25, 2026 23:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Complete webview implementation with real-time data and interactive UI Implement Wrong Branch Detection

1 participant