miniscaffold-docs-test-3
[Enter useful description for miniscaffold-docs-test-3]
Builds
macOS/Linux | Windows |
---|---|
NuGet
Package | Stable | Prerelease |
---|---|---|
miniscaffold-docs-test-3 |
Developing
Make sure the following requirements are installed on your system:
- dotnet SDK 3.0 or higher
- Mono if you're on Linux or macOS.
or
Environment Variables
CONFIGURATION
will set the configuration of the dotnet commands. If not set, it will default to Release.CONFIGURATION=Debug ./build.sh
will result in-c
additions to commands such as indotnet build -c Debug
GITHUB_TOKEN
will be used to upload release notes and Nuget packages to GitHub.- Be sure to set this before releasing
DISABLE_COVERAGE
Will disable running code coverage metrics. AltCover can have severe performance degradation so it's worth disabling when looking to do a quicker feedback loop.DISABLE_COVERAGE=1 ./build.sh
Building
> build.cmd <optional buildtarget> // on windows
$ ./build.sh <optional buildtarget>// on unix
The bin of your library should look similar to:
$ tree src/MyCoolNewLib/bin/
src/MyCoolNewLib/bin/
└── Debug
├── net461
│ ├── FSharp.Core.dll
│ ├── MyCoolNewLib.dll
│ ├── MyCoolNewLib.pdb
│ ├── MyCoolNewLib.xml
└── netstandard2.1
├── MyCoolNewLib.deps.json
├── MyCoolNewLib.dll
├── MyCoolNewLib.pdb
└── MyCoolNewLib.xml
Build Targets
Clean
- Cleans artifact and temp directories.DotnetRestore
- Runs dotnet restore on the solution file.DotnetBuild
- Runs dotnet build on the solution file.DotnetTest
- Runs dotnet test on the solution file.GenerateCoverageReport
- Code coverage is run duringDotnetTest
and this generates a report via ReportGenerator.WatchTests
- Runs dotnet watch with the test projects. Useful for rapid feedback loops.GenerateAssemblyInfo
- Generates AssemblyInfo for libraries.DotnetPack
- Runs dotnet pack. This includes running Source Link.SourceLinkTest
- Runs a Source Link test tool to verify Source Links were properly generated.PublishToNuGet
- Publishes the NuGet packages generated inDotnetPack
to NuGet via paket push.GitRelease
- Creates a commit message with the Release Notes and a git tag via the version in theRelease Notes
.GitHubRelease
- Publishes a GitHub Release with the Release Notes and any NuGet packages.FormatCode
- Runs Fantomas on the solution file.BuildDocs
- Generates Documentation fromdocsSrc
and the XML Documentation Comments from your libraries insrc
.WatchDocs
- Generates documentation and starts a webserver locally. It will rebuild and hot reload if it detects any changes made todocsSrc
files, libraries insrc
, or thedocsTool
itself.ReleaseDocs
- Will stage, commit, and push docs generated in theBuildDocs
target.Release
- Task that runs all release type tasks such asPublishToNuGet
,GitRelease
,ReleaseDocs
, andGitHubRelease
. Make sure to read Releasing to setup your environment correctly for releases.
Releasing
git add .
git commit -m "Scaffold"
git remote add origin https://github.com/user/MyCoolNewLib.git
git push -u origin master
paket config add-token "https://www.nuget.org" 4003d786-cc37-4004-bfdf-c4f3e8ef9b3a
-
- You can then set the
GITHUB_TOKEN
to upload release notes and artifacts to github - Otherwise it will fallback to username/password
- You can then set the
-
Then update the
CHANGELOG.md
and add a new header with a version number and date just under the "Unreleased" header, in KeepAChangelog format. Don't forget to make the version number a link and update the link reference section at the bottom of the file, too. E.g., change this:
## Unreleased
### Added
- FEATURE: Does cool stuff!
### Fixed
- BUGFIX: Fixes that silly oversight
## [0.1.0] - 2017-03-17
First release
### Added
- This release already has lots of features
[0.1.0]: https://github.com/user/MyCoolNewLib.git/releases/tag/v0.1.0
to this:
## Unreleased
## [0.2.0] - 2017-04-20
### Added
- FEATURE: Does cool stuff!
### Fixed
- BUGFIX: Fixes that silly oversight
## [0.1.0] - 2017-03-17
First release
### Added
- This release already has lots of features
[0.2.0]: https://github.com/user/MyCoolNewLib.git/compare/v0.1.0...v0.2.0
[0.1.0]: https://github.com/user/MyCoolNewLib.git/releases/tag/v0.1.0
- You can then use the
Release
target. This will:- make a commit bumping the version:
Bump version to 0.2.0
and add the changelog to the commit - publish the package to NuGet
- push a git tag
- make a commit bumping the version:
./build.sh Release