diff --git a/NStack/NStack.csproj b/NStack/NStack.csproj index 2430313..5934263 100644 --- a/NStack/NStack.csproj +++ b/NStack/NStack.csproj @@ -26,34 +26,7 @@ It starts with a new string type that is focused on Unicode code-points as opposed to the historical chars and UTF-16 encoding and introduces a utf8 string that supports slicing - Version 1.0.5 - * Fixes #83. Ustring ConsoleWidth must return the exactly character size or zero and not Rune.ColumnWidth - - Version 1.0.3 - * Fixes #79. Needed to add unit test for equal and not equal operators. - - Version 1.0.1 - Moderinized API doc generation and now using gitflow - * Fixes #59. Automatically generate API docs via github action - * Fixes #61. ustring.IsNullOrEmpty doesn't work the same way as the string.IsNullOrEmpty method. - - Previous Versions: - 0.17: Fork by @tig modernize build/deploy and help publishing newer versions. No functional changes. - 0.16: Fixes issue #51 (chess symbols); - 0.15: Fixes to MaxRune; ColumnWidth differentiates between non-printable and nul characters; Rune has a constructor from two surrogate pairs; contributions by @BDisp; - 0.14: Upgrade the NetStandard dependencies; - 0.13: Fixes ustring.Map() and Lower(); Extends Rune.IsValid to match Go; add Rune.ExpectedSizeFromFirstByte() plus a bug fix; - stack - 0.12: Rebuild with an older Roslyn, to prevent regressions on Xamarin. - 0.10: Merged some changes from upstream. - - 0.9: - Added ustring.ColumnWidth to return number of columns that a ustring takes in a console. - - 0.8: - * Renamed some methods to match the equivalent methods in Char. - * Introduced Substring (int start) - * Introduced difference between this [int start, int end] and this [int start, object end] the latter used to mean "until the end", replacing '0' as the previous value for "until the end". - * Introduced new method in Rune to measure the width in columns for console applications. + See https://github.com/gui-cs/NStack/releases diff --git a/NStack/README.md b/NStack/README.md new file mode 100644 index 0000000..8881df3 --- /dev/null +++ b/NStack/README.md @@ -0,0 +1,125 @@ +# Build & Deploy + +## Regenerating Tables when the Unicode standard is updated + +To regenerate the Tables.cs file from the reference unicode files, run `Makefile` +with the command `make tables`, which will create the updated tables. + +There is some work to be done to dump the tables as a binary blob, +without going through the various data structures that we have now, it would +avoid all these constructors triggered on the static class. + +## Version Numbers + +Version info for NStack is managed by [gitversion](https://gitversion.net). + +Install `gitversion`: + +```powershell +dotnet tool install --global GitVersion.Tool +dotnet-gitversion +``` + +The project version (the nuget package and in `NStack.dll`) is determined from the latest `git tag`. + +The format of version numbers is `vmajor.minor.patch.build.height` and follows the [Semantic Versioning](https://semver.org/) rules. + +To define a new version (e.g. with a higher `major`, `minor`, `patch`, or `build` value) tag a commit using `git tag`: + +```powershell +git tag v1.3.4-beta.5 -a -m "Release v1.3.4 Beta 5" +dotnet-gitversion /updateprojectfiles +dotnet build -c Release +``` + +**DO NOT COMMIT AFTER USING `/updateprojectfiles`!** + +Doing so will update the `.csproj` files in your branch with version info, which we do not want. + +## Deploying a new version of the NStack Nuget Library + +To release a new version (e.g. with a higher `major`, `minor`, or `patch` value) tag a commit using `git tag` and then +push that tag directly to the `main` branch on `github.com/gui-cs/NStack` (`upstream`). + +The `tag` must be of the form `v..`, e.g. `v2.3.4`. + +`patch` can indicate pre-release or not (e.g. `pre`, `beta`, `rc`, etc...). + +### 1) Verify the `develop` branch is ready for release + +* Ensure everything is committed and pushed to the `develop` branch +* Ensure your local `develop` branch is up-to-date with `upstream/develop` + +### 2) Create a pull request for the release in the `develop` branch + +The PR title should be of the form "Release v2.3.4" + +```powershell +git checkout develop +git pull upstream develop +git checkout -b v_2_3_4 +git merge develop +git add . +git commit -m "Release v2.3.4" +git push +``` + +Go to the link printed by `git push` and fill out the Pull Request. + +### 3) On github.com, verify the build action worked on your fork, then merge the PR + +### 4) Pull the merged `develop` from `upstream` + +```powershell +git checkout develop +git pull upstream develop +``` + +### 5) Merge `develop` into `main` + +```powershell +git checkout main +git pull upstream main +git merge develop +``` + +Fix any merge errors. + +### 6) Create a new annotated tag for the release on `main` + +```powershell +git tag v2.3.4 -a -m "Release v2.3.4" +``` + +### 7) Push the new tag to `main` on `upstream` + +```powershell +git push --atomic upstream main v2.3.4 +``` + +*See https://stackoverflow.com/a/3745250/297526* + +### 8) Monitor Github Actions to ensure the Nuget publishing worked. + +https://github.com/gui-cs/Terminal.Gui/actions + +### 9) Check Nuget to see the new package version (wait a few minutes) +https://www.nuget.org/packages/Terminal.Gui + +### 10) Add a new Release in Github: https://github.com/gui-cs/Terminal.Gui/releases + +Generate release notes with the list of PRs since the last release + +Use `gh` to get a list with just titles to make it easy to paste into release notes: + +```powershell +gh pr list --limit 500 --search "is:pr is:closed is:merged closed:>=2021-05-18" +``` +### 11) Update the `develop` branch with the new version + +```powershell +git checkout develop +git pull upstream develop +git merge main +git push upstream develop +``` diff --git a/NStack/demo.md b/NStack/demo.md deleted file mode 100644 index ef7301a..0000000 --- a/NStack/demo.md +++ /dev/null @@ -1,6 +0,0 @@ -# Hello - -This is a text file - -## Second level - diff --git a/NStack/unicode/README.md b/NStack/unicode/README.md deleted file mode 100644 index e2198fa..0000000 --- a/NStack/unicode/README.md +++ /dev/null @@ -1,6 +0,0 @@ -To regenerate the Tables.cs file from the reference unicode files, execute the Makefile -with the command `make tables`, which will dump the updated tables: - -There is some work to be done to dump the tables as a binary blob, -without going through the various data structures that we have now, it would -avoid all these constructors triggered on the static class. \ No newline at end of file diff --git a/README.md b/README.md index 30db768..428c92d 100644 --- a/README.md +++ b/README.md @@ -34,29 +34,3 @@ can exist without them being valid UTF8 strings, but rather a collection of byte a particular character set and are effectively not possible to map into strings. -# Version Numbers - -Version info for NStack is managed by [gitversion](https://gitversion.net). - -Install `gitversion`: - -```powershell -dotnet tool install --global GitVersion.Tool -dotnet-gitversion -``` - -The project version (the nuget package and in `NStack.dll`) is determined from the latest `git tag`. - -The format of version numbers is `vmajor.minor.patch.build.height` and follows the [Semantic Versioning](https://semver.org/) rules. - -To define a new version (e.g. with a higher `major`, `minor`, `patch`, or `build` value) tag a commit using `git tag`: - -```powershell -git tag v1.3.4-beta.5 -a -m "Release v1.3.4 Beta 5" -dotnet-gitversion /updateprojectfiles -dotnet build -c Release -``` - -**DO NOT COMMIT AFTER USING `/updateprojectfiles`!** - -Doing so will update the `.csproj` files in your branch with version info, which we do not want.