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
6 changes: 3 additions & 3 deletions .claude/tasks/clean-code-review.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ Reimplement the current branch on a new branch with a clean, narrative-quality g

1. **Validate the source branch**
- Ensure the current branch has no merge conflicts, uncommitted changes, or other issues.
- Confirm it is up to date with `v2_develop`.
- Confirm it is up to date with `develop`.

2. **Analyze the diff**
- Study all changes between the current branch and `v2_develop`.
- Study all changes between the current branch and `develop`.
- Form a clear understanding of the final intended state.

3. **Create the clean branch**
Expand All @@ -33,7 +33,7 @@ Reimplement the current branch on a new branch with a clean, narrative-quality g
- Use `--no-verify` only when necessary (e.g., to bypass known issues). Individual commits do not need to pass tests, but this should be rare.

7. **Open a pull request**
- Create a PR from the clean branch to `v2_develop`.
- Create a PR from the clean branch to `develop`.
- Follow Terminal.Gui PR guidelines (see CONTRIBUTING.md).
- Include a link to the original branch in the PR description.

Expand Down
4 changes: 2 additions & 2 deletions .claude/workflows/pr-workflow.md
Original file line number Diff line number Diff line change
Expand Up @@ -116,9 +116,9 @@ git diff

1. **Monitor CI/CD pipelines** - Ensure all checks pass
2. **Address review feedback** promptly
3. **Keep PR updated** with `v2_develop` if needed:
3. **Keep PR updated** with `develop` if needed:
```bash
git fetch origin
git rebase origin/v2_develop
git rebase origin/develop
git push --force-with-lease
```
16 changes: 8 additions & 8 deletions .github/workflows/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ The repository uses multiple GitHub Actions workflows. What runs and when:

### 1) Build Validation (`.github/workflows/build-validation.yml`)

- **Triggers**: push and pull_request to `v2_release`, `v2_develop` (ignores `**.md`)
- **Triggers**: push and pull_request to `main`, `develop` (ignores `**.md`)
- **Runner/timeout**: `ubuntu-latest`, 10 minutes
- **Steps**:
- Checkout and setup .NET 10.x GA
Expand All @@ -22,7 +22,7 @@ The repository uses multiple GitHub Actions workflows. What runs and when:

### 2) Build & Run Unit Tests (`.github/workflows/unit-tests.yml`)

- **Triggers**: push and pull_request to `v2_release`, `v2_develop` (ignores `**.md`)
- **Triggers**: push and pull_request to `main`, `develop` (ignores `**.md`)
- **Matrix**: Ubuntu/Windows/macOS
- **Timeout**: 15 minutes (non-parallel), 60 minutes (parallel)
- **Process**:
Expand All @@ -39,7 +39,7 @@ The repository uses multiple GitHub Actions workflows. What runs and when:

### 3) Build & Run Integration Tests (`.github/workflows/integration-tests.yml`)

- **Triggers**: push and pull_request to `v2_release`, `v2_develop` (ignores `**.md`)
- **Triggers**: push and pull_request to `main`, `develop` (ignores `**.md`)
- **Matrix**: Ubuntu/Windows/macOS
- **Timeout**: 15 minutes
- **Process**:
Expand All @@ -56,7 +56,7 @@ The repository uses multiple GitHub Actions workflows. What runs and when:
- `release_type`: Choose from `prealpha`, `alpha`, `beta`, `rc`, or `stable`
- `version_override`: (Optional) Specify exact version number, otherwise GitVersion calculates it
- **Process**:
1. Checks out `v2_release` branch
1. Checks out `main` branch
2. Determines version using GitVersion or override
3. Creates annotated git tag (e.g., `v2.0.0-prealpha` or `v2.0.0`)
4. Creates release commit with message
Expand All @@ -67,19 +67,19 @@ The repository uses multiple GitHub Actions workflows. What runs and when:

### 5) Publish to NuGet (`.github/workflows/publish.yml`)

- **Triggers**: push to `v2_release`, `v2_develop`, and tags `v*`(ignores `**.md`)
- **Triggers**: push to `main`, `develop`, and tags `v*`(ignores `**.md`)
- Uses GitVersion to compute SemVer, builds Release, packs with symbols, and pushes to NuGet.org using `NUGET_API_KEY`
- **Automatically triggered** by the Create Release workflow when a new tag is pushed
- **Additional actions on v2_release branch**:
- **Additional actions on main branch**:
- Delists old NuGet packages to keep package list clean:
- Keeps only the most recent `2.0.0-develop.*` package
- Keeps only the just-published `2.0.0-alpha.*` or `2.0.0-beta.*` package
- Triggers Terminal.Gui.templates repository update via repository_dispatch (requires `PAT_FOR_TEMPLATES` secret)

### 6) Build and publish API docs (`.github/workflows/api-docs.yml`)

- **Triggers**: push to `v1_release` and `v2_develop`
- Builds DocFX site on Windows and deploys to GitHub Pages when `ref_name` is `v2_release` or `v2_develop`
- **Triggers**: push to `v1_release` and `develop`
- Builds DocFX site on Windows and deploys to GitHub Pages when `ref_name` is `main` or `develop`


### Replicating CI Locally
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/api-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Build and publish v2 API docs

on:
push:
branches: [v2_develop]
branches: [develop]

permissions:
id-token: write
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/build-validation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@ name: Build Validation

on:
push:
branches: [ v2_release, v2_develop ]
branches: [ main, develop ]
paths-ignore:
- '**.md'
pull_request:
branches: [ v2_release, v2_develop ]
branches: [ main, develop ]
paths-ignore:
- '**.md'

Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/check-duplicates.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
name: Check for Duplicate UnitTests
on:
push:
branches: [ v2_release, v2_develop ]
branches: [ main, develop ]
pull_request:
branches: [ v2_release, v2_develop ]
branches: [ main, develop ]
workflow_dispatch:
jobs:
check-duplicates:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,15 @@ name: "Code scanning"

on:
push:
branches: [main, v2_release]
branches: [main]
paths-ignore:
- '**/*.md'
- '**/*.txt'
- '**/*.html'
- docs
- docfx
pull_request:
branches: [main, v2_release]
branches: [main]
paths-ignore:
- '**/*.md'
- '**/*.txt'
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/integration-tests.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
name: Build & Run Integration Tests
on:
push:
branches: [ v2_release, v2_develop ]
branches: [ main, develop ]
paths-ignore:
- '**.md'
pull_request:
branches: [ v2_release, v2_develop ]
branches: [ main, develop ]
paths-ignore:
- '**.md'

Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Publish Terminal.Gui to Nuget

on:
push:
branches: [ v2_release, v2_develop ]
branches: [ main, develop ]
tags:
- v*
paths-ignore:
Expand Down Expand Up @@ -69,21 +69,21 @@ jobs:
run: dotnet nuget push Terminal.Gui/bin/Release/Terminal.Gui.${{ steps.gitversion.outputs.SemVer }}.nupkg --skip-duplicate --api-key ${{ secrets.NUGET_API_KEY }}

# - name: Delist old NuGet packages
# if: github.ref == 'refs/heads/v2_release'
# if: github.ref == 'refs/heads/main'
# shell: pwsh
# run: |
# $version = "${{ steps.gitversion.outputs.SemVer }}"
# Write-Host "Running delist script for just-published version: $version"
# ./Scripts/delist-nuget.ps1 -ApiKey "${{ secrets.NUGET_API_KEY }}" -JustPublishedVersion "$version"

- name: Prepare payload for template dispatch
if: github.ref == 'refs/heads/v2_release'
if: github.ref == 'refs/heads/main'
id: payload
run: |
echo "json={\"version\":\"${{ steps.gitversion.outputs.SemVer }}\"}" >> $GITHUB_OUTPUT

- name: Trigger Terminal.Gui.templates update
if: github.ref == 'refs/heads/v2_release'
if: github.ref == 'refs/heads/main'
uses: peter-evans/repository-dispatch@v3
with:
token: ${{ secrets.TEMPLATE_REPO_TOKEN }}
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,10 @@ jobs:
contents: write

steps:
- name: Checkout v2_release
- name: Checkout main
uses: actions/checkout@v4
with:
ref: v2_release
ref: main
fetch-depth: 0
token: ${{ secrets.GITHUB_TOKEN }}

Expand Down Expand Up @@ -99,7 +99,7 @@ jobs:

- name: Push Changes
run: |
git push origin v2_release
git push origin main
git push origin "${{ steps.prepare.outputs.tag }}"
echo "Pushed branch and tag to origin"

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/stress-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on:
schedule:
- cron: '0 0 * * *' # Runs every day at midnight UTC
push:
branches: [ v2_release, v2_develop ]
branches: [ main, develop ]
paths-ignore:
- '**.md'

Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/unit-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@ name: Build & Run Unit Tests

on:
push:
branches: [ v2_release, v2_develop ]
branches: [ main, develop ]
paths-ignore:
- '**.md'
pull_request:
branches: [ v2_release, v2_develop ]
branches: [ main, develop ]
paths-ignore:
- '**.md'

Expand Down
2 changes: 1 addition & 1 deletion CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ When in planning mode:
**Terminal.Gui** - Cross-platform .NET console UI toolkit

- **Language**: C# (net8.0)
- **Branch**: `v2_develop`
- **Branch**: `develop`
- **Version**: v2 (Alpha)

## Build & Test
Expand Down
10 changes: 5 additions & 5 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Welcome! This guide provides everything you need to know to contribute effective
- **Platform**: Cross-platform (Windows, macOS, Linux)
- **Architecture**: Console UI toolkit with driver-based architecture
- **Version**: v2 (Beta), v1 (maintenance mode)
- **Branching**: GitFlow model (v2_develop is default/active development)
- **Branching**: GitFlow model (develop is default/active development)

## Key Architecture Concepts

Expand Down Expand Up @@ -334,8 +334,8 @@ foreach (Rune rune in text.EnumerateRunes ())

### GitFlow Model

- `v2_develop` - Default branch, active development
- `v2_release` - Stable releases, matches NuGet
- `develop` - Default branch, active development
- `main` - Stable releases, matches NuGet
- `v1_develop`, `v1_release` - Legacy v1 (maintenance only)

## Release Process
Expand All @@ -348,14 +348,14 @@ Releases are now automated using GitHub Actions to prevent manual errors. To cre
2. **Select "Create Release" workflow** from the left sidebar
3. **Click "Run workflow"** button
4. **Configure release parameters:**
- **Branch:** Ensure `v2_release` is selected
- **Branch:** Ensure `main` is selected
- **Release type:** Choose from `prealpha`, `alpha`, `beta`, `rc`, or `stable`
- **Version override:** (Optional) Specify exact version (e.g., `2.0.0`), otherwise GitVersion calculates it automatically
5. **Click "Run workflow"** to start the automated release process

The workflow will:
- Create an annotated git tag (e.g., `v2.0.0-prealpha` or `v2.0.0`)
- Create a release commit on `v2_release`
- Create a release commit on `main`
- Push the tag and commit to the repository
- Create a GitHub Release
- Automatically trigger the publish workflow to push the package to NuGet.org
Expand Down
34 changes: 17 additions & 17 deletions GitVersion.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,26 +3,26 @@
# Terminal.Gui uses the GitFlow branching strategy.
# https://gitversion.net/docs/learn/branching-strategies/gitflow/
#
# - We have two main branches: `v2_release` and `v2_develop`.
# - `v2_release` is the main branch for V2 releases and matches the latest NuGet release package (e.g., 2.0.0);
# - We have two main branches: `main` and `develop`.
# - `main` is the main branch for V2 releases and matches the latest NuGet release package (e.g., 2.0.0);
# prior to release, it uses pre-release labels (e.g., 2.0.0-prealpha.1).
# - `v2_develop` is the development branch for V2 and always carries a pre-release label (e.g., 2.1.0-develop.1).
# - Development happens on feature branches off `v2_develop`.
# - For releases, we merge feature branches into `v2_develop`, then `v2_develop` into `v2_release`.
# - The ./.github/workflows/publish.yml builds and publishes on pushes to `v2_develop` and `v2_release`.
# - `develop` is the development branch for V2 and always carries a pre-release label (e.g., 2.1.0-develop.1).
# - Development happens on feature branches off `develop`.
# - For releases, we merge feature branches into `develop`, then `develop` into `main`.
# - The ./.github/workflows/publish.yml builds and publishes on pushes to `develop` and `main`.
#
# Branches:
# - v1_release: Main branch for V1 (historical)
# - v1_develop: Develop branch for V1 (historical)
# - v2_release: Main branch for V2
# - v2_develop: Develop branch for V2
# - main: Main branch for V2
# - develop: Develop branch for V2
#
# Package Naming:
# - from v2_develop: 2.1.0-develop.1 (minor version increments)
# - from v2_release (pre-release): 2.0.0-prealpha.1 or 2.0.0-beta.1
# - from v2_release (release): 2.0.0 (patch version increments)
# - from develop: 2.1.0-develop.1 (minor version increments)
# - from main (pre-release): 2.0.0-prealpha.1 or 2.0.0-beta.1
# - from main (release): 2.0.0 (patch version increments)
#
mode: ContinuousDelivery # GitVersion 6.x uses Mainline mode for GitFlow, focusing on main branch releases
mode: ContinuousDelivery # GitVersion 6.x is configured here to use ContinuousDelivery mode for this GitFlow-style setup

# We prefix our tags with 'v' or 'V' (e.g., v1.0.0)
tag-prefix: '[vV]'
Expand All @@ -31,19 +31,19 @@ branches:

# V2 Release Branch
main:
# Matches the v2_release branch
regex: ^v2_release$
# Matches the main branch
regex: ^main$
# Uses 'alpha' as pre-release label before `beta`
label: beta
Comment thread
tig marked this conversation as resolved.
# Increments patch version (x.y.z+1) on commits
increment: Patch
# Specifies v2_develop as the source branch
# Specifies develop as the source branch
source-branches: ['develop']

# V2 Development Branch
develop:
# Matches the v2_develop branch
regex: v2_develop
# Matches the develop branch
regex: develop
# Adds 'develop' as pre-release label (e.g., 2.1.0-develop.1)
label: develop
# Increments minor version (x.y+1.z) on commits
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
![v2 Beta Status](https://img.shields.io/github/milestones/progress-percent/gui-cs/Terminal.Gui/9)
![v2 Release Status](https://img.shields.io/github/milestones/progress-percent/gui-cs/Terminal.Gui/7)
Comment thread
tig marked this conversation as resolved.
![NuGet Version](https://img.shields.io/nuget/vpre/Terminal.Gui)
![Bugs](https://img.shields.io/github/issues/gui-cs/Terminal.Gui)
[![codecov](https://codecov.io/gh/gui-cs/Terminal.Gui/graph/badge.svg?token=1Ac9gyGtrj)](https://codecov.io/gh/gui-cs/Terminal.Gui)
Expand All @@ -16,7 +16,7 @@ Cross-platform UI toolkit for building sophisticated terminal UI (TUI) applicati

> **Important:**
> - **v1** is in maintenance mode - only critical bug fixes accepted
> - **v2 Beta** is recommended for new projects - API is stable with comprehensive features
> - **v2 Beta** is recommended for new projects - The team is 100% Focused on v2.0.0 RELEASE!
> - Breaking changes possible before Beta, but core architecture is solid

![Sample app](docfx/images/sample.gif)
Expand Down
2 changes: 1 addition & 1 deletion Scripts/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ PowerShell script to delist old NuGet packages, keeping only the most recent ver
- **Alpha packages** (`2.0.0-alpha.*`): Keeps only the just-published version (or most recent if not specified)
- **Beta packages** (`2.0.0-beta.*`): Keeps only the just-published version (or most recent if not specified)

This script is automatically run by the `publish.yml` workflow when publishing from the `v2_release` branch.
This script is currently intended to be run manually when old NuGet packages need to be delisted; it is not currently run automatically by `publish.yml`.

### LICENSE
MIT License
Expand Down
2 changes: 1 addition & 1 deletion Scripts/Terminal.Gui.PowerShell.Build.psd1
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ PrivateData = @{
# Tags = @()

# A URL to the license for this module.
LicenseUri = 'https://github.com/gui-cs/Terminal.Gui/tree/v2_develop/Scripts/COPYRIGHT'
LicenseUri = 'https://github.com/gui-cs/Terminal.Gui/tree/develop/Scripts/COPYRIGHT'

# A URL to the main website for this project.
ProjectUri = 'https://github.com/gui-cs/Terminal.Gui'
Expand Down
2 changes: 1 addition & 1 deletion Scripts/Terminal.Gui.PowerShell.Core.psd1
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ PrivateData = @{
# Tags = @()

# A URL to the license for this module.
LicenseUri = 'https://github.com/gui-cs/Terminal.Gui/tree/v2_develop/Scripts/COPYRIGHT'
LicenseUri = 'https://github.com/gui-cs/Terminal.Gui/tree/develop/Scripts/COPYRIGHT'

# A URL to the main website for this project.
ProjectUri = 'https://github.com/gui-cs/Terminal.Gui'
Expand Down
Loading
Loading