Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Microsoft.AspNetCore.BuildTools.ApiCheck to builds #205

Closed
wants to merge 15 commits into from

Commits on Mar 24, 2017

  1. Add Microsoft.AspNetCore.BuildTools.ApiCheck to builds

    - aspnet/KoreBuild#143
    
    Add Microsoft.AspNetCore.BuildTools.ApiCheck.Task project
      - include task assembly in the Microsoft.AspNetMicrosoft.AspNetCore.BuildTools.ApiCheck package
      - add *.props and *.targets files to hook task into `Pack` target; runs just before .nupkg is created
    - reference Microsoft.AspNetMicrosoft.AspNetCore.BuildTools.ApiCheck project from the Sdk project
      - requires lots of hacks; dotnet/sdk#939 workarounds fail in this scenario
    
    Fall back to `RuntimeTargets` when `RuntimeAssemblies` yields no assemblies
    
    Improve project-to-project reference and native assembly handling
    - avoid `FileNotFoundException` in `AssemblyLoadContext.GetAssemblyName()` due to `\placeholder\` paths
    - catch and ignore `BadImageFormatException` in `AssemblyLoadContext.GetAssemblyName()`
    - avoid `InvalidOperationException` in `PackageGraph.RuntimeIsCompatible()` due to missing .sha512 file
    
    Change ApiCheck.exe's options and output
    - add `api-check --compact-output` option
    - generally make tool's output more useful to the task
      - catch and log `FileNotFoundException`; output types and stack traces of caught `Exception`s
    - remove `--framework` option; unused in .NET Framework already
    - change ApiCheck.exe option from `--ApiListing` to `--api-listing` for consistency w/ other options
    
    nits:
    - remove `PackageGraph.RuntimeIsCompatible()` `candidateRuntime` parameter
      - not needed and confusingly-named; passed value included in `compatibleRuntimes`
    - update solution to use current project type GUID
    - ignore global.json and launchSettings.json
    - make some Linq a bit more readable
    - whitespace and `using` cleanup
    - move all property groups above item groups in Microsoft.AspNetMicrosoft.AspNetCore.BuildTools.ApiCheck.csproj
    - make a couple of constructors `private`; used only in `public static` methods
    - ignore case a bit more
    
    notes:
    - don't use `UseCommandProcessor==true`; `ToolTask` writes out .cmd file with a BOM that cmd.exe hates
    dougbu committed Mar 24, 2017
    Configuration menu
    Copy the full SHA
    3971392 View commit details
    Browse the repository at this point in the history
  2. Use DotNetMuxer

    dougbu committed Mar 24, 2017
    Configuration menu
    Copy the full SHA
    d9f2b91 View commit details
    Browse the repository at this point in the history
  3. Make versions consistent for Microsoft dependencies

    - everything should now be using `NETStandard.Library` v1.6.1, CoreFx packages v4.3.0, etc.
    - remove duplicate `<PropertyGroup>` from `NugetReferenceResolver` project
    - add two dependencies to `BuildTools.Tasks.Tests` project to avoid package downgrade warnings
    dougbu committed Mar 24, 2017
    Configuration menu
    Copy the full SHA
    77e856e View commit details
    Browse the repository at this point in the history
  4. Use Exception.ToString()

    dougbu committed Mar 24, 2017
    Configuration menu
    Copy the full SHA
    83fd1a8 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    09625a3 View commit details
    Browse the repository at this point in the history
  6. Bump ApiCheck package version

    dougbu committed Mar 24, 2017
    Configuration menu
    Copy the full SHA
    ad3b9f5 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    05e1df9 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    a4b0ce5 View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    46c6743 View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    84d976f View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    d360953 View commit details
    Browse the repository at this point in the history
  12. Configuration menu
    Copy the full SHA
    1174dc7 View commit details
    Browse the repository at this point in the history
  13. Use Microsoft.Extensions.CommandLineUtils.Sources package

    - VersionTool project cannot do this because it has `public` properties of these `internal` types
      - just sorted the dependencies
    - will file a separate issue to make those properties `internal` if possible; probably low-pri
    dougbu committed Mar 24, 2017
    Configuration menu
    Copy the full SHA
    42ef4b6 View commit details
    Browse the repository at this point in the history
  14. Use restored --framework option in ApiCheckTask; other cleanup

    - don't change default: `$(NetStandardImplicitPackageVersion)` -> `$(NetStandardPackageVersion)`
    - don't use `$(IsPackable)` in a condition; redundant and may block direct use of the `ApiCheck` target
    dougbu committed Mar 24, 2017
    Configuration menu
    Copy the full SHA
    76eba60 View commit details
    Browse the repository at this point in the history
  15. Configuration menu
    Copy the full SHA
    150106a View commit details
    Browse the repository at this point in the history