Skip to content

Commit b7b5789

Browse files
Merge pull request #57 from umbraco/v9/feature/build-script
v9: Update build script
2 parents 329b0e7 + ce79ed4 commit b7b5789

36 files changed

+757
-1808
lines changed

.artifactignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
**/*
2+
!src/*/bin/**
3+
!src/*/obj/**
4+
!tests/*/bin/**
5+
!tests/*/obj/**

.editorconfig

Lines changed: 393 additions & 9 deletions
Large diffs are not rendered by default.

.gitignore

Lines changed: 39 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,40 +1,51 @@
1-
.DS_Store
2-
._.DS_Store
1+
#
2+
# Umbraco Deploy .gitignore
3+
#
34

4-
*.aps
5+
# Common files
56
*.obj
6-
*.orig
7-
*.pch
87
*.pdb
9-
*.suo
108
*.user
9+
*.aps
10+
*.pch
1111
*.vspscc
12-
*.[Pp]ublish.xml
13-
[Bb]uild[Ll]og.*
12+
*.orig
13+
*.suo
14+
*.vs10x
15+
*.ndproj
16+
*.ignorer.*
1417

18+
# Common directories
19+
.DS_Store
20+
._.DS_Store
1521
.vs/
22+
.idea/
23+
24+
# Build directories
1625
[Bb]in/
17-
[Db]ebug*/
1826
[Oo]bj/
19-
[Rr]elease*/
27+
[Db]ebug/
28+
[Rr]elease/
29+
30+
# Tools
2031
_ReSharper*/
32+
_NCrunch_*/
33+
*.ncrunchsolution
34+
*.ncrunchsolution.user
35+
*.ncrunchproject
36+
*.crunchsolution.cache
37+
tools/NDepend/
2138
[Tt]est[Rr]esult*
22-
packages/
23-
[Aa]pp_[Dd]ata/
24-
bower_components/
25-
node_modules/
26-
Umbraco.Deploy.UI.Client/build/
27-
build/Tools/nuget.exe
28-
29-
src/Umbraco.Deploy.Contrib.Connectors/App_Plugins/*
30-
src/Umbraco.Deploy.Contrib.Connectors/Config/*
31-
src/Umbraco.Deploy.Contrib.Connectors/app.config
32-
/build/UmbracoDeploy.Contrib.*.nupkg
33-
/build/UmbracoDeploy.Contrib.*.zip
34-
/src/.idea
35-
36-
MigrationBackup/
39+
[Bb]uild[Ll]og.*
40+
[Ss]ource
41+
[Ss]andbox
42+
node_modules
43+
lib-bower
44+
*.psess
45+
*.vspx
46+
NDependOut/
47+
QueryResult.htm
48+
tools/docfx/
3749

38-
build.tmp
39-
build.out
40-
build/temp
50+
# Build
51+
/build.out/

.globalconfig

Lines changed: 83 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,83 @@
1+
is_global = true
2+
3+
##########################################
4+
# StyleCopAnalyzers Settings
5+
##########################################
6+
7+
# All constant fields must be PascalCase
8+
# https://github.com/DotNetAnalyzers/StyleCopAnalyzers/blob/master/documentation/SA1303.md
9+
dotnet_naming_symbols.stylecop_constant_fields_group.applicable_accessibilities = public, internal, protected_internal, protected, private_protected, private
10+
dotnet_naming_symbols.stylecop_constant_fields_group.required_modifiers = const
11+
dotnet_naming_symbols.stylecop_constant_fields_group.applicable_kinds = field
12+
dotnet_naming_rule.stylecop_constant_fields_must_be_pascal_case_rule.symbols = stylecop_constant_fields_group
13+
dotnet_naming_rule.stylecop_constant_fields_must_be_pascal_case_rule.style = pascal_case_style
14+
15+
# All static readonly fields must be PascalCase
16+
# Ajusted to ignore private fields.
17+
# https://github.com/DotNetAnalyzers/StyleCopAnalyzers/blob/master/documentation/SA1311.md
18+
dotnet_naming_symbols.stylecop_static_readonly_fields_group.applicable_accessibilities = public, internal, protected_internal, protected, private_protected
19+
dotnet_naming_symbols.stylecop_static_readonly_fields_group.required_modifiers = static, readonly
20+
dotnet_naming_symbols.stylecop_static_readonly_fields_group.applicable_kinds = field
21+
dotnet_naming_rule.stylecop_static_readonly_fields_must_be_pascal_case_rule.symbols = stylecop_static_readonly_fields_group
22+
dotnet_naming_rule.stylecop_static_readonly_fields_must_be_pascal_case_rule.style = pascal_case_style
23+
24+
# No non-private instance fields are allowed
25+
# https://github.com/DotNetAnalyzers/StyleCopAnalyzers/blob/master/documentation/SA1401.md
26+
dotnet_naming_symbols.stylecop_fields_must_be_private_group.applicable_accessibilities = public, internal, protected_internal, protected, private_protected
27+
dotnet_naming_symbols.stylecop_fields_must_be_private_group.applicable_kinds = field
28+
dotnet_naming_rule.stylecop_instance_fields_must_be_private_rule.symbols = stylecop_fields_must_be_private_group
29+
dotnet_naming_rule.stylecop_instance_fields_must_be_private_rule.style = disallowed_style
30+
31+
# Local variables must be camelCase
32+
# https://github.com/DotNetAnalyzers/StyleCopAnalyzers/blob/master/documentation/SA1312.md
33+
dotnet_naming_symbols.stylecop_local_fields_group.applicable_accessibilities = local
34+
dotnet_naming_symbols.stylecop_local_fields_group.applicable_kinds = local
35+
dotnet_naming_rule.stylecop_local_fields_must_be_camel_case_rule.symbols = stylecop_local_fields_group
36+
dotnet_naming_rule.stylecop_local_fields_must_be_camel_case_rule.style = camel_case_style
37+
38+
##########################################
39+
# StyleCopAnalyzers rule severity
40+
# https://github.com/DotNetAnalyzers/StyleCopAnalyzers
41+
##########################################
42+
43+
dotnet_analyzer_diagnostic.category-StyleCop.CSharp.DocumentationRules.severity = suggestion
44+
dotnet_analyzer_diagnostic.category-StyleCop.CSharp.ReadabilityRules.severity = suggestion
45+
dotnet_analyzer_diagnostic.category-StyleCop.CSharp.NamingRules.severity = suggestion
46+
dotnet_analyzer_diagnostic.category-StyleCop.CSharp.SpacingRules.severity = suggestion
47+
dotnet_analyzer_diagnostic.category-StyleCop.CSharp.OrderingRules.severity = suggestion
48+
dotnet_analyzer_diagnostic.category-StyleCop.CSharp.MaintainabilityRules.severity = suggestion
49+
dotnet_analyzer_diagnostic.category-StyleCop.CSharp.LayoutRules.severity = suggestion
50+
51+
dotnet_diagnostic.SA1636.severity = none # SA1636: File header copyright text should match
52+
dotnet_diagnostic.SA1101.severity = none # PrefixLocalCallsWithThis - stylecop appears to be ignoring dotnet_style_qualification_for_*
53+
dotnet_diagnostic.SA1309.severity = none # FieldNamesMustNotBeginWithUnderscore
54+
55+
dotnet_diagnostic.SA1503.severity = warning # BracesMustNotBeOmitted
56+
dotnet_diagnostic.SA1117.severity = warning # ParametersMustBeOnSameLineOrSeparateLines
57+
dotnet_diagnostic.SA1116.severity = warning # SplitParametersMustStartOnLineAfterDeclaration
58+
dotnet_diagnostic.SA1122.severity = warning # UseStringEmptyForEmptyStrings
59+
dotnet_diagnostic.SA1028.severity = warning # CodeMustNotContainTrailingWhitespace
60+
dotnet_diagnostic.SA1500.severity = warning # BracesForMultiLineStatementsMustNotShareLine
61+
dotnet_diagnostic.SA1401.severity = warning # FieldsMustBePrivate
62+
dotnet_diagnostic.SA1519.severity = warning # BracesMustNotBeOmittedFromMultiLineChildStatement
63+
dotnet_diagnostic.SA1111.severity = warning # ClosingParenthesisMustBeOnLineOfLastParameter
64+
dotnet_diagnostic.SA1520.severity = warning # UseBracesConsistently
65+
dotnet_diagnostic.SA1407.severity = warning # ArithmeticExpressionsMustDeclarePrecedence
66+
dotnet_diagnostic.SA1400.severity = warning # AccessModifierMustBeDeclared
67+
dotnet_diagnostic.SA1119.severity = warning # StatementMustNotUseUnnecessaryParenthesis
68+
dotnet_diagnostic.SA1649.severity = warning # FileNameMustMatchTypeName
69+
dotnet_diagnostic.SA1121.severity = warning # UseBuiltInTypeAlias
70+
dotnet_diagnostic.SA1132.severity = warning # DoNotCombineFields
71+
dotnet_diagnostic.SA1134.severity = warning # AttributesMustNotShareLine
72+
dotnet_diagnostic.SA1106.severity = warning # CodeMustNotContainEmptyStatements
73+
dotnet_diagnostic.SA1312.severity = warning # VariableNamesMustBeginWithLowerCaseLetter
74+
dotnet_diagnostic.SA1310.severity = warning # FieldNamesMustNotContainUnderscore
75+
dotnet_diagnostic.SA1303.severity = warning # ConstFieldNamesMustBeginWithUpperCaseLetter
76+
dotnet_diagnostic.SA1130.severity = warning # UseLambdaSyntax
77+
dotnet_diagnostic.SA1405.severity = warning # DebugAssertMustProvideMessageText
78+
dotnet_diagnostic.SA1205.severity = warning # PartialElementsMustDeclareAccess
79+
dotnet_diagnostic.SA1306.severity = warning # FieldNamesMustBeginWithLowerCaseLetter
80+
dotnet_diagnostic.SA1209.severity = warning # UsingAliasDirectivesMustBePlacedAfterOtherUsingDirectives
81+
dotnet_diagnostic.SA1216.severity = warning # UsingStaticDirectivesMustBePlacedAtTheCorrectLocation
82+
dotnet_diagnostic.SA1133.severity = warning # DoNotCombineAttributes
83+
dotnet_diagnostic.SA1135.severity = warning # UsingDirectivesMustBeQualified

Directory.Build.props

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
<Project>
2+
<PropertyGroup>
3+
<TargetFramework>net5.0</TargetFramework>
4+
<Company>Umbraco HQ</Company>
5+
<Authors>Umbraco</Authors>
6+
<Copyright>Copyright © Umbraco $([System.DateTime]::Today.ToString('yyyy'))</Copyright>
7+
<Product>Umbraco Deploy Contrib</Product>
8+
<PackageProjectUrl>https://umbraco.com/</PackageProjectUrl>
9+
<PackageIconUrl>https://umbraco.com/dist/nuget/logo-small.png</PackageIconUrl>
10+
<PackageIcon>icon.png</PackageIcon>
11+
<PackageTags>umbraco</PackageTags>
12+
<NeutralLanguage>en-US</NeutralLanguage>
13+
</PropertyGroup>
14+
15+
<!-- SourceLink -->
16+
<PropertyGroup>
17+
<PublishRepositoryUrl>true</PublishRepositoryUrl>
18+
<EmbedUntrackedSources>true</EmbedUntrackedSources>
19+
<IncludeSymbols>true</IncludeSymbols>
20+
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
21+
</PropertyGroup>
22+
23+
<ItemGroup>
24+
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="1.1.1" PrivateAssets="all" IsImplicitlyDefined="true" />
25+
<PackageReference Include="Nerdbank.GitVersioning" Version="3.5.113" PrivateAssets="all" IsImplicitlyDefined="true" />
26+
<PackageReference Include="StyleCop.Analyzers" Version="1.2.0-beta.435" PrivateAssets="all" IsImplicitlyDefined="true" />
27+
<PackageReference Include="Umbraco.Code" Version="2.0.0" PrivateAssets="all" IsImplicitlyDefined="true" />
28+
<PackageReference Include="Umbraco.GitVersioning.Extensions" Version="0.1.1" PrivateAssets="all" IsImplicitlyDefined="true" />
29+
</ItemGroup>
30+
31+
<ItemGroup>
32+
<Content Include="$(MSBuildThisFileDirectory)icon.png" Pack="true" PackagePath="" Visible="false" />
33+
</ItemGroup>
34+
35+
<PropertyGroup>
36+
<GitVersionBaseDirectory>$(MSBuildThisFileDirectory)</GitVersionBaseDirectory>
37+
</PropertyGroup>
38+
</Project>

NuGet.config

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<configuration>
3+
<packageSources>
4+
<clear />
5+
<add key="nuget.org" value="https://api.nuget.org/v3/index.json" />
6+
<add key="Umbraco Prereleases" value="https://www.myget.org/F/umbracoprereleases/api/v3/index.json" />
7+
<add key="Umbraco Nightly" value="https://www.myget.org/F/umbraconightly/api/v3/index.json" />
8+
</packageSources>
9+
</configuration>

README.md

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
[![Build Status](https://dev.azure.com/umbraco/Umbraco%20Deploy%20Contrib/_apis/build/status/Umbraco%20Deploy%20Contrib%20v3%20-%20Release?branchName=master-v3)](https://dev.azure.com/umbraco/Umbraco%20Deploy%20Contrib/_build/latest?definitionId=185&branchName=master-v3) [![NuGet release](https://img.shields.io/nuget/v/UmbracoDeploy.Contrib.svg)](https://www.nuget.org/packages/UmbracoDeploy.Contrib)
1+
[![Build Status](https://dev.azure.com/umbraco/Umbraco%20Deploy%20Contrib/_apis/build/status/Umbraco%20Deploy%20Contrib%20v9%20(Continuous)?branchName=v10%2Fdev)](https://dev.azure.com/umbraco/Umbraco%20Deploy%20Contrib/_build/latest?definitionId=345&branchName=v10%2Fdev) [![NuGet release](https://img.shields.io/nuget/v/Umbraco.Deploy.Contrib.svg)](https://www.nuget.org/packages/Umbraco.Deploy.Contrib)
22

33
# Umbraco Deploy Contrib
44

@@ -18,7 +18,7 @@ The main branches corresponding to the Umbraco and Umbraco Deploy major releases
1818

1919
This project offers Umbraco Deploy connectors for the following community packages:
2020

21-
-
21+
- (none)
2222

2323
Value connectors for certain core property editors are also included:
2424

@@ -36,6 +36,15 @@ When working with Umbraco 8, you can install the NuGet package using `Install-Pa
3636

3737
For Umbraco 9+ the package is available for install by: `Install-Package Umbraco.Deploy.Contrib`
3838

39+
### Building and packaging
40+
41+
```powershell
42+
dotnet restore Umbraco.Deploy.Contrib.sln
43+
dotnet build Umbraco.Deploy.Contrib.sln --configuration Release --no-restore
44+
dotnet pack Umbraco.Deploy.Contrib.sln --configuration Release --no-build -p:BuildProjectReferences=false --output build.out
45+
```
46+
47+
3948
---
4049
## Contributing to this project
4150

src/Umbraco.Deploy.Contrib.sln renamed to Umbraco.Deploy.Contrib.sln

Lines changed: 21 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,30 @@
11

22
Microsoft Visual Studio Solution File, Format Version 12.00
3-
# Visual Studio Version 16
4-
VisualStudioVersion = 16.0.29411.108
3+
# Visual Studio Version 17
4+
VisualStudioVersion = 17.3.32819.101
55
MinimumVisualStudioVersion = 10.0.40219.1
6-
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Umbraco.Deploy.Contrib", "Umbraco.Deploy.Contrib\Umbraco.Deploy.Contrib.csproj", "{42FB2213-0815-41CD-94F8-DFB0EC1D8061}"
6+
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Umbraco.Deploy.Contrib", "src\Umbraco.Deploy.Contrib\Umbraco.Deploy.Contrib.csproj", "{42FB2213-0815-41CD-94F8-DFB0EC1D8061}"
77
EndProject
8-
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Umbraco.Deploy.Contrib.Tests", "Umbraco.Deploy.Contrib.Tests\Umbraco.Deploy.Contrib.Tests.csproj", "{48B09241-9C44-47EF-B4DF-397B39A631DC}"
8+
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Umbraco.Deploy.Contrib.Tests", "tests\Umbraco.Deploy.Contrib.Tests\Umbraco.Deploy.Contrib.Tests.csproj", "{48B09241-9C44-47EF-B4DF-397B39A631DC}"
99
EndProject
1010
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{7AF3C28D-DBD0-4771-9A78-D6E982094DCC}"
1111
ProjectSection(SolutionItems) = preProject
12-
..\CONTRIBUTING.md = ..\CONTRIBUTING.md
13-
..\LICENSE.md = ..\LICENSE.md
14-
..\README.md = ..\README.md
12+
.artifactignore = .artifactignore
13+
.editorconfig = .editorconfig
14+
.gitattributes = .gitattributes
15+
.gitignore = .gitignore
16+
.globalconfig = .globalconfig
17+
azure-pipelines.yml = azure-pipelines.yml
18+
CONTRIBUTING.md = CONTRIBUTING.md
19+
Directory.Build.props = Directory.Build.props
20+
LICENSE.md = LICENSE.md
21+
NuGet.config = NuGet.config
22+
README.md = README.md
23+
version.json = version.json
1524
EndProjectSection
1625
EndProject
26+
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Tests", "Tests", "{A6A24D3F-71EC-4B77-8466-6CCBB69DC2A2}"
27+
EndProject
1728
Global
1829
GlobalSection(SolutionConfigurationPlatforms) = preSolution
1930
Debug|Any CPU = Debug|Any CPU
@@ -32,6 +43,9 @@ Global
3243
GlobalSection(SolutionProperties) = preSolution
3344
HideSolutionNode = FALSE
3445
EndGlobalSection
46+
GlobalSection(NestedProjects) = preSolution
47+
{48B09241-9C44-47EF-B4DF-397B39A631DC} = {A6A24D3F-71EC-4B77-8466-6CCBB69DC2A2}
48+
EndGlobalSection
3549
GlobalSection(ExtensibilityGlobals) = postSolution
3650
SolutionGuid = {20357E31-FA18-4D77-B38B-6C878A179849}
3751
EndGlobalSection

0 commit comments

Comments
 (0)