Skip to content
This repository was archived by the owner on Jan 12, 2024. It is now read-only.

Commit 60767d2

Browse files
authored
Merge pull request #2 from microsoft/beheim/oss
Missing copyright headers
2 parents 1d1c14a + 7913e6d commit 60767d2

File tree

27 files changed

+129
-105
lines changed

27 files changed

+129
-105
lines changed

PRIVACY.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
# Privacy
22

3-
The code in this repository contains features that may enable you and Microsoft to collect data from users of the applications.
4-
The data collection is disabled by default but can be enabled by setting the corresponding flag upon compilation.
3+
The code in this repository contains features that may enable you and Microsoft to collect data from users of the applications. Data collection is disabled by default but can be enabled by setting the corresponding flag upon compilation.
54

65
## Data Collection
76

build/Set-VersionNumbers.ps1

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
param(
2+
[string]
3+
$AssemblyVersion = $Env:ASSEMBLY_VERSION,
4+
5+
[string]
6+
$SemverVersion = $Env:SEMVER_VERSION,
7+
8+
[string]
9+
$NuGetVersion = $Env:NUGET_VERSION,
10+
11+
[string]
12+
$VsixVersion = $Env:VSIX_VERSION,
13+
14+
[switch]
15+
$EnableTelemetry
16+
);
17+
18+
if ("$AssemblyVersion".Trim().Length -eq 0) {
19+
$Date = Get-Date;
20+
$Year = $Date.Year.ToString().Substring(2);
21+
$Month = $Date.Month.ToString().PadLeft(2, "0");
22+
$Hour = (Get-Date).Hour.ToString().PadLeft(2, "0");
23+
$Minute = (Get-Date).Minute.ToString().PadLeft(2, "0");
24+
$AssemblyVersion = "0.0.$Year$Month.$Hour$Minute";
25+
}
26+
27+
if ("$SemverVersion".Trim().Length -eq 0) {
28+
$pieces = "$AssemblyVersion".split(".");
29+
$SemverVersion = "$($pieces[0]).$($pieces[1]).$($pieces[2])$($pieces[3])";
30+
}
31+
32+
if ("$NuGetVersion".Trim().Length -eq 0) {
33+
$NuGetVersion = "$AssemblyVersion-alpha";
34+
}
35+
36+
if ("$VsixVersion".Trim().Length -eq 0) {
37+
$VsixVersion = "$AssemblyVersion";
38+
}
39+
40+
Get-ChildItem -Recurse *.v.template `
41+
| ForEach-Object {
42+
$Source = $_.FullName;
43+
$Target = $Source.Substring(0, $Source.Length - 11);
44+
Write-Verbose "Replacing ASSEMBLY_VERSION with $AssemblyVersion in $Source and writing to $Target.";
45+
Get-Content $Source `
46+
| ForEach-Object {
47+
$_.
48+
Replace("#ASSEMBLY_VERSION#", $AssemblyVersion).
49+
Replace("#NUGET_VERSION#", $NuGetVersion).
50+
Replace("#VSIX_VERSION#", $VsixVersion).
51+
Replace("#SEMVER_VERSION#", $SemverVersion).
52+
Replace("#ENABLE_TELEMETRY#", $EnableTelemetry.IsPresent.ToString().ToLower())
53+
} `
54+
| Set-Content $Target -NoNewline
55+
}

build/bootstrap.cmd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ dotnet --info || GOTO missingDotnet
66
git --version || GOTO missingGit
77

88
:: Set Build number on all files that uses it
9-
CALL build\setVersionNumber.cmd
9+
call powershell -NoProfile build\Set-VersionNumbers.ps1
1010

1111
:: Initialize the compiler's nuspec file
1212
CALL :nuspecBootstrap

build/setVersionNumber.cmd

Lines changed: 0 additions & 29 deletions
This file was deleted.

src/ProjectTemplates/.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
Quantum.App1/Quantum.App1.csproj
2+
Quantum.Library1/Quantum.Library1.csproj
3+
Quantum.Test1/Quantum.Test1.csproj

src/QsCompiler/CommandLineTool/QsCommandLineTool.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<PropertyGroup>
55
<AssemblyName>qsc</AssemblyName>
66
<AssemblyTitle>Microsoft Q# compiler command line tool.</AssemblyTitle>
7-
<TargetFramework>netcoreapp2.2</TargetFramework>
7+
<TargetFramework>netcoreapp2.1</TargetFramework>
88
<OutputType>Exe</OutputType>
99
</PropertyGroup>
1010

src/QsCompiler/LanguageServer/QsLanguageServer.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
<PropertyGroup>
55
<AssemblyName>Microsoft.Quantum.QsLanguageServer</AssemblyName>
6-
<TargetFramework>netcoreapp2.2</TargetFramework>
6+
<TargetFramework>netcoreapp2.1</TargetFramework>
77
<OutputType>Exe</OutputType>
88
</PropertyGroup>
99
<PropertyGroup>

src/QsCompiler/Tests.Compiler/Tests.Compiler.fsproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFramework>netcoreapp2.2</TargetFramework>
4+
<TargetFramework>netcoreapp2.1</TargetFramework>
55
<IsPackable>false</IsPackable>
66
<AssemblyName>Tests.Microsoft.Quantum.QsCompiler</AssemblyName>
77
<OutputType>Library</OutputType>

src/QsCompiler/Tests.DocGenerator/Tests.DocGenerator.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFramework>netcoreapp2.2</TargetFramework>
4+
<TargetFramework>netcoreapp2.1</TargetFramework>
55
<IsPackable>false</IsPackable>
66
<RootNamespace>Microsoft.Quantum.QsCompiler.Documentation.Testing</RootNamespace>
77
<AssemblyName>Tests.Microsoft.Quantum.QsDocumentationParser</AssemblyName>

src/QsCompiler/Tests.LanguageServer/Tests.LanguageServer.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFramework>netcoreapp2.2</TargetFramework>
4+
<TargetFramework>netcoreapp2.1</TargetFramework>
55
<IsPackable>false</IsPackable>
66
<AssemblyName>Tests.Microsoft.Quantum.QsLanguageServer</AssemblyName>
77
<OutputType>Library</OutputType>

0 commit comments

Comments
 (0)