Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Publish to MyGet feed plus auto versioning for Bot Builder V3. (#4817)
* Set up automated versioning for all projects. * Version references fixed in 3 projects. * Rename .nuspec to match .csproj file name. * Add bones folder to .gitignore * revert .nuspec files for AspNetCore projects. * Add buildtools\SetVersionInNuspecFile.ps1 * File version setting removed from AssemblyInfo.cs. for Microsoft.Bot.Builder and Microsoft.Bot.Connector.AspNetCore2 and * .gitignores updated. * Version setting added to 2 .csproj files, Microsoft.Bot.Builder, Microsoft.Bot.Builder.Autofac. * Add SetVersionInAssemblyInfoCsFiles.ps1 * Changed assembly name to Microsoft.Bot.Connector.AspNetCore2. * AssemblyVersion uncommented in AssemblyInfo.cs * Diagnostic message added to SetVersionInAssembliInforCsFies.ps1 * Fixed Microsoft.Bot.Connector.AspNetCore2.nuspec * Reverting some of netcore2 changes. * Tweak
- Loading branch information
BruceHaley
authored and
Tom Laird-McConnell
committed
Jul 6, 2018
1 parent
783f2f9
commit 3e130b0
Showing
13 changed files
with
93 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
## Ignore Visual Studio temporary files, build results, and | ||
## files generated by popular Visual Studio add-ons. | ||
|
||
# User-specific files | ||
*.suo | ||
*.user | ||
*.userosscache | ||
*.sln.docstates | ||
|
||
# User-specific files (MonoDevelop/Xamarin Studio) | ||
*.userprefs | ||
|
||
# Build results | ||
[Dd]ebug/ | ||
|
||
bones/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<Project> | ||
|
||
<PropertyGroup> | ||
<Version Condition=" '$(PackageVersion)' == '' ">3.15.3.0-local</Version> | ||
<Version Condition=" '$(PackageVersion)' != '' ">$(PackageVersion)</Version> | ||
<PackageVersion Condition=" '$(PackageVersion)' == '' ">3.15.3.0-local</PackageVersion> | ||
<PackageVersion Condition=" '$(PackageVersion)' != '' ">$(PackageVersion)</PackageVersion> | ||
</PropertyGroup> | ||
|
||
</Project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
# Set version in AssemblyInfo.cs files. | ||
Param ( | ||
[string]$rootFolder, | ||
[string]$version, | ||
[string]$filePattern = "AssemblyInfo.cs" | ||
) | ||
|
||
function UpdateAssemblyInfo() | ||
{ | ||
foreach ($file in $input) | ||
{ | ||
$path = $file.FullName | ||
Write-Host ($path) | ||
$isUpdated = $false | ||
|
||
$patternAV = '^((?!\/\/).)*\[assembly: AssemblyVersion\("(.*)"\)\]' | ||
$patternAFV = '^((?!\/\/).)*\[assembly: AssemblyFileVersion\("(.*)"\)\]' | ||
(Get-Content $path) | ForEach-Object{ | ||
if($_ -match $patternAV){ | ||
# We have found the matching line | ||
$isUpdated = $true | ||
'[assembly: AssemblyVersion("{0}")]' -f $version | ||
} elseif($_ -match $patternAFV){ | ||
$isUpdated = $true | ||
# We have found the matching line | ||
'[assembly: AssemblyFileVersion("{0}")]' -f $version | ||
} else { | ||
# Output line as is | ||
$_ | ||
} | ||
} | Set-Content $path | ||
if (!$isUpdated) { | ||
Write-Host ' Nothing found to update.' | ||
} | ||
} | ||
} | ||
|
||
Write-Host ("Root folder: " + $rootFolder) | ||
Write-Host ("File pattern: " + $filePattern) | ||
Write-Host ("Version: " + $version) | ||
|
||
Write-Host ("Updating files...") | ||
Get-Childitem -Path $rootFolder -recurse |? {$_.Name -like $filePattern} | UpdateAssemblyInfo; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
param | ||
( | ||
[string]$fileFullPath, | ||
[string]$version | ||
) | ||
|
||
[xml]$myXML = Get-Content $fileFullPath | ||
|
||
$myXML.package.metadata.version = $version | ||
|
||
$myXML.Save($fileFullPath) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters