Skip to content

Commit

Permalink
Series of new projects by reason of independent script engines and MIT (
Browse files Browse the repository at this point in the history
#56)

* Draft versions Varhead and LSender projects (netstd2.0 + net40). Part of #55

Updated tests. Also PascalCasing due to crazy .net convention, ie. IDE1006

* Draft of the E-MSBuild project (netstd2.0 + net40). Part of #55

* Reimplemented fixes for "Save changes to " through new VaLier

* Draft of SobaScript project. /Core (netstd2.0 + net40). Part of #55

components still are part of vssbe

* Fixed unlooping mechanism because of disabled parsing for some data

* Final draft of SobaScript, Mapper, Z.Core, Z.Ext, Z.VS /part of #55

* Recovered missing files

* fixed CI build

* Fixed vsix 7z x64 folder and NuGetComponent use of GetNuTool

* CIM __vssbe_diag flag to enable diagnostic mode

* Removed src: E-MSBuild, SobaScript, Varhead, Mapper, LSender, Z.Core, Z.Ext, Z.VS

+their tests

* +submodules SobaScript, E-MSBuild, ...

* Fixed "Method in type from assembly does not have an implementation"

also reverts old order SDK10 -> SDK15

* Fixes debug mode init and updates NuGetComponent
  • Loading branch information
3F authored Sep 19, 2019
1 parent 7904b38 commit 2033236
Show file tree
Hide file tree
Showing 186 changed files with 3,090 additions and 23,570 deletions.
15 changes: 15 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,3 +1,18 @@
[submodule "MvsSln"]
path = MvsSln
url = https://github.com/3F/MvsSln.git
[submodule "E-MSBuild"]
path = E-MSBuild
url = https://github.com/3F/E-MSBuild.git
[submodule "SobaScript"]
path = SobaScript
url = https://github.com/3F/SobaScript.git
[submodule "SobaScript.Z.Core"]
path = SobaScript.Z.Core
url = https://github.com/3F/SobaScript.Z.Core.git
[submodule "SobaScript.Z.Ext"]
path = SobaScript.Z.Ext
url = https://github.com/3F/SobaScript.Z.Ext.git
[submodule "SobaScript.Z.VS"]
path = SobaScript.Z.VS
url = https://github.com/3F/SobaScript.Z.VS.git
2 changes: 1 addition & 1 deletion .gnt/packages.config
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="vsSBE.CI.MSBuild" version="1.6.12011" output="vsSBE.CI.MSBuild" />
<package id="7z.Libs" version="16.4.0" />
<package id="vsSBE.CI.MSBuild" version="1.6.12010" output="vsSBE.CI.MSBuild" />
</packages>
34 changes: 28 additions & 6 deletions .vssbe
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@
"Mode": {
"$type": "net.r_eg.vsSBE.Events.ModeScript, vsSolutionBuildEvent",
"Type": "Script",
"Command": "$(revDeltaBase = \"2016/11/05\")\n$(revDeltaMin = $([System.Math]::Pow(10, 3)))\n$$(revDeltaMax = $([System.Math]::Pow(10, 5)))\n$(revDeltaMax = 65534) #[\" limit of AssemblyVersion (2^16 - 2) - i.e. 65534 max allowed \"]\n\n#[\" \n To restore packages via GetNuTool\n https://github.com/NuGet/Home/issues/1521\n\"]\n#[NuGet gnt.raw(\"/p:ngconfig=\\\".gnt/packages.config\\\"\")]",
"Command": "$(revDeltaBase = \"2016/11/05\")\n$(revDeltaMin = $([System.Math]::Pow(10, 3)))\n$$(revDeltaMax = $([System.Math]::Pow(10, 5)))\n$(revDeltaMax = 65534) #[\" limit of AssemblyVersion (2^16 - 2) - i.e. 65534 max allowed \"]\n\n#[\" \n To restore packages via GetNuTool\n https://github.com/NuGet/Home/issues/1521\n\"]\n##[NuGet gnt.raw(\"/p:ngconfig=\\\".gnt/packages.config\\\"\")]",
"Command__": [
"$(revDeltaBase = \"2016/11/05\")",
"$(revDeltaMin = $([System.Math]::Pow(10, 3)))",
Expand All @@ -102,7 +102,7 @@
" To restore packages via GetNuTool",
" https://github.com/NuGet/Home/issues/1521",
"\"]",
"#[NuGet gnt.raw(\"/p:ngconfig=\\\".gnt/packages.config\\\"\")]"
"##[NuGet gnt.raw(\"/p:ngconfig=\\\".gnt/packages.config\\\"\")]"
]
}
},
Expand Down Expand Up @@ -192,16 +192,38 @@
"Mode": {
"$type": "net.r_eg.vsSBE.Events.ModeScript, vsSolutionBuildEvent",
"Type": "Script",
"Command": "\r\n#[File call(\"submodules.bat\", \"$(pMvsSln)/MvsSln.sln\", 2000)]\r\n\r\n#[\" Packages \"]\r\n\r\n#[( !(#[IO exists.directory(\"packages\")]) || !(#[IO exists.directory(\"$(pMvsSln)/packages\")]) )\r\n{\r\n #[File call(\"packages.cmd\", \"\", 2000)]\r\n}]",
"Command": "#[( !(#[IO exists.file(\"$(pMvsSln)/MvsSln.sln\")]) )\n{\n #[File call(\"git\", \"submodule update --init --recursive MvsSln\", 1000)]\n}]\n\n#[( !(#[IO exists.file(\"SobaScript/SobaScript.sln\")]) )\n{\n #[File call(\"git\", \"submodule update --init --recursive SobaScript\", 1000)]\n #[File call(\"git\", \"submodule update --init --recursive E-MSBuild\", 1000)]\n}]\n\n#[( !(#[IO exists.file(\"SobaScript.Z.Core/SobaScript.Z.Core.sln\")]) )\n{\n #[File call(\"git\", \"submodule update --init --recursive SobaScript.Z.Core\", 1000)]\n #[File call(\"git\", \"submodule update --init --recursive SobaScript.Z.Ext\", 1000)]\n #[File call(\"git\", \"submodule update --init --recursive SobaScript.Z.VS\", 1000)]\n}]\n\n\n\n#[\" Packages \"]\n\n#[( !(#[IO exists.file(\"packages/__checked\")]) || !(#[IO exists.directory(\"$(pMvsSln)/packages\")]) )\n{\n #[File call(\"tools\\hmsbuild.bat\", \"-t:restore /v:q /nologo /p:Configuration=$(Configuration) /p:Platform=\\\"Any CPU\\\"\", 1000)]\n \n #[File call(\"packages.cmd\", \"\", 1000)]\n \n #[IO copy.directory(\"\", \"packages/\", true)]\n #[File write(\"packages/__checked\"): ]\n}]",
"Command__": [
"#[( !(#[IO exists.file(\"$(pMvsSln)/MvsSln.sln\")]) )",
"{",
" #[File call(\"git\", \"submodule update --init --recursive MvsSln\", 1000)]",
"}]",
"",
"#[( !(#[IO exists.file(\"SobaScript/SobaScript.sln\")]) )",
"{",
" #[File call(\"git\", \"submodule update --init --recursive SobaScript\", 1000)]",
" #[File call(\"git\", \"submodule update --init --recursive E-MSBuild\", 1000)]",
"}]",
"",
"#[( !(#[IO exists.file(\"SobaScript.Z.Core/SobaScript.Z.Core.sln\")]) )",
"{",
" #[File call(\"git\", \"submodule update --init --recursive SobaScript.Z.Core\", 1000)]",
" #[File call(\"git\", \"submodule update --init --recursive SobaScript.Z.Ext\", 1000)]",
" #[File call(\"git\", \"submodule update --init --recursive SobaScript.Z.VS\", 1000)]",
"}]",
"",
"",
"#[File call(\"submodules.bat\", \"$(pMvsSln)/MvsSln.sln\", 2000)]",
"",
"#[\" Packages \"]",
"",
"#[( !(#[IO exists.directory(\"packages\")]) || !(#[IO exists.directory(\"$(pMvsSln)/packages\")]) )",
"#[( !(#[IO exists.file(\"packages/__checked\")]) || !(#[IO exists.directory(\"$(pMvsSln)/packages\")]) )",
"{",
" #[File call(\"packages.cmd\", \"\", 2000)]",
" #[File call(\"tools\\hmsbuild.bat\", \"-t:restore /v:q /nologo /p:Configuration=$(Configuration) /p:Platform=\\\"Any CPU\\\"\", 1000)]",
" ",
" #[File call(\"packages.cmd\", \"\", 1000)]",
" ",
" #[IO copy.directory(\"\", \"packages/\", true)]",
" #[File write(\"packages/__checked\"): ]",
"}]"
]
}
Expand Down
4 changes: 4 additions & 0 deletions CI.MSBuild/EventManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,10 @@ public override void Initialize(IEventSource evt)
log = new Log(Verbosity);
initializer = new Initializer(Parameters, log);

if(!log.IsDiagnostic) {
log.info($"set {Log.DIAG_KEY}= true to enable diagnostic mode.");
}

// load with properties by default
library = initializer.load();
setPropertiesByDefault();
Expand Down
2 changes: 1 addition & 1 deletion CI.MSBuild/Initializer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ protected void header()
log.info(new String('=', 37));
log.info("Version: v{0}", System.Diagnostics.FileVersionInfo.GetVersionInfo(Assembly.GetExecutingAssembly().Location).ProductVersion);
log.info($"Copyright (c) 2013-{Math.Max(2019, DateTime.Now.Year)} Denis Kuzmin < entry.reg@gmail.com > GitHub/3F");
log.info(new String('_', 70));
log.info(new String('_', 70) + Environment.NewLine);
}

/// <summary>
Expand Down
11 changes: 10 additions & 1 deletion CI.MSBuild/Log.cs
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,21 @@ namespace net.r_eg.vsSBE.CI.MSBuild
//TODO: Either use from MvsSln or NLog from main plugin
internal class Log: ILog
{
internal const string DIAG_KEY = "__vssbe_diag";

/// <summary>
/// Flag of Diagnostic mode
/// </summary>
public bool IsDiagnostic
{
get => level == LoggerVerbosity.Diagnostic;
//level == LoggerVerbosity.Diagnostic;
get => string.Equals
(
//TODO:
Environment.GetEnvironmentVariable(DIAG_KEY, EnvironmentVariableTarget.Process)?.Trim(),
"true",
StringComparison.InvariantCultureIgnoreCase
);
}

/// <summary>
Expand Down
1 change: 1 addition & 0 deletions E-MSBuild
Submodule E-MSBuild added at a855a4
1 change: 1 addition & 0 deletions SobaScript
Submodule SobaScript added at 2c7941
1 change: 1 addition & 0 deletions SobaScript.Z.Core
Submodule SobaScript.Z.Core added at 226e08
1 change: 1 addition & 0 deletions SobaScript.Z.Ext
Submodule SobaScript.Z.Ext added at b4b40b
1 change: 1 addition & 0 deletions SobaScript.Z.VS
Submodule SobaScript.Z.VS added at 481acc
10 changes: 8 additions & 2 deletions VsixLib.targets
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
<Visible>false</Visible>
<Link>%(Filename)%(Extension)</Link>
<IncludeInVSIX>true</IncludeInVSIX>
<VSIXSubPath>x64\</VSIXSubPath>
</Content>
-->
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
Expand All @@ -22,8 +23,13 @@
<VsixLib Include="$(SolutionDir)\tools\gnt.bat" />
<VsixLib Include="$(SolutionDir)\tools\hMSBuild.bat" />

<!-- 7z.dll x86 -->
<VsixLib Include="$(SolutionDir)packages\7z.Libs.*\bin\x86\7z.dll" /><!-- packages\7z.Libs.*\bin\x86\7z.dll -->
<VsixLib Include="$(SolutionDir)packages\7z.Libs.*\bin\x86\7z.dll" />

</ItemGroup>

<ItemGroup Label="x64">

<VsixLibX64 Include="$(SolutionDir)packages\7z.Libs.*\bin\x64\7z.dll" />

</ItemGroup>

Expand Down
9 changes: 5 additions & 4 deletions build.bat
Original file line number Diff line number Diff line change
Expand Up @@ -32,15 +32,16 @@ if "%reltype%"=="" (

set __p_call=1

:: Packages
:: package restore for SDK-based projects
:: call %_msbuild% -t:restore /p:Configuration=%reltype%_SDK15 /p:Platform="Any CPU"

call .\packages.cmd || goto err
:: Activate vsSBE

:: call %_msbuild% ".gnt/gnt.core" /p:ngpath="%cd%/packages" /p:ngconfig="%cd%/.gnt/packages.config;%cd%/vsSolutionBuildEvent/packages.config;%cd%/vsSolutionBuildEventTest/packages.config" /nologo /v:m
call %_gnt% /p:ngpath="%cd%/packages" /p:ngconfig="%cd%/.gnt/packages.config" || goto err

:: Build

set bnode=%_msbuild% %sln% /m:4 /l:"%cimdll%" /p:Platform=%platform% /v:%level%
set bnode=%_msbuild% %sln% /m:4 /l:"%cimdll%" /p:Platform=%platform% /v:%level% /nologo

call %bnode% /p:Configuration=%reltype%_SDK10 /t:Rebuild || goto err
call %bnode% /p:Configuration=%reltype%_SDK15 /t:Build || goto err
Expand Down
3 changes: 2 additions & 1 deletion packages.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@

set _gnt=tools/gnt
set _gntArgs=%*
set _pkgdir=packages


:found
Expand All @@ -22,7 +23,7 @@ call %_gnt% %_gntArgs% /p:wpath="%cd%/MvsSln" /p:ngconfig="packages.config;MvsSl
:: -
echo.
echo vsSolutionBuildEvent ...
call %_gnt% %_gntArgs% /p:ngpath="%cd%/packages" /p:ngconfig="%cd%/.gnt/packages.config;%cd%/vsSolutionBuildEvent/packages.config;%cd%/vsSolutionBuildEventTest/packages.config" /nologo /v:m || goto err
call %_gnt% %_gntArgs% /p:wpath="%cd%" /p:ngpath="%_pkgdir%" /p:ngconfig=".gnt/packages.config;vsSolutionBuildEvent/packages.config;vsSolutionBuildEventTest/packages.config" /nologo /v:m || goto err

goto exit

Expand Down
47 changes: 0 additions & 47 deletions submodules.bat

This file was deleted.

Loading

0 comments on commit 2033236

Please sign in to comment.