From 3c17f127fd130ac103ed5f7b71ac20d88f0685b3 Mon Sep 17 00:00:00 2001 From: Daniel Wertheim Date: Mon, 6 Jan 2020 20:10:57 +0100 Subject: [PATCH] Replaces Cake with AZ-Pipeline using YAML and moves projects (#9) --- .editorconfig | 12 + .gitignore | 20 +- README.md | 4 + ReleaseNotes.md | 3 + azure-pipelines-cd.yml | 20 ++ azure-pipelines-ci.yml | 24 ++ azure-templates/stage-build.yml | 42 ++++ azure-templates/stage-deploy.yml | 23 ++ build.cake | 85 ------- build.ps1 | 235 ------------------ buildconfig.cake | 33 --- src/Directory.Build.props | 21 +- src/{samples => }/Sample/Order.cs | 0 src/{samples => }/Sample/OrderLine.cs | 0 src/{samples => }/Sample/OrderStatus.cs | 0 src/{samples => }/Sample/Program.cs | 0 src/{samples => }/Sample/Prop.cs | 0 src/{samples => }/Sample/Sample.csproj | 4 +- src/Structurizer.sln | 40 +-- .../Configuration/StructureTypeConfig.cs | 0 .../StructureTypeConfigurations.cs | 0 .../StructureTypeConfigurator.cs | 0 .../Structurizer/DataTypeCode.cs | 0 .../Structurizer/DataTypeConverter.cs | 0 .../Extensions/ExpressionExtensions.cs | 0 .../Structurizer/Extensions/TypeExtensions.cs | 0 .../Structurizer/FlexibleStructureBuilder.cs | 0 .../Structurizer/IDataTypeConverter.cs | 0 .../Structurizer/IIndexAccessor.cs | 0 src/{projects => }/Structurizer/IStructure.cs | 0 .../Structurizer/IStructureBuilder.cs | 0 .../Structurizer/IStructureIndex.cs | 0 .../Structurizer/IStructureIndexValue.cs | 0 .../Structurizer/IStructureIndexesFactory.cs | 0 .../Structurizer/IStructureProperty.cs | 0 .../Structurizer/IStructurePropertyFactory.cs | 0 .../Structurizer/IStructureSchema.cs | 0 .../Structurizer/IStructureSchemaFactory.cs | 0 .../Structurizer/IStructureType.cs | 0 .../Structurizer/IStructureTypeConfig.cs | 0 .../IStructureTypeConfigurations.cs | 0 .../IStructureTypeConfigurator.cs | 0 .../Structurizer/IStructureTypeFactory.cs | 0 .../Structurizer/IStructureTypeReflecter.cs | 0 src/{projects => }/Structurizer/IndexMode.cs | 0 .../Structurizer/Schemas/DynamicGetter.cs | 0 .../Schemas/DynamicPropertyFactory.cs | 0 .../Structurizer/Schemas/IndexAccessor.cs | 0 .../Schemas/PropertyPathBuilder.cs | 0 .../Structurizer/Schemas/StructureProperty.cs | 0 .../Schemas/StructurePropertyCallstack.cs | 0 .../Schemas/StructurePropertyFactory.cs | 0 .../Schemas/StructurePropertyFactoryRules.cs | 0 .../Schemas/StructurePropertyInfo.cs | 0 .../Structurizer/Schemas/StructureSchema.cs | 0 .../Structurizer/Schemas/StructureType.cs | 0 .../Schemas/StructureTypeReflecter.cs | 0 src/{projects => }/Structurizer/Structure.cs | 0 .../Structurizer/StructureBuilder.cs | 0 .../Structurizer/StructureIndex.cs | 0 .../Structurizer/StructureIndexValue.cs | 0 .../Structurizer/StructureIndexesFactory.cs | 0 .../Structurizer/StructureSchemaFactory.cs | 0 .../Structurizer/StructureTypeFactory.cs | 0 src/Structurizer/Structurizer.csproj | 19 ++ .../Structurizer/StructurizerException.cs | 0 .../StructurizerExceptionMessages.cs | 0 .../Configuration/StructureTypeConfigTests.cs | 0 .../StructureTypeConfigurationsTests.cs | 0 .../StructureTypeConfiguratorTests.cs | 0 .../UnitTests/DataTypeCodeTests.cs | 0 .../FlexibleStructureBuilderTests.cs | 0 .../Schemas/DataTypeConverterTests.cs | 0 .../Schemas/IndexAccessorTestFactory.cs | 0 .../IndexAccessorGetValuesOnDeepGraphTests.cs | 0 .../IndexAccessorGetValuesOnSubItemTests.cs | 0 .../IndexAccessorGetValuesTests.cs | 0 .../Schemas/PropertyPathBuilderTests.cs | 0 .../Schemas/StructurePropertyTestFactory.cs | 0 .../StructurePropertyAttributesTests.cs | 0 .../StructurePropertyEnumerableTests.cs | 0 .../StructurePropertyGetGuidValueTests.cs | 0 .../StructurePropertyGetIdentityValueTests.cs | 0 ...StructurePropertyGetPrimitiveValueTests.cs | 0 .../StructurePropertyGetStringValueTests.cs | 0 .../Schemas/StructureSchemaFactoryTests.cs | 0 .../UnitTests/Schemas/StructureSchemaTests.cs | 0 .../Schemas/StructureTypeFactoryTests.cs | 0 ...eflecterComplexIndexablePropertiesTests.cs | 0 ...ecterEnumerableIndexablePropertiesTests.cs | 0 ...lecterGetIndexablePropertiesExceptTests.cs | 0 ...cterGetSpecificIndexablePropertiesTests.cs | 0 ...ReflecterSimpleIndexablePropertiesTests.cs | 0 .../StructureTypeReflecterTestsBase.cs | 0 .../StructureBuilderBaseTests.cs | 0 .../StructureBuilderEnumerableTests.cs | 0 .../StructureBuilderGraphTests.cs | 0 .../StructureBuilderIncludeAndExcludeTests.cs | 0 .../StructureBuilderNullablesTests.cs | 0 .../StructureBuilderTests.cs | 0 .../UnitTests/StructureIndexesFactoryTests.cs | 0 .../UnitTests/StructureSchemaTestFactory.cs | 0 .../UnitTests/StructureTypeTestFactory.cs | 0 src/{tests => }/UnitTests/UnitTests.cs | 0 src/UnitTests/UnitTests.csproj | 21 ++ src/projects/Structurizer/Structurizer.csproj | 28 --- src/tests/UnitTests/UnitTests.csproj | 21 -- tools/packages.config | 4 - 108 files changed, 209 insertions(+), 450 deletions(-) create mode 100644 .editorconfig create mode 100644 azure-pipelines-cd.yml create mode 100644 azure-pipelines-ci.yml create mode 100644 azure-templates/stage-build.yml create mode 100644 azure-templates/stage-deploy.yml delete mode 100644 build.cake delete mode 100644 build.ps1 delete mode 100644 buildconfig.cake rename src/{samples => }/Sample/Order.cs (100%) rename src/{samples => }/Sample/OrderLine.cs (100%) rename src/{samples => }/Sample/OrderStatus.cs (100%) rename src/{samples => }/Sample/Program.cs (100%) rename src/{samples => }/Sample/Prop.cs (100%) rename src/{samples => }/Sample/Sample.csproj (57%) rename src/{projects => }/Structurizer/Configuration/StructureTypeConfig.cs (100%) rename src/{projects => }/Structurizer/Configuration/StructureTypeConfigurations.cs (100%) rename src/{projects => }/Structurizer/Configuration/StructureTypeConfigurator.cs (100%) rename src/{projects => }/Structurizer/DataTypeCode.cs (100%) rename src/{projects => }/Structurizer/DataTypeConverter.cs (100%) rename src/{projects => }/Structurizer/Extensions/ExpressionExtensions.cs (100%) rename src/{projects => }/Structurizer/Extensions/TypeExtensions.cs (100%) rename src/{projects => }/Structurizer/FlexibleStructureBuilder.cs (100%) rename src/{projects => }/Structurizer/IDataTypeConverter.cs (100%) rename src/{projects => }/Structurizer/IIndexAccessor.cs (100%) rename src/{projects => }/Structurizer/IStructure.cs (100%) rename src/{projects => }/Structurizer/IStructureBuilder.cs (100%) rename src/{projects => }/Structurizer/IStructureIndex.cs (100%) rename src/{projects => }/Structurizer/IStructureIndexValue.cs (100%) rename src/{projects => }/Structurizer/IStructureIndexesFactory.cs (100%) rename src/{projects => }/Structurizer/IStructureProperty.cs (100%) rename src/{projects => }/Structurizer/IStructurePropertyFactory.cs (100%) rename src/{projects => }/Structurizer/IStructureSchema.cs (100%) rename src/{projects => }/Structurizer/IStructureSchemaFactory.cs (100%) rename src/{projects => }/Structurizer/IStructureType.cs (100%) rename src/{projects => }/Structurizer/IStructureTypeConfig.cs (100%) rename src/{projects => }/Structurizer/IStructureTypeConfigurations.cs (100%) rename src/{projects => }/Structurizer/IStructureTypeConfigurator.cs (100%) rename src/{projects => }/Structurizer/IStructureTypeFactory.cs (100%) rename src/{projects => }/Structurizer/IStructureTypeReflecter.cs (100%) rename src/{projects => }/Structurizer/IndexMode.cs (100%) rename src/{projects => }/Structurizer/Schemas/DynamicGetter.cs (100%) rename src/{projects => }/Structurizer/Schemas/DynamicPropertyFactory.cs (100%) rename src/{projects => }/Structurizer/Schemas/IndexAccessor.cs (100%) rename src/{projects => }/Structurizer/Schemas/PropertyPathBuilder.cs (100%) rename src/{projects => }/Structurizer/Schemas/StructureProperty.cs (100%) rename src/{projects => }/Structurizer/Schemas/StructurePropertyCallstack.cs (100%) rename src/{projects => }/Structurizer/Schemas/StructurePropertyFactory.cs (100%) rename src/{projects => }/Structurizer/Schemas/StructurePropertyFactoryRules.cs (100%) rename src/{projects => }/Structurizer/Schemas/StructurePropertyInfo.cs (100%) rename src/{projects => }/Structurizer/Schemas/StructureSchema.cs (100%) rename src/{projects => }/Structurizer/Schemas/StructureType.cs (100%) rename src/{projects => }/Structurizer/Schemas/StructureTypeReflecter.cs (100%) rename src/{projects => }/Structurizer/Structure.cs (100%) rename src/{projects => }/Structurizer/StructureBuilder.cs (100%) rename src/{projects => }/Structurizer/StructureIndex.cs (100%) rename src/{projects => }/Structurizer/StructureIndexValue.cs (100%) rename src/{projects => }/Structurizer/StructureIndexesFactory.cs (100%) rename src/{projects => }/Structurizer/StructureSchemaFactory.cs (100%) rename src/{projects => }/Structurizer/StructureTypeFactory.cs (100%) create mode 100644 src/Structurizer/Structurizer.csproj rename src/{projects => }/Structurizer/StructurizerException.cs (100%) rename src/{projects => }/Structurizer/StructurizerExceptionMessages.cs (100%) rename src/{tests => }/UnitTests/Configuration/StructureTypeConfigTests.cs (100%) rename src/{tests => }/UnitTests/Configuration/StructureTypeConfigurationsTests.cs (100%) rename src/{tests => }/UnitTests/Configuration/StructureTypeConfiguratorTests.cs (100%) rename src/{tests => }/UnitTests/DataTypeCodeTests.cs (100%) rename src/{tests => }/UnitTests/FlexibleStructureBuilderTests.cs (100%) rename src/{tests => }/UnitTests/Schemas/DataTypeConverterTests.cs (100%) rename src/{tests => }/UnitTests/Schemas/IndexAccessorTestFactory.cs (100%) rename src/{tests => }/UnitTests/Schemas/MemberAccessors/IndexAccessorGetValuesOnDeepGraphTests.cs (100%) rename src/{tests => }/UnitTests/Schemas/MemberAccessors/IndexAccessorGetValuesOnSubItemTests.cs (100%) rename src/{tests => }/UnitTests/Schemas/MemberAccessors/IndexAccessorGetValuesTests.cs (100%) rename src/{tests => }/UnitTests/Schemas/PropertyPathBuilderTests.cs (100%) rename src/{tests => }/UnitTests/Schemas/StructurePropertyTestFactory.cs (100%) rename src/{tests => }/UnitTests/Schemas/StructurePropertyTests/StructurePropertyAttributesTests.cs (100%) rename src/{tests => }/UnitTests/Schemas/StructurePropertyTests/StructurePropertyEnumerableTests.cs (100%) rename src/{tests => }/UnitTests/Schemas/StructurePropertyTests/StructurePropertyGetGuidValueTests.cs (100%) rename src/{tests => }/UnitTests/Schemas/StructurePropertyTests/StructurePropertyGetIdentityValueTests.cs (100%) rename src/{tests => }/UnitTests/Schemas/StructurePropertyTests/StructurePropertyGetPrimitiveValueTests.cs (100%) rename src/{tests => }/UnitTests/Schemas/StructurePropertyTests/StructurePropertyGetStringValueTests.cs (100%) rename src/{tests => }/UnitTests/Schemas/StructureSchemaFactoryTests.cs (100%) rename src/{tests => }/UnitTests/Schemas/StructureSchemaTests.cs (100%) rename src/{tests => }/UnitTests/Schemas/StructureTypeFactoryTests.cs (100%) rename src/{tests => }/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterComplexIndexablePropertiesTests.cs (100%) rename src/{tests => }/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterEnumerableIndexablePropertiesTests.cs (100%) rename src/{tests => }/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterGetIndexablePropertiesExceptTests.cs (100%) rename src/{tests => }/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterGetSpecificIndexablePropertiesTests.cs (100%) rename src/{tests => }/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterSimpleIndexablePropertiesTests.cs (100%) rename src/{tests => }/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterTestsBase.cs (100%) rename src/{tests => }/UnitTests/StructureBuilderTests/StructureBuilderBaseTests.cs (100%) rename src/{tests => }/UnitTests/StructureBuilderTests/StructureBuilderEnumerableTests.cs (100%) rename src/{tests => }/UnitTests/StructureBuilderTests/StructureBuilderGraphTests.cs (100%) rename src/{tests => }/UnitTests/StructureBuilderTests/StructureBuilderIncludeAndExcludeTests.cs (100%) rename src/{tests => }/UnitTests/StructureBuilderTests/StructureBuilderNullablesTests.cs (100%) rename src/{tests => }/UnitTests/StructureBuilderTests/StructureBuilderTests.cs (100%) rename src/{tests => }/UnitTests/StructureIndexesFactoryTests.cs (100%) rename src/{tests => }/UnitTests/StructureSchemaTestFactory.cs (100%) rename src/{tests => }/UnitTests/StructureTypeTestFactory.cs (100%) rename src/{tests => }/UnitTests/UnitTests.cs (100%) create mode 100644 src/UnitTests/UnitTests.csproj delete mode 100644 src/projects/Structurizer/Structurizer.csproj delete mode 100644 src/tests/UnitTests/UnitTests.csproj delete mode 100644 tools/packages.config diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 0000000..2fdef90 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,12 @@ +root = true + +[*] +end_of_line = crlf +insert_final_newline = true +indent_style = space + +[*.props, *.csproj, *.yml, *.json] +indent_size = 2 + +[*.cs] +indent_size = 4 diff --git a/.gitignore b/.gitignore index ab8a743..2c4ee81 100644 --- a/.gitignore +++ b/.gitignore @@ -1,9 +1,5 @@ -# node -node_modules/ - # vs .vs/ -[Aa]pp_[Dd]ata/ [Bb]in/ [D]ebug/ [Aa]rtifacts/ @@ -15,12 +11,6 @@ node_modules/ *.vssscc *.suo *.cache -project.lock.json - -# deploy -build/ -tools/** -!tools/packages.config # misc *~ @@ -29,11 +19,11 @@ tools/** *.orig *.pfx -# nuget -[Pp]ackages/ +# rider +.idea -# approvals# -*.received.txt +# vs-code +.vscode # resharper _ReSharper.* @@ -42,4 +32,4 @@ _ReSharper.* *.DotSettings.user #windows stuff -Thumbs.db \ No newline at end of file +Thumbs.db diff --git a/README.md b/README.md index b057428..f549393 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,8 @@ # Structurizer +[![NuGet](https://img.shields.io/nuget/v/structurizer.svg?cacheSeconds=3600)](https://www.nuget.org/packages/structurizer) +[![License MIT](https://img.shields.io/badge/License-MIT-blue.svg)](https://choosealicense.com/licenses/mit/) +[![Build Status](https://dev.azure.com/danielwertheim/structurizer/_apis/build/status/danielwertheim.structurizer-CI?branchName=master)](https://dev.azure.com/danielwertheim/structurizer/_build/latest?definitionId=31&branchName=master) + Structurizer is extracted from one of my other projects [PineCone](https://github.com/danielwertheim/pinecone), which was used for much of the underlying indexing stuff for another project of mine, SisoDB. Structurizer is reduced to only manage a key-value representation of an object-graph. ## Release notes diff --git a/ReleaseNotes.md b/ReleaseNotes.md index 5ba8e38..578c1ac 100644 --- a/ReleaseNotes.md +++ b/ReleaseNotes.md @@ -1,5 +1,8 @@ #Release notes +## v4.0.1 +From this version release notes are kept in [each release](https://github.com/danielwertheim/structurizer/releases) on GitHub. + ## v4.0.0 - 2018-11-16 - *New*: .NET Standard 2.0 instead of .NET Standard 1.3. Also supports .NET4.5.1 for a while more. - *Changed*: Support for anonymous types passed as object. diff --git a/azure-pipelines-cd.yml b/azure-pipelines-cd.yml new file mode 100644 index 0000000..24ba528 --- /dev/null +++ b/azure-pipelines-cd.yml @@ -0,0 +1,20 @@ +name: $(SemVer) + +variables: + SemVer: $[ variables['Build.SourceBranchName'] ] + CommitId: $(Build.SourceVersion) + +trigger: + batch: true + branches: + include: + - refs/tags/* + +pr: none + +pool: + vmImage: windows-2019 + +stages: +- template: azure-templates/stage-build.yml +- template: azure-templates/stage-deploy.yml diff --git a/azure-pipelines-ci.yml b/azure-pipelines-ci.yml new file mode 100644 index 0000000..4e9f414 --- /dev/null +++ b/azure-pipelines-ci.yml @@ -0,0 +1,24 @@ +name: $(SemVer) + +variables: + BuildRev: $[counter(format('{0:yyyyMMdd}', pipeline.startTime), 1)] + SemVer: $[format('{0:yyyy}.{0:MM}.{0:dd}-pre{1}', pipeline.startTime, variables.BuildRev)] + CommitId: $(Build.SourceVersion) + +trigger: + batch: true + branches: + include: + - master + +pr: + autoCancel: true + branches: + include: + - master + +pool: + vmImage: windows-2019 + +stages: +- template: azure-templates/stage-build.yml diff --git a/azure-templates/stage-build.yml b/azure-templates/stage-build.yml new file mode 100644 index 0000000..fcdaf07 --- /dev/null +++ b/azure-templates/stage-build.yml @@ -0,0 +1,42 @@ +stages: +- stage: Build + jobs: + - job: BuildTestPack + displayName: 'Build, test & pack' + timeoutInMinutes: 5 + cancelTimeoutInMinutes: 2 + steps: + - task: UseDotNet@2 + displayName: 'Use .NET Core 3.1.x' + inputs: + version: '3.1.x' + packageType: sdk + + - task: DotNetCoreCLI@2 + displayName: 'Build Solution' + inputs: + command: build + projects: 'src/*.sln' + arguments: '-c $(BuildConfiguration) --no-incremental --nologo -p:TreatWarningsAsErrors=true -p:Version=$(SemVer) -p:InformationalVersion=$(CommitId)' + + - task: DotNetCoreCLI@2 + displayName: 'UnitTests' + inputs: + command: test + projects: 'src/**/UnitTests.csproj' + arguments: '-c $(BuildConfiguration) --no-build' + testRunTitle: 'UnitTests' + + - task: DotNetCoreCLI@2 + displayName: 'Pack Nupkg' + inputs: + command: custom + custom: pack + projects: 'src/*.sln' + arguments: '-c $(BuildConfiguration) --no-build -o $(Build.ArtifactStagingDirectory) -p:Version=$(SemVer) -p:InformationalVersion=$(CommitId)' + + - task: PublishPipelineArtifact@1 + displayName: 'Publish Artifacts' + inputs: + path: '$(Build.ArtifactStagingDirectory)' + artifact: Artifacts diff --git a/azure-templates/stage-deploy.yml b/azure-templates/stage-deploy.yml new file mode 100644 index 0000000..ce834fe --- /dev/null +++ b/azure-templates/stage-deploy.yml @@ -0,0 +1,23 @@ +stages: +- stage: Deploy + condition: and (succeeded(), startsWith( variables['Build.SourceBranch'], 'refs/tags' )) + dependsOn: Build + jobs: + - deployment: DeployArtifacts + environment: 'Prod' + displayName: 'Deploys artifacts' + timeoutInMinutes: 4 + cancelTimeoutInMinutes: 2 + strategy: + runOnce: + deploy: + steps: + - checkout: none + - task: NuGetCommand@2 + displayName: 'Push Nupkg to NuGet' + inputs: + command: push + nugetFeedType: external + publishFeedCredentials: nuget_push_new_versions + verbosityPush: Normal + packagesToPush: '$(Pipeline.Workspace)/**/*.nupkg;!$(Pipeline.Workspace)/**/*.symbols.nupkg' diff --git a/build.cake b/build.cake deleted file mode 100644 index 79fc504..0000000 --- a/build.cake +++ /dev/null @@ -1,85 +0,0 @@ -#load "./buildconfig.cake" - -var config = BuildConfig.Create(Context, BuildSystem); - -Information($"SrcDir: '{config.SrcDir}'"); -Information($"OutDir: '{config.OutDir}'"); -Information($"SemVer: '{config.SemVer}'"); -Information($"BuildVersion: '{config.BuildVersion}'"); -Information($"BuildProfile: '{config.BuildProfile}'"); -Information($"IsTeamCityBuild: '{config.IsTeamCityBuild}'"); - -Task("Default") - .IsDependentOn("InitOutDir") - .IsDependentOn("Restore") - .IsDependentOn("Build") - .IsDependentOn("UnitTests"); - -Task("CI") - .IsDependentOn("Default") - .IsDependentOn("Pack"); -/********************************************/ -Task("InitOutDir").Does(() => { - EnsureDirectoryExists(config.OutDir); - CleanDirectory(config.OutDir); -}); - -Task("Restore").Does(() => { - foreach(var sln in GetFiles($"{config.SrcDir}*.sln")) { - MSBuild(sln, settings => - settings - .SetConfiguration(config.BuildProfile) - .SetVerbosity(Verbosity.Minimal) - .WithTarget("Restore") - .WithProperty("TreatWarningsAsErrors", "true") - .WithProperty("Version", config.SemVer)); - } -}); - -Task("Build").Does(() => { - foreach(var sln in GetFiles($"{config.SrcDir}*.sln")) { - MSBuild(sln, settings => - settings - .SetConfiguration(config.BuildProfile) - .SetVerbosity(Verbosity.Minimal) - .WithTarget("Rebuild") - .WithProperty("TreatWarningsAsErrors", "true") - .WithProperty("NoRestore", "true") - .WithProperty("Version", config.SemVer) - .WithProperty("AssemblyVersion", config.BuildVersion) - .WithProperty("FileVersion", config.BuildVersion)); - } -}); - -Task("UnitTests").Does(() => { - var settings = new DotNetCoreTestSettings { - Configuration = config.BuildProfile, - NoBuild = true, - Logger = "console;verbosity=normal" - }; - foreach(var testProj in GetFiles($"{config.SrcDir}tests/**/UnitTests.csproj")) { - DotNetCoreTest(testProj.FullPath, settings); - } -}); - -Task("Pack").Does(() => { - DeleteFiles($"{config.SrcDir}projects/**/*.nupkg"); - - foreach(var proj in GetFiles($"{config.SrcDir}projects/**/*.csproj")) { - MSBuild(proj, settings => - settings - .SetConfiguration(config.BuildProfile) - .SetVerbosity(Verbosity.Minimal) - .WithTarget("Pack") - .WithProperty("TreatWarningsAsErrors", "true") - .WithProperty("NoRestore", "true") - .WithProperty("NoBuild", "true") - .WithProperty("Version", config.SemVer)); - } - - CopyFiles( - GetFiles($"{config.SrcDir}projects/**/*.nupkg"), - config.OutDir); -}); - -RunTarget(config.Target); \ No newline at end of file diff --git a/build.ps1 b/build.ps1 deleted file mode 100644 index 82529cf..0000000 --- a/build.ps1 +++ /dev/null @@ -1,235 +0,0 @@ -########################################################################## -# This is the Cake bootstrapper script for PowerShell. -# This file was downloaded from https://github.com/cake-build/resources -# Feel free to change this file to fit your needs. -########################################################################## - -<# - -.SYNOPSIS -This is a Powershell script to bootstrap a Cake build. - -.DESCRIPTION -This Powershell script will download NuGet if missing, restore NuGet tools (including Cake) -and execute your Cake build script with the parameters you provide. - -.PARAMETER Script -The build script to execute. -.PARAMETER Target -The build script target to run. -.PARAMETER Configuration -The build configuration to use. -.PARAMETER Verbosity -Specifies the amount of information to be displayed. -.PARAMETER ShowDescription -Shows description about tasks. -.PARAMETER DryRun -Performs a dry run. -.PARAMETER Experimental -Uses the nightly builds of the Roslyn script engine. -.PARAMETER Mono -Uses the Mono Compiler rather than the Roslyn script engine. -.PARAMETER SkipToolPackageRestore -Skips restoring of packages. -.PARAMETER ScriptArgs -Remaining arguments are added here. - -.LINK -https://cakebuild.net - -#> - -[CmdletBinding()] -Param( - [string]$Script = "build.cake", - [string]$Target, - [string]$Configuration, - [ValidateSet("Quiet", "Minimal", "Normal", "Verbose", "Diagnostic")] - [string]$Verbosity, - [switch]$ShowDescription, - [Alias("WhatIf", "Noop")] - [switch]$DryRun, - [switch]$Experimental, - [switch]$Mono, - [switch]$SkipToolPackageRestore, - [Parameter(Position=0,Mandatory=$false,ValueFromRemainingArguments=$true)] - [string[]]$ScriptArgs -) - -[Reflection.Assembly]::LoadWithPartialName("System.Security") | Out-Null -function MD5HashFile([string] $filePath) -{ - if ([string]::IsNullOrEmpty($filePath) -or !(Test-Path $filePath -PathType Leaf)) - { - return $null - } - - [System.IO.Stream] $file = $null; - [System.Security.Cryptography.MD5] $md5 = $null; - try - { - $md5 = [System.Security.Cryptography.MD5]::Create() - $file = [System.IO.File]::OpenRead($filePath) - return [System.BitConverter]::ToString($md5.ComputeHash($file)) - } - finally - { - if ($file -ne $null) - { - $file.Dispose() - } - } -} - -function GetProxyEnabledWebClient -{ - $wc = New-Object System.Net.WebClient - $proxy = [System.Net.WebRequest]::GetSystemWebProxy() - $proxy.Credentials = [System.Net.CredentialCache]::DefaultCredentials - $wc.Proxy = $proxy - return $wc -} - -Write-Host "Preparing to run build script..." - -if(!$PSScriptRoot){ - $PSScriptRoot = Split-Path $MyInvocation.MyCommand.Path -Parent -} - -$TOOLS_DIR = Join-Path $PSScriptRoot "tools" -$ADDINS_DIR = Join-Path $TOOLS_DIR "Addins" -$MODULES_DIR = Join-Path $TOOLS_DIR "Modules" -$NUGET_EXE = Join-Path $TOOLS_DIR "nuget.exe" -$CAKE_EXE = Join-Path $TOOLS_DIR "Cake/Cake.exe" -$NUGET_URL = "https://dist.nuget.org/win-x86-commandline/latest/nuget.exe" -$PACKAGES_CONFIG = Join-Path $TOOLS_DIR "packages.config" -$PACKAGES_CONFIG_MD5 = Join-Path $TOOLS_DIR "packages.config.md5sum" -$ADDINS_PACKAGES_CONFIG = Join-Path $ADDINS_DIR "packages.config" -$MODULES_PACKAGES_CONFIG = Join-Path $MODULES_DIR "packages.config" - -# Make sure tools folder exists -if ((Test-Path $PSScriptRoot) -and !(Test-Path $TOOLS_DIR)) { - Write-Verbose -Message "Creating tools directory..." - New-Item -Path $TOOLS_DIR -Type directory | out-null -} - -# Make sure that packages.config exist. -if (!(Test-Path $PACKAGES_CONFIG)) { - Write-Verbose -Message "Downloading packages.config..." - try { - $wc = GetProxyEnabledWebClient - $wc.DownloadFile("https://cakebuild.net/download/bootstrapper/packages", $PACKAGES_CONFIG) } catch { - Throw "Could not download packages.config." - } -} - -# Try find NuGet.exe in path if not exists -if (!(Test-Path $NUGET_EXE)) { - Write-Verbose -Message "Trying to find nuget.exe in PATH..." - $existingPaths = $Env:Path -Split ';' | Where-Object { (![string]::IsNullOrEmpty($_)) -and (Test-Path $_ -PathType Container) } - $NUGET_EXE_IN_PATH = Get-ChildItem -Path $existingPaths -Filter "nuget.exe" | Select -First 1 - if ($NUGET_EXE_IN_PATH -ne $null -and (Test-Path $NUGET_EXE_IN_PATH.FullName)) { - Write-Verbose -Message "Found in PATH at $($NUGET_EXE_IN_PATH.FullName)." - $NUGET_EXE = $NUGET_EXE_IN_PATH.FullName - } -} - -# Try download NuGet.exe if not exists -if (!(Test-Path $NUGET_EXE)) { - Write-Verbose -Message "Downloading NuGet.exe..." - try { - $wc = GetProxyEnabledWebClient - $wc.DownloadFile($NUGET_URL, $NUGET_EXE) - } catch { - Throw "Could not download NuGet.exe." - } -} - -# Save nuget.exe path to environment to be available to child processed -$ENV:NUGET_EXE = $NUGET_EXE - -# Restore tools from NuGet? -if(-Not $SkipToolPackageRestore.IsPresent) { - Push-Location - Set-Location $TOOLS_DIR - - # Check for changes in packages.config and remove installed tools if true. - [string] $md5Hash = MD5HashFile($PACKAGES_CONFIG) - if((!(Test-Path $PACKAGES_CONFIG_MD5)) -Or - ($md5Hash -ne (Get-Content $PACKAGES_CONFIG_MD5 ))) { - Write-Verbose -Message "Missing or changed package.config hash..." - Get-ChildItem -Exclude packages.config,nuget.exe,Cake.Bakery | - Remove-Item -Recurse - } - - Write-Verbose -Message "Restoring tools from NuGet..." - $NuGetOutput = Invoke-Expression "&`"$NUGET_EXE`" install -ExcludeVersion -OutputDirectory `"$TOOLS_DIR`"" - - if ($LASTEXITCODE -ne 0) { - Throw "An error occurred while restoring NuGet tools." - } - else - { - $md5Hash | Out-File $PACKAGES_CONFIG_MD5 -Encoding "ASCII" - } - Write-Verbose -Message ($NuGetOutput | out-string) - - Pop-Location -} - -# Restore addins from NuGet -if (Test-Path $ADDINS_PACKAGES_CONFIG) { - Push-Location - Set-Location $ADDINS_DIR - - Write-Verbose -Message "Restoring addins from NuGet..." - $NuGetOutput = Invoke-Expression "&`"$NUGET_EXE`" install -ExcludeVersion -OutputDirectory `"$ADDINS_DIR`"" - - if ($LASTEXITCODE -ne 0) { - Throw "An error occurred while restoring NuGet addins." - } - - Write-Verbose -Message ($NuGetOutput | out-string) - - Pop-Location -} - -# Restore modules from NuGet -if (Test-Path $MODULES_PACKAGES_CONFIG) { - Push-Location - Set-Location $MODULES_DIR - - Write-Verbose -Message "Restoring modules from NuGet..." - $NuGetOutput = Invoke-Expression "&`"$NUGET_EXE`" install -ExcludeVersion -OutputDirectory `"$MODULES_DIR`"" - - if ($LASTEXITCODE -ne 0) { - Throw "An error occurred while restoring NuGet modules." - } - - Write-Verbose -Message ($NuGetOutput | out-string) - - Pop-Location -} - -# Make sure that Cake has been installed. -if (!(Test-Path $CAKE_EXE)) { - Throw "Could not find Cake.exe at $CAKE_EXE" -} - - - -# Build Cake arguments -$cakeArguments = @("$Script"); -if ($Target) { $cakeArguments += "-target=$Target" } -if ($Configuration) { $cakeArguments += "-configuration=$Configuration" } -if ($Verbosity) { $cakeArguments += "-verbosity=$Verbosity" } -if ($ShowDescription) { $cakeArguments += "-showdescription" } -if ($DryRun) { $cakeArguments += "-dryrun" } -if ($Experimental) { $cakeArguments += "-experimental" } -if ($Mono) { $cakeArguments += "-mono" } -$cakeArguments += $ScriptArgs - -# Start Cake -Write-Host "Running build script..." -&$CAKE_EXE $cakeArguments -exit $LASTEXITCODE diff --git a/buildconfig.cake b/buildconfig.cake deleted file mode 100644 index c71aa47..0000000 --- a/buildconfig.cake +++ /dev/null @@ -1,33 +0,0 @@ -public class BuildConfig -{ - private const string Version = "4.0.0"; - private const bool IsPreRelease = false; - - public readonly string SrcDir = "./src/"; - public readonly string OutDir = "./build/"; - - public string Target { get; private set; } - public string SemVer { get; private set; } - public string BuildVersion { get; private set; } - public string BuildProfile { get; private set; } - public bool IsTeamCityBuild { get; private set; } - - public static BuildConfig Create( - ICakeContext context, - BuildSystem buildSystem) - { - if (context == null) - throw new ArgumentNullException("context"); - - var buildRevision = context.Argument("buildrevision", "0"); - - return new BuildConfig - { - Target = context.Argument("target", "Default"), - SemVer = Version + (IsPreRelease ? $"-pre{buildRevision}" : string.Empty), - BuildVersion = Version + "." + buildRevision, - BuildProfile = context.Argument("configuration", "Release"), - IsTeamCityBuild = buildSystem.TeamCity.IsRunningOnTeamCity - }; - } -} diff --git a/src/Directory.Build.props b/src/Directory.Build.props index b752783..c7adc60 100644 --- a/src/Directory.Build.props +++ b/src/Directory.Build.props @@ -1,10 +1,15 @@ - - Structurizer + 0.0.0 - danielwertheim - danielwertheim - Copyright © danielwertheim 2016,2017,2018 - Git - - \ No newline at end of file + danielwertheim + danielwertheim + Copyright © danielwertheim + latest + https://github.com/danielwertheim/structurizer + Git + MIT + https://github.com/danielwertheim/structurizer + https://github.com/danielwertheim/structurizer/releases + true + + diff --git a/src/samples/Sample/Order.cs b/src/Sample/Order.cs similarity index 100% rename from src/samples/Sample/Order.cs rename to src/Sample/Order.cs diff --git a/src/samples/Sample/OrderLine.cs b/src/Sample/OrderLine.cs similarity index 100% rename from src/samples/Sample/OrderLine.cs rename to src/Sample/OrderLine.cs diff --git a/src/samples/Sample/OrderStatus.cs b/src/Sample/OrderStatus.cs similarity index 100% rename from src/samples/Sample/OrderStatus.cs rename to src/Sample/OrderStatus.cs diff --git a/src/samples/Sample/Program.cs b/src/Sample/Program.cs similarity index 100% rename from src/samples/Sample/Program.cs rename to src/Sample/Program.cs diff --git a/src/samples/Sample/Prop.cs b/src/Sample/Prop.cs similarity index 100% rename from src/samples/Sample/Prop.cs rename to src/Sample/Prop.cs diff --git a/src/samples/Sample/Sample.csproj b/src/Sample/Sample.csproj similarity index 57% rename from src/samples/Sample/Sample.csproj rename to src/Sample/Sample.csproj index a734390..4825c43 100644 --- a/src/samples/Sample/Sample.csproj +++ b/src/Sample/Sample.csproj @@ -3,10 +3,12 @@ Exe netcoreapp2.1 + false + false - + diff --git a/src/Structurizer.sln b/src/Structurizer.sln index df8a60a..6d4eb7c 100644 --- a/src/Structurizer.sln +++ b/src/Structurizer.sln @@ -1,18 +1,18 @@  Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio 15 -VisualStudioVersion = 15.0.28306.52 +# Visual Studio Version 16 +VisualStudioVersion = 16.0.29613.14 MinimumVisualStudioVersion = 10.0.40219.1 -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Structurizer", "projects\Structurizer\Structurizer.csproj", "{19E4C0FA-DE88-4E13-B234-570B4F6F2AB6}" -EndProject -Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{53FAF42D-011E-4014-B3C3-6A3A0EC981DB}" +Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{47EDD254-E0BB-4EA2-AEA5-8AC817802C29}" ProjectSection(SolutionItems) = preProject Directory.Build.props = Directory.Build.props EndProjectSection EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "UnitTests", "tests\UnitTests\UnitTests.csproj", "{8E9CFC68-B575-4875-A507-69D7F0601A43}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Structurizer", "Structurizer\Structurizer.csproj", "{CDB3E809-4B1E-4EF3-808E-4FD503D325B8}" +EndProject +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "UnitTests", "UnitTests\UnitTests.csproj", "{D9782C06-2123-48EB-9855-6CEA85066CF1}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Sample", "samples\Sample\Sample.csproj", "{17694DD5-3B75-4D6D-AAD2-A75C6B7D06F9}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Sample", "Sample\Sample.csproj", "{48863385-3B25-473C-91F0-00F4615F6188}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution @@ -20,23 +20,23 @@ Global Release|Any CPU = Release|Any CPU EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution - {19E4C0FA-DE88-4E13-B234-570B4F6F2AB6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {19E4C0FA-DE88-4E13-B234-570B4F6F2AB6}.Debug|Any CPU.Build.0 = Debug|Any CPU - {19E4C0FA-DE88-4E13-B234-570B4F6F2AB6}.Release|Any CPU.ActiveCfg = Release|Any CPU - {19E4C0FA-DE88-4E13-B234-570B4F6F2AB6}.Release|Any CPU.Build.0 = Release|Any CPU - {8E9CFC68-B575-4875-A507-69D7F0601A43}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {8E9CFC68-B575-4875-A507-69D7F0601A43}.Debug|Any CPU.Build.0 = Debug|Any CPU - {8E9CFC68-B575-4875-A507-69D7F0601A43}.Release|Any CPU.ActiveCfg = Release|Any CPU - {8E9CFC68-B575-4875-A507-69D7F0601A43}.Release|Any CPU.Build.0 = Release|Any CPU - {17694DD5-3B75-4D6D-AAD2-A75C6B7D06F9}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {17694DD5-3B75-4D6D-AAD2-A75C6B7D06F9}.Debug|Any CPU.Build.0 = Debug|Any CPU - {17694DD5-3B75-4D6D-AAD2-A75C6B7D06F9}.Release|Any CPU.ActiveCfg = Release|Any CPU - {17694DD5-3B75-4D6D-AAD2-A75C6B7D06F9}.Release|Any CPU.Build.0 = Release|Any CPU + {CDB3E809-4B1E-4EF3-808E-4FD503D325B8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {CDB3E809-4B1E-4EF3-808E-4FD503D325B8}.Debug|Any CPU.Build.0 = Debug|Any CPU + {CDB3E809-4B1E-4EF3-808E-4FD503D325B8}.Release|Any CPU.ActiveCfg = Release|Any CPU + {CDB3E809-4B1E-4EF3-808E-4FD503D325B8}.Release|Any CPU.Build.0 = Release|Any CPU + {D9782C06-2123-48EB-9855-6CEA85066CF1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {D9782C06-2123-48EB-9855-6CEA85066CF1}.Debug|Any CPU.Build.0 = Debug|Any CPU + {D9782C06-2123-48EB-9855-6CEA85066CF1}.Release|Any CPU.ActiveCfg = Release|Any CPU + {D9782C06-2123-48EB-9855-6CEA85066CF1}.Release|Any CPU.Build.0 = Release|Any CPU + {48863385-3B25-473C-91F0-00F4615F6188}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {48863385-3B25-473C-91F0-00F4615F6188}.Debug|Any CPU.Build.0 = Debug|Any CPU + {48863385-3B25-473C-91F0-00F4615F6188}.Release|Any CPU.ActiveCfg = Release|Any CPU + {48863385-3B25-473C-91F0-00F4615F6188}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE EndGlobalSection GlobalSection(ExtensibilityGlobals) = postSolution - SolutionGuid = {2900D425-B629-46CC-B594-01671AB7E954} + SolutionGuid = {87631C88-A07E-4057-8EEE-590DB1278E76} EndGlobalSection EndGlobal diff --git a/src/projects/Structurizer/Configuration/StructureTypeConfig.cs b/src/Structurizer/Configuration/StructureTypeConfig.cs similarity index 100% rename from src/projects/Structurizer/Configuration/StructureTypeConfig.cs rename to src/Structurizer/Configuration/StructureTypeConfig.cs diff --git a/src/projects/Structurizer/Configuration/StructureTypeConfigurations.cs b/src/Structurizer/Configuration/StructureTypeConfigurations.cs similarity index 100% rename from src/projects/Structurizer/Configuration/StructureTypeConfigurations.cs rename to src/Structurizer/Configuration/StructureTypeConfigurations.cs diff --git a/src/projects/Structurizer/Configuration/StructureTypeConfigurator.cs b/src/Structurizer/Configuration/StructureTypeConfigurator.cs similarity index 100% rename from src/projects/Structurizer/Configuration/StructureTypeConfigurator.cs rename to src/Structurizer/Configuration/StructureTypeConfigurator.cs diff --git a/src/projects/Structurizer/DataTypeCode.cs b/src/Structurizer/DataTypeCode.cs similarity index 100% rename from src/projects/Structurizer/DataTypeCode.cs rename to src/Structurizer/DataTypeCode.cs diff --git a/src/projects/Structurizer/DataTypeConverter.cs b/src/Structurizer/DataTypeConverter.cs similarity index 100% rename from src/projects/Structurizer/DataTypeConverter.cs rename to src/Structurizer/DataTypeConverter.cs diff --git a/src/projects/Structurizer/Extensions/ExpressionExtensions.cs b/src/Structurizer/Extensions/ExpressionExtensions.cs similarity index 100% rename from src/projects/Structurizer/Extensions/ExpressionExtensions.cs rename to src/Structurizer/Extensions/ExpressionExtensions.cs diff --git a/src/projects/Structurizer/Extensions/TypeExtensions.cs b/src/Structurizer/Extensions/TypeExtensions.cs similarity index 100% rename from src/projects/Structurizer/Extensions/TypeExtensions.cs rename to src/Structurizer/Extensions/TypeExtensions.cs diff --git a/src/projects/Structurizer/FlexibleStructureBuilder.cs b/src/Structurizer/FlexibleStructureBuilder.cs similarity index 100% rename from src/projects/Structurizer/FlexibleStructureBuilder.cs rename to src/Structurizer/FlexibleStructureBuilder.cs diff --git a/src/projects/Structurizer/IDataTypeConverter.cs b/src/Structurizer/IDataTypeConverter.cs similarity index 100% rename from src/projects/Structurizer/IDataTypeConverter.cs rename to src/Structurizer/IDataTypeConverter.cs diff --git a/src/projects/Structurizer/IIndexAccessor.cs b/src/Structurizer/IIndexAccessor.cs similarity index 100% rename from src/projects/Structurizer/IIndexAccessor.cs rename to src/Structurizer/IIndexAccessor.cs diff --git a/src/projects/Structurizer/IStructure.cs b/src/Structurizer/IStructure.cs similarity index 100% rename from src/projects/Structurizer/IStructure.cs rename to src/Structurizer/IStructure.cs diff --git a/src/projects/Structurizer/IStructureBuilder.cs b/src/Structurizer/IStructureBuilder.cs similarity index 100% rename from src/projects/Structurizer/IStructureBuilder.cs rename to src/Structurizer/IStructureBuilder.cs diff --git a/src/projects/Structurizer/IStructureIndex.cs b/src/Structurizer/IStructureIndex.cs similarity index 100% rename from src/projects/Structurizer/IStructureIndex.cs rename to src/Structurizer/IStructureIndex.cs diff --git a/src/projects/Structurizer/IStructureIndexValue.cs b/src/Structurizer/IStructureIndexValue.cs similarity index 100% rename from src/projects/Structurizer/IStructureIndexValue.cs rename to src/Structurizer/IStructureIndexValue.cs diff --git a/src/projects/Structurizer/IStructureIndexesFactory.cs b/src/Structurizer/IStructureIndexesFactory.cs similarity index 100% rename from src/projects/Structurizer/IStructureIndexesFactory.cs rename to src/Structurizer/IStructureIndexesFactory.cs diff --git a/src/projects/Structurizer/IStructureProperty.cs b/src/Structurizer/IStructureProperty.cs similarity index 100% rename from src/projects/Structurizer/IStructureProperty.cs rename to src/Structurizer/IStructureProperty.cs diff --git a/src/projects/Structurizer/IStructurePropertyFactory.cs b/src/Structurizer/IStructurePropertyFactory.cs similarity index 100% rename from src/projects/Structurizer/IStructurePropertyFactory.cs rename to src/Structurizer/IStructurePropertyFactory.cs diff --git a/src/projects/Structurizer/IStructureSchema.cs b/src/Structurizer/IStructureSchema.cs similarity index 100% rename from src/projects/Structurizer/IStructureSchema.cs rename to src/Structurizer/IStructureSchema.cs diff --git a/src/projects/Structurizer/IStructureSchemaFactory.cs b/src/Structurizer/IStructureSchemaFactory.cs similarity index 100% rename from src/projects/Structurizer/IStructureSchemaFactory.cs rename to src/Structurizer/IStructureSchemaFactory.cs diff --git a/src/projects/Structurizer/IStructureType.cs b/src/Structurizer/IStructureType.cs similarity index 100% rename from src/projects/Structurizer/IStructureType.cs rename to src/Structurizer/IStructureType.cs diff --git a/src/projects/Structurizer/IStructureTypeConfig.cs b/src/Structurizer/IStructureTypeConfig.cs similarity index 100% rename from src/projects/Structurizer/IStructureTypeConfig.cs rename to src/Structurizer/IStructureTypeConfig.cs diff --git a/src/projects/Structurizer/IStructureTypeConfigurations.cs b/src/Structurizer/IStructureTypeConfigurations.cs similarity index 100% rename from src/projects/Structurizer/IStructureTypeConfigurations.cs rename to src/Structurizer/IStructureTypeConfigurations.cs diff --git a/src/projects/Structurizer/IStructureTypeConfigurator.cs b/src/Structurizer/IStructureTypeConfigurator.cs similarity index 100% rename from src/projects/Structurizer/IStructureTypeConfigurator.cs rename to src/Structurizer/IStructureTypeConfigurator.cs diff --git a/src/projects/Structurizer/IStructureTypeFactory.cs b/src/Structurizer/IStructureTypeFactory.cs similarity index 100% rename from src/projects/Structurizer/IStructureTypeFactory.cs rename to src/Structurizer/IStructureTypeFactory.cs diff --git a/src/projects/Structurizer/IStructureTypeReflecter.cs b/src/Structurizer/IStructureTypeReflecter.cs similarity index 100% rename from src/projects/Structurizer/IStructureTypeReflecter.cs rename to src/Structurizer/IStructureTypeReflecter.cs diff --git a/src/projects/Structurizer/IndexMode.cs b/src/Structurizer/IndexMode.cs similarity index 100% rename from src/projects/Structurizer/IndexMode.cs rename to src/Structurizer/IndexMode.cs diff --git a/src/projects/Structurizer/Schemas/DynamicGetter.cs b/src/Structurizer/Schemas/DynamicGetter.cs similarity index 100% rename from src/projects/Structurizer/Schemas/DynamicGetter.cs rename to src/Structurizer/Schemas/DynamicGetter.cs diff --git a/src/projects/Structurizer/Schemas/DynamicPropertyFactory.cs b/src/Structurizer/Schemas/DynamicPropertyFactory.cs similarity index 100% rename from src/projects/Structurizer/Schemas/DynamicPropertyFactory.cs rename to src/Structurizer/Schemas/DynamicPropertyFactory.cs diff --git a/src/projects/Structurizer/Schemas/IndexAccessor.cs b/src/Structurizer/Schemas/IndexAccessor.cs similarity index 100% rename from src/projects/Structurizer/Schemas/IndexAccessor.cs rename to src/Structurizer/Schemas/IndexAccessor.cs diff --git a/src/projects/Structurizer/Schemas/PropertyPathBuilder.cs b/src/Structurizer/Schemas/PropertyPathBuilder.cs similarity index 100% rename from src/projects/Structurizer/Schemas/PropertyPathBuilder.cs rename to src/Structurizer/Schemas/PropertyPathBuilder.cs diff --git a/src/projects/Structurizer/Schemas/StructureProperty.cs b/src/Structurizer/Schemas/StructureProperty.cs similarity index 100% rename from src/projects/Structurizer/Schemas/StructureProperty.cs rename to src/Structurizer/Schemas/StructureProperty.cs diff --git a/src/projects/Structurizer/Schemas/StructurePropertyCallstack.cs b/src/Structurizer/Schemas/StructurePropertyCallstack.cs similarity index 100% rename from src/projects/Structurizer/Schemas/StructurePropertyCallstack.cs rename to src/Structurizer/Schemas/StructurePropertyCallstack.cs diff --git a/src/projects/Structurizer/Schemas/StructurePropertyFactory.cs b/src/Structurizer/Schemas/StructurePropertyFactory.cs similarity index 100% rename from src/projects/Structurizer/Schemas/StructurePropertyFactory.cs rename to src/Structurizer/Schemas/StructurePropertyFactory.cs diff --git a/src/projects/Structurizer/Schemas/StructurePropertyFactoryRules.cs b/src/Structurizer/Schemas/StructurePropertyFactoryRules.cs similarity index 100% rename from src/projects/Structurizer/Schemas/StructurePropertyFactoryRules.cs rename to src/Structurizer/Schemas/StructurePropertyFactoryRules.cs diff --git a/src/projects/Structurizer/Schemas/StructurePropertyInfo.cs b/src/Structurizer/Schemas/StructurePropertyInfo.cs similarity index 100% rename from src/projects/Structurizer/Schemas/StructurePropertyInfo.cs rename to src/Structurizer/Schemas/StructurePropertyInfo.cs diff --git a/src/projects/Structurizer/Schemas/StructureSchema.cs b/src/Structurizer/Schemas/StructureSchema.cs similarity index 100% rename from src/projects/Structurizer/Schemas/StructureSchema.cs rename to src/Structurizer/Schemas/StructureSchema.cs diff --git a/src/projects/Structurizer/Schemas/StructureType.cs b/src/Structurizer/Schemas/StructureType.cs similarity index 100% rename from src/projects/Structurizer/Schemas/StructureType.cs rename to src/Structurizer/Schemas/StructureType.cs diff --git a/src/projects/Structurizer/Schemas/StructureTypeReflecter.cs b/src/Structurizer/Schemas/StructureTypeReflecter.cs similarity index 100% rename from src/projects/Structurizer/Schemas/StructureTypeReflecter.cs rename to src/Structurizer/Schemas/StructureTypeReflecter.cs diff --git a/src/projects/Structurizer/Structure.cs b/src/Structurizer/Structure.cs similarity index 100% rename from src/projects/Structurizer/Structure.cs rename to src/Structurizer/Structure.cs diff --git a/src/projects/Structurizer/StructureBuilder.cs b/src/Structurizer/StructureBuilder.cs similarity index 100% rename from src/projects/Structurizer/StructureBuilder.cs rename to src/Structurizer/StructureBuilder.cs diff --git a/src/projects/Structurizer/StructureIndex.cs b/src/Structurizer/StructureIndex.cs similarity index 100% rename from src/projects/Structurizer/StructureIndex.cs rename to src/Structurizer/StructureIndex.cs diff --git a/src/projects/Structurizer/StructureIndexValue.cs b/src/Structurizer/StructureIndexValue.cs similarity index 100% rename from src/projects/Structurizer/StructureIndexValue.cs rename to src/Structurizer/StructureIndexValue.cs diff --git a/src/projects/Structurizer/StructureIndexesFactory.cs b/src/Structurizer/StructureIndexesFactory.cs similarity index 100% rename from src/projects/Structurizer/StructureIndexesFactory.cs rename to src/Structurizer/StructureIndexesFactory.cs diff --git a/src/projects/Structurizer/StructureSchemaFactory.cs b/src/Structurizer/StructureSchemaFactory.cs similarity index 100% rename from src/projects/Structurizer/StructureSchemaFactory.cs rename to src/Structurizer/StructureSchemaFactory.cs diff --git a/src/projects/Structurizer/StructureTypeFactory.cs b/src/Structurizer/StructureTypeFactory.cs similarity index 100% rename from src/projects/Structurizer/StructureTypeFactory.cs rename to src/Structurizer/StructureTypeFactory.cs diff --git a/src/Structurizer/Structurizer.csproj b/src/Structurizer/Structurizer.csproj new file mode 100644 index 0000000..70831b4 --- /dev/null +++ b/src/Structurizer/Structurizer.csproj @@ -0,0 +1,19 @@ + + + + net451;netstandard2.0 + Used for creating key-value representation of object graphs + key-value structure object-graph + + + + 1701;1702;1705;1591 + bin\Release\$(TargetFramework)\Structurizer.xml + + + + + + + + diff --git a/src/projects/Structurizer/StructurizerException.cs b/src/Structurizer/StructurizerException.cs similarity index 100% rename from src/projects/Structurizer/StructurizerException.cs rename to src/Structurizer/StructurizerException.cs diff --git a/src/projects/Structurizer/StructurizerExceptionMessages.cs b/src/Structurizer/StructurizerExceptionMessages.cs similarity index 100% rename from src/projects/Structurizer/StructurizerExceptionMessages.cs rename to src/Structurizer/StructurizerExceptionMessages.cs diff --git a/src/tests/UnitTests/Configuration/StructureTypeConfigTests.cs b/src/UnitTests/Configuration/StructureTypeConfigTests.cs similarity index 100% rename from src/tests/UnitTests/Configuration/StructureTypeConfigTests.cs rename to src/UnitTests/Configuration/StructureTypeConfigTests.cs diff --git a/src/tests/UnitTests/Configuration/StructureTypeConfigurationsTests.cs b/src/UnitTests/Configuration/StructureTypeConfigurationsTests.cs similarity index 100% rename from src/tests/UnitTests/Configuration/StructureTypeConfigurationsTests.cs rename to src/UnitTests/Configuration/StructureTypeConfigurationsTests.cs diff --git a/src/tests/UnitTests/Configuration/StructureTypeConfiguratorTests.cs b/src/UnitTests/Configuration/StructureTypeConfiguratorTests.cs similarity index 100% rename from src/tests/UnitTests/Configuration/StructureTypeConfiguratorTests.cs rename to src/UnitTests/Configuration/StructureTypeConfiguratorTests.cs diff --git a/src/tests/UnitTests/DataTypeCodeTests.cs b/src/UnitTests/DataTypeCodeTests.cs similarity index 100% rename from src/tests/UnitTests/DataTypeCodeTests.cs rename to src/UnitTests/DataTypeCodeTests.cs diff --git a/src/tests/UnitTests/FlexibleStructureBuilderTests.cs b/src/UnitTests/FlexibleStructureBuilderTests.cs similarity index 100% rename from src/tests/UnitTests/FlexibleStructureBuilderTests.cs rename to src/UnitTests/FlexibleStructureBuilderTests.cs diff --git a/src/tests/UnitTests/Schemas/DataTypeConverterTests.cs b/src/UnitTests/Schemas/DataTypeConverterTests.cs similarity index 100% rename from src/tests/UnitTests/Schemas/DataTypeConverterTests.cs rename to src/UnitTests/Schemas/DataTypeConverterTests.cs diff --git a/src/tests/UnitTests/Schemas/IndexAccessorTestFactory.cs b/src/UnitTests/Schemas/IndexAccessorTestFactory.cs similarity index 100% rename from src/tests/UnitTests/Schemas/IndexAccessorTestFactory.cs rename to src/UnitTests/Schemas/IndexAccessorTestFactory.cs diff --git a/src/tests/UnitTests/Schemas/MemberAccessors/IndexAccessorGetValuesOnDeepGraphTests.cs b/src/UnitTests/Schemas/MemberAccessors/IndexAccessorGetValuesOnDeepGraphTests.cs similarity index 100% rename from src/tests/UnitTests/Schemas/MemberAccessors/IndexAccessorGetValuesOnDeepGraphTests.cs rename to src/UnitTests/Schemas/MemberAccessors/IndexAccessorGetValuesOnDeepGraphTests.cs diff --git a/src/tests/UnitTests/Schemas/MemberAccessors/IndexAccessorGetValuesOnSubItemTests.cs b/src/UnitTests/Schemas/MemberAccessors/IndexAccessorGetValuesOnSubItemTests.cs similarity index 100% rename from src/tests/UnitTests/Schemas/MemberAccessors/IndexAccessorGetValuesOnSubItemTests.cs rename to src/UnitTests/Schemas/MemberAccessors/IndexAccessorGetValuesOnSubItemTests.cs diff --git a/src/tests/UnitTests/Schemas/MemberAccessors/IndexAccessorGetValuesTests.cs b/src/UnitTests/Schemas/MemberAccessors/IndexAccessorGetValuesTests.cs similarity index 100% rename from src/tests/UnitTests/Schemas/MemberAccessors/IndexAccessorGetValuesTests.cs rename to src/UnitTests/Schemas/MemberAccessors/IndexAccessorGetValuesTests.cs diff --git a/src/tests/UnitTests/Schemas/PropertyPathBuilderTests.cs b/src/UnitTests/Schemas/PropertyPathBuilderTests.cs similarity index 100% rename from src/tests/UnitTests/Schemas/PropertyPathBuilderTests.cs rename to src/UnitTests/Schemas/PropertyPathBuilderTests.cs diff --git a/src/tests/UnitTests/Schemas/StructurePropertyTestFactory.cs b/src/UnitTests/Schemas/StructurePropertyTestFactory.cs similarity index 100% rename from src/tests/UnitTests/Schemas/StructurePropertyTestFactory.cs rename to src/UnitTests/Schemas/StructurePropertyTestFactory.cs diff --git a/src/tests/UnitTests/Schemas/StructurePropertyTests/StructurePropertyAttributesTests.cs b/src/UnitTests/Schemas/StructurePropertyTests/StructurePropertyAttributesTests.cs similarity index 100% rename from src/tests/UnitTests/Schemas/StructurePropertyTests/StructurePropertyAttributesTests.cs rename to src/UnitTests/Schemas/StructurePropertyTests/StructurePropertyAttributesTests.cs diff --git a/src/tests/UnitTests/Schemas/StructurePropertyTests/StructurePropertyEnumerableTests.cs b/src/UnitTests/Schemas/StructurePropertyTests/StructurePropertyEnumerableTests.cs similarity index 100% rename from src/tests/UnitTests/Schemas/StructurePropertyTests/StructurePropertyEnumerableTests.cs rename to src/UnitTests/Schemas/StructurePropertyTests/StructurePropertyEnumerableTests.cs diff --git a/src/tests/UnitTests/Schemas/StructurePropertyTests/StructurePropertyGetGuidValueTests.cs b/src/UnitTests/Schemas/StructurePropertyTests/StructurePropertyGetGuidValueTests.cs similarity index 100% rename from src/tests/UnitTests/Schemas/StructurePropertyTests/StructurePropertyGetGuidValueTests.cs rename to src/UnitTests/Schemas/StructurePropertyTests/StructurePropertyGetGuidValueTests.cs diff --git a/src/tests/UnitTests/Schemas/StructurePropertyTests/StructurePropertyGetIdentityValueTests.cs b/src/UnitTests/Schemas/StructurePropertyTests/StructurePropertyGetIdentityValueTests.cs similarity index 100% rename from src/tests/UnitTests/Schemas/StructurePropertyTests/StructurePropertyGetIdentityValueTests.cs rename to src/UnitTests/Schemas/StructurePropertyTests/StructurePropertyGetIdentityValueTests.cs diff --git a/src/tests/UnitTests/Schemas/StructurePropertyTests/StructurePropertyGetPrimitiveValueTests.cs b/src/UnitTests/Schemas/StructurePropertyTests/StructurePropertyGetPrimitiveValueTests.cs similarity index 100% rename from src/tests/UnitTests/Schemas/StructurePropertyTests/StructurePropertyGetPrimitiveValueTests.cs rename to src/UnitTests/Schemas/StructurePropertyTests/StructurePropertyGetPrimitiveValueTests.cs diff --git a/src/tests/UnitTests/Schemas/StructurePropertyTests/StructurePropertyGetStringValueTests.cs b/src/UnitTests/Schemas/StructurePropertyTests/StructurePropertyGetStringValueTests.cs similarity index 100% rename from src/tests/UnitTests/Schemas/StructurePropertyTests/StructurePropertyGetStringValueTests.cs rename to src/UnitTests/Schemas/StructurePropertyTests/StructurePropertyGetStringValueTests.cs diff --git a/src/tests/UnitTests/Schemas/StructureSchemaFactoryTests.cs b/src/UnitTests/Schemas/StructureSchemaFactoryTests.cs similarity index 100% rename from src/tests/UnitTests/Schemas/StructureSchemaFactoryTests.cs rename to src/UnitTests/Schemas/StructureSchemaFactoryTests.cs diff --git a/src/tests/UnitTests/Schemas/StructureSchemaTests.cs b/src/UnitTests/Schemas/StructureSchemaTests.cs similarity index 100% rename from src/tests/UnitTests/Schemas/StructureSchemaTests.cs rename to src/UnitTests/Schemas/StructureSchemaTests.cs diff --git a/src/tests/UnitTests/Schemas/StructureTypeFactoryTests.cs b/src/UnitTests/Schemas/StructureTypeFactoryTests.cs similarity index 100% rename from src/tests/UnitTests/Schemas/StructureTypeFactoryTests.cs rename to src/UnitTests/Schemas/StructureTypeFactoryTests.cs diff --git a/src/tests/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterComplexIndexablePropertiesTests.cs b/src/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterComplexIndexablePropertiesTests.cs similarity index 100% rename from src/tests/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterComplexIndexablePropertiesTests.cs rename to src/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterComplexIndexablePropertiesTests.cs diff --git a/src/tests/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterEnumerableIndexablePropertiesTests.cs b/src/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterEnumerableIndexablePropertiesTests.cs similarity index 100% rename from src/tests/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterEnumerableIndexablePropertiesTests.cs rename to src/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterEnumerableIndexablePropertiesTests.cs diff --git a/src/tests/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterGetIndexablePropertiesExceptTests.cs b/src/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterGetIndexablePropertiesExceptTests.cs similarity index 100% rename from src/tests/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterGetIndexablePropertiesExceptTests.cs rename to src/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterGetIndexablePropertiesExceptTests.cs diff --git a/src/tests/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterGetSpecificIndexablePropertiesTests.cs b/src/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterGetSpecificIndexablePropertiesTests.cs similarity index 100% rename from src/tests/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterGetSpecificIndexablePropertiesTests.cs rename to src/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterGetSpecificIndexablePropertiesTests.cs diff --git a/src/tests/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterSimpleIndexablePropertiesTests.cs b/src/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterSimpleIndexablePropertiesTests.cs similarity index 100% rename from src/tests/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterSimpleIndexablePropertiesTests.cs rename to src/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterSimpleIndexablePropertiesTests.cs diff --git a/src/tests/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterTestsBase.cs b/src/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterTestsBase.cs similarity index 100% rename from src/tests/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterTestsBase.cs rename to src/UnitTests/Schemas/StructureTypeReflecterTests/StructureTypeReflecterTestsBase.cs diff --git a/src/tests/UnitTests/StructureBuilderTests/StructureBuilderBaseTests.cs b/src/UnitTests/StructureBuilderTests/StructureBuilderBaseTests.cs similarity index 100% rename from src/tests/UnitTests/StructureBuilderTests/StructureBuilderBaseTests.cs rename to src/UnitTests/StructureBuilderTests/StructureBuilderBaseTests.cs diff --git a/src/tests/UnitTests/StructureBuilderTests/StructureBuilderEnumerableTests.cs b/src/UnitTests/StructureBuilderTests/StructureBuilderEnumerableTests.cs similarity index 100% rename from src/tests/UnitTests/StructureBuilderTests/StructureBuilderEnumerableTests.cs rename to src/UnitTests/StructureBuilderTests/StructureBuilderEnumerableTests.cs diff --git a/src/tests/UnitTests/StructureBuilderTests/StructureBuilderGraphTests.cs b/src/UnitTests/StructureBuilderTests/StructureBuilderGraphTests.cs similarity index 100% rename from src/tests/UnitTests/StructureBuilderTests/StructureBuilderGraphTests.cs rename to src/UnitTests/StructureBuilderTests/StructureBuilderGraphTests.cs diff --git a/src/tests/UnitTests/StructureBuilderTests/StructureBuilderIncludeAndExcludeTests.cs b/src/UnitTests/StructureBuilderTests/StructureBuilderIncludeAndExcludeTests.cs similarity index 100% rename from src/tests/UnitTests/StructureBuilderTests/StructureBuilderIncludeAndExcludeTests.cs rename to src/UnitTests/StructureBuilderTests/StructureBuilderIncludeAndExcludeTests.cs diff --git a/src/tests/UnitTests/StructureBuilderTests/StructureBuilderNullablesTests.cs b/src/UnitTests/StructureBuilderTests/StructureBuilderNullablesTests.cs similarity index 100% rename from src/tests/UnitTests/StructureBuilderTests/StructureBuilderNullablesTests.cs rename to src/UnitTests/StructureBuilderTests/StructureBuilderNullablesTests.cs diff --git a/src/tests/UnitTests/StructureBuilderTests/StructureBuilderTests.cs b/src/UnitTests/StructureBuilderTests/StructureBuilderTests.cs similarity index 100% rename from src/tests/UnitTests/StructureBuilderTests/StructureBuilderTests.cs rename to src/UnitTests/StructureBuilderTests/StructureBuilderTests.cs diff --git a/src/tests/UnitTests/StructureIndexesFactoryTests.cs b/src/UnitTests/StructureIndexesFactoryTests.cs similarity index 100% rename from src/tests/UnitTests/StructureIndexesFactoryTests.cs rename to src/UnitTests/StructureIndexesFactoryTests.cs diff --git a/src/tests/UnitTests/StructureSchemaTestFactory.cs b/src/UnitTests/StructureSchemaTestFactory.cs similarity index 100% rename from src/tests/UnitTests/StructureSchemaTestFactory.cs rename to src/UnitTests/StructureSchemaTestFactory.cs diff --git a/src/tests/UnitTests/StructureTypeTestFactory.cs b/src/UnitTests/StructureTypeTestFactory.cs similarity index 100% rename from src/tests/UnitTests/StructureTypeTestFactory.cs rename to src/UnitTests/StructureTypeTestFactory.cs diff --git a/src/tests/UnitTests/UnitTests.cs b/src/UnitTests/UnitTests.cs similarity index 100% rename from src/tests/UnitTests/UnitTests.cs rename to src/UnitTests/UnitTests.cs diff --git a/src/UnitTests/UnitTests.csproj b/src/UnitTests/UnitTests.csproj new file mode 100644 index 0000000..72ea06d --- /dev/null +++ b/src/UnitTests/UnitTests.csproj @@ -0,0 +1,21 @@ + + + + net452;netcoreapp3.1 + false + true + + + + + + + + + + + + + + + diff --git a/src/projects/Structurizer/Structurizer.csproj b/src/projects/Structurizer/Structurizer.csproj deleted file mode 100644 index edabf0f..0000000 --- a/src/projects/Structurizer/Structurizer.csproj +++ /dev/null @@ -1,28 +0,0 @@ - - - - net4.5.1;netstandard2.0 - Structurizer - Used for creating key-value representation of object graphs - Structurizer - Structurizer - Structurizer - key-value structure object-graph - https://raw.githubusercontent.com/danielwertheim/structurizer/master/LICENSE.txt - https://github.com/danielwertheim/structurizer - https://github.com/danielwertheim/structurizer - https://github.com/danielwertheim/structurizer/blob/master/ReleaseNotes.md - True - - - - 1701;1702;1705;1591 - bin\Release\netstandard2.0\Structurizer.xml - - - - - - - - diff --git a/src/tests/UnitTests/UnitTests.csproj b/src/tests/UnitTests/UnitTests.csproj deleted file mode 100644 index a56e0c9..0000000 --- a/src/tests/UnitTests/UnitTests.csproj +++ /dev/null @@ -1,21 +0,0 @@ - - - - netcoreapp2.1 - - false - - - - - - - - - - - - - - - diff --git a/tools/packages.config b/tools/packages.config deleted file mode 100644 index 0501888..0000000 --- a/tools/packages.config +++ /dev/null @@ -1,4 +0,0 @@ - - - -