Giter Site home page Giter Site logo

sil.buildtasks's Issues

Replacement verification fails if ReplacementText contains match group syntax

Although the code does a Regex.Replace, which should allow for the ReplacementText to specify a regex replacement (e.g., with group numbers or names), the verification code does not consider whether there were any matches but merely checks to see whether the resulting string contains the literal ReplacementText string. If it doesn't, it reports failure and does not save the file.

`SetReleaseNotesProperty` will catch the version link section for the first published version

Consider I have the following CHANGELOG.md:

# Changelog
All notable changes to this project will be documented in this file.

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

## [0.0.1] - 2021-03-21
### Added
- Password authentication: `MatrixClient.Login`
- Reactive event sync: `MatrixClient.StartEventPolling`

[0.0.1]: https://github.com/ForNeVeR/Smith.MatrixSdk/releases/tag/v0.0.1
[Unreleased]: https://github.com/ForNeVeR/Smith.MatrixSdk/compare/v0.0.1...HEAD

After publishing the first release, my changelog inside of a NuGet package will contain the following:

Added:
- Password authentication: `MatrixClient.Login`
- Reactive event sync: `MatrixClient.StartEventPolling`

[0.0.1]: https://github.com/ForNeVeR/Smith.MatrixSdk/releases/tag/v0.0.1
[Unreleased]: https://github.com/ForNeVeR/Smith.MatrixSdk/compare/v0.0.1...HEAD

However, the link section is unwanted in the package.

Probably, we could detect its existence and exclude it automatically from the first build?

[SetReleaseNotesProperty] Release notes include closing tag of comment

If the CHANGELOG.md file contains a comment at the top, e.g.

<!-- comment
-->

## [Unreleased]

### Added

- [MyProject1] Add 'DoSomething()' method to 'Foo'

the closing tag of the comment will show up in the release notes if the entries are filtered:

-->
Changes since version 2.4.0

Added:
- Add 'DoSomething()' method to 'Foo'

I added ignored tests in db6802f.

Add filter option for project-specific entries to SetReleaseNotesProperty task

Summary

This new feature adds a filter option to the SetReleaseNotesProperty task which allows to filter out any entries that don't belong to a specific nuget package. To achieve this we add a new property FilterEntries that controls whether or not the new feature is enabled for a project.

Specification

  • the user can set the FilterEntries property in his .csproj file. If the property value evaluates true, the new filter option is
    enabled. If it evaluates to false or the property is not set, the filter option is disabled. This is the behavior that's implemented
    in version<= 2.5.0.
  • if the filter option is enabled, only entries without a tag or with a tag matching the current project are output. The tag itself is stripped off.
  • if the filter option is disabled, all entries are output.

Examples

CHANGELOG.md file

Given the following snippet of a CHANGELOG.md file:

...
## [Unreleased]

## [2.5.0] - 2021-02-22

### Added

- [MyProject1] Add `DoSomething()` method to `Foo`
- `ReadMe.md` Lorem ipsem

### Fixed

- [Some.OtherProject] Fix crash in `FooBar`

## [2.4.0] - 2021-01-22
...

Filter option enabled

If MyProject1.csproj sets the FilterEntries property:

<Project Sdk="Microsoft.NET.Sdk">
	<PropertyGroup>
            ...
		<FilterEntries>true</FilterEntries>
            ...
	</PropertyGroup>
        ...
</Project>

then the ReleaseNotesProperty will contain the following when building version 2.4.0 of MyProject1:

Changes since version 2.4.0

Added:
- Add `DoSomething()` method to `Foo`
- `ReadMe.md` Lorem ipsem

If likewise Some.Project.csproj sets FilterEntries and creates a nuget package Some.OtherProject (PackageId property):

<Project Sdk="Microsoft.NET.Sdk">
	<PropertyGroup>
            ...
		<FilterEntries>true</FilterEntries>
		<PackageId>Some.OtherProject</PackageId>
            ...
	</PropertyGroup>
        ...
</Project>

The output would be for Some.OtherProject:

Changes since version 2.4.0

Added:
- `ReadMe.md` Lorem ipsem

Fixed:
- Fix crash in `FooBar`

Filter option disabled

If neither project sets the FilterEntries property, the output would be identical for both projects:

Changes since version 2.4.0

Added:
- [MyProject1] Add `DoSomething()` method to `Foo`
- `ReadMe.md` Lorem ipsem

Fixed:
- [Some.OtherProject] Fix crash in `FooBar`

ToDo

  • implement filter option
  • add unit tests
  • update documentation
  • update changelog
  • mention +semver:minor in commit message

Log messages are lost

The logging in MakeWixForDirTree just puts out "High", "Normal" and "Low". The actual message is lost. Makes for pretty useless logging. See an example here.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.