This repository was archived by the owner on Jun 21, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +29
-7
lines changed
Expand file tree Collapse file tree 1 file changed +29
-7
lines changed Original file line number Diff line number Diff line change 77
88 <Import Project =" $(SolutionDir)\src\common\signing.props" />
99
10- <ItemGroup Condition =" $(Buildtype) == 'Internal'" >
11- <Compile Remove =" ApiClientConfiguration_User.cs" />
12- <Compile Include =" ..\..\script\src\ApiClientConfiguration_User.cs" >
13- <Link >ApiClientConfiguration_User.cs</Link >
14- </Compile >
15- </ItemGroup >
16-
10+ <Target Name =" AddClientSecret" BeforeTargets =" BeforeCompile" Condition =" $(Buildtype) == 'Internal'"
11+ Inputs =" $(MSBuildThisFileFullPath)" Outputs =" $(IntermediateOutputPath)ApiClientConfiguration_User.cs" >
12+ <Error Condition =" '$(GitHubVS_ClientId)' == ''" Text =" Please define a 'GitHubVS_ClientId' environment variable" />
13+ <Error Condition =" '$(GitHubVS_ClientSecret)' == ''" Text =" Please define a 'GitHubVS_ClientSecret' environment variable" />
14+ <PropertyGroup >
15+ <GeneratedFilePath >$(IntermediateOutputPath)ApiClientConfiguration_User.cs</GeneratedFilePath >
16+ <GeneratedText >
17+ <![CDATA[
18+ namespace GitHub.Api
19+ {
20+ static partial class ApiClientConfiguration
21+ {
22+ static partial void Configure()
23+ {
24+ ClientId = "$(GitHubVS_ClientId)"%3b
25+ ClientSecret = "$(GitHubVS_ClientSecret)"%3b
26+ }
27+ }
28+ }
29+ ]]>
30+ </GeneratedText >
31+ </PropertyGroup >
32+ <ItemGroup >
33+ <Compile Remove =" ApiClientConfiguration_User.cs" />
34+ <Compile Include =" $(GeneratedFilePath)" />
35+ </ItemGroup >
36+ <WriteLinesToFile File =" $(GeneratedFilePath)" Lines =" $(GeneratedText)" WriteOnlyWhenDifferent =" true" Overwrite =" true" />
37+ </Target >
38+
1739 <ItemGroup >
1840 <Reference Include =" System.ComponentModel.Composition" />
1941 <Reference Include =" System.Net.Http" />
You can’t perform that action at this time.
0 commit comments