Skip to content

Commit

Permalink
added explicit net45 build for aspnetcore50, moved minimatcher to be …
Browse files Browse the repository at this point in the history
…a source reference
  • Loading branch information
Mpdreamz committed Feb 13, 2015
1 parent 334ceb6 commit d0182e4
Show file tree
Hide file tree
Showing 16 changed files with 1,187 additions and 36 deletions.
7 changes: 7 additions & 0 deletions EditorConfig.sln
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,15 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution
build\chocolatey.nuspec = build\chocolatey.nuspec
build\nuget.nuspec = build\nuget.nuspec
README.md = README.md
sign.snk = sign.snk
EndProjectSection
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EditorConfig.App", "src\EditorConfig.App\EditorConfig.App.csproj", "{D7CD5DEF-002E-4463-9FE8-AC6676DAA36C}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EditorConfig.Tests", "src\EditorConfig.Tests\EditorConfig.Tests.csproj", "{F65280C8-E47C-48D1-B99A-33CB4C594FCB}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EditorConfig.Core.NET45", "src\EditorConfig.Core.NET45\EditorConfig.Core.NET45.csproj", "{F22050E7-E2C3-47BC-8B06-5BFE163FF045}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand All @@ -38,6 +41,10 @@ Global
{F65280C8-E47C-48D1-B99A-33CB4C594FCB}.Debug|Any CPU.Build.0 = Debug|Any CPU
{F65280C8-E47C-48D1-B99A-33CB4C594FCB}.Release|Any CPU.ActiveCfg = Release|Any CPU
{F65280C8-E47C-48D1-B99A-33CB4C594FCB}.Release|Any CPU.Build.0 = Release|Any CPU
{F22050E7-E2C3-47BC-8B06-5BFE163FF045}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{F22050E7-E2C3-47BC-8B06-5BFE163FF045}.Debug|Any CPU.Build.0 = Debug|Any CPU
{F22050E7-E2C3-47BC-8B06-5BFE163FF045}.Release|Any CPU.ActiveCfg = Release|Any CPU
{F22050E7-E2C3-47BC-8B06-5BFE163FF045}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down
3 changes: 2 additions & 1 deletion build/build.fsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
// include Fake lib
#r @"tools/FAKE/tools/FakeLib.dll"
#I @"tools/FAKE/tools"
#r "FakeLib.dll"
open Fake
open System
open SemVerHelper
Expand Down
6 changes: 3 additions & 3 deletions build/nuget.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@
<licenseUrl>https://raw.github.com/editorconfig/editorconfig-core/master/LICENSE</licenseUrl>
<requireLicenseAcceptance>false</requireLicenseAcceptance>
<iconUrl>http://editorconfig.org/logo.png</iconUrl>
<dependencies>
<dependency id="Minimatch" version="1.1.0.0" />
</dependencies>
</metadata>
<files>
<file src="output\EditorConfig.Core.NET45\EditorConfig.Core.dll" target="lib\net45"/>
<file src="output\EditorConfig.Core.NET45\EditorConfig.Core.pdb" target="lib\net45"/>
<file src="output\EditorConfig.Core.NET45\EditorConfig.Core.XML" target="lib\net45"/>
<file src="output\EditorConfig.Core\EditorConfig.Core.dll" target="lib"/>
<file src="output\EditorConfig.Core\EditorConfig.Core.pdb" target="lib"/>
<file src="output\EditorConfig.Core\EditorConfig.Core.XML" target="lib"/>
Expand Down
2 changes: 0 additions & 2 deletions packages/repositories.config
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<repositories>
<repository path="..\src\EditorConfig.App\packages.config" />
<repository path="..\src\EditorConfig.Core\packages.config" />
<repository path="..\src\EditorConfig.Tests\packages.config" />
</repositories>
File renamed without changes.
4 changes: 0 additions & 4 deletions src/EditorConfig.App/EditorConfig.App.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,6 @@
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="Minimatch">
<HintPath>..\..\packages\Minimatch.1.1.0.0\lib\portable-net40+sl50+win+wp80\Minimatch.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
Expand All @@ -51,7 +48,6 @@
</ItemGroup>
<ItemGroup>
<None Include="App.config" />
<None Include="packages.config" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\EditorConfig.Core\EditorConfig.Core.csproj">
Expand Down
4 changes: 0 additions & 4 deletions src/EditorConfig.App/packages.config

This file was deleted.

83 changes: 83 additions & 0 deletions src/EditorConfig.Core.NET45/EditorConfig.Core.NET45.csproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{F22050E7-E2C3-47BC-8B06-5BFE163FF045}</ProjectGuid>
<OutputType>Library</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>EditorConfig.Core</RootNamespace>
<AssemblyName>EditorConfig.Core</AssemblyName>
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<DocumentationFile>bin\Debug\EditorConfig.Core.XML</DocumentationFile>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup>
<SignAssembly>true</SignAssembly>
</PropertyGroup>
<PropertyGroup>
<AssemblyOriginatorKeyFile>..\..\sign.snk</AssemblyOriginatorKeyFile>
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Data" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="..\EditorConfig.Core\Charset.cs">
<Link>Charset.cs</Link>
</Compile>
<Compile Include="..\EditorConfig.Core\EditorConfigFile.cs">
<Link>EditorConfigFile.cs</Link>
</Compile>
<Compile Include="..\EditorConfig.Core\EditorConfigParser.cs">
<Link>EditorConfigParser.cs</Link>
</Compile>
<Compile Include="..\EditorConfig.Core\EndOfLine.cs">
<Link>EndOfLine.cs</Link>
</Compile>
<Compile Include="..\EditorConfig.Core\FileConfiguration.cs">
<Link>FileConfiguration.cs</Link>
</Compile>
<Compile Include="..\EditorConfig.Core\IndentSize.cs">
<Link>IndentSize.cs</Link>
</Compile>
<Compile Include="..\EditorConfig.Core\IndentStyle.cs">
<Link>IndentStyle.cs</Link>
</Compile>
<Compile Include="..\EditorConfig.Core\Minimatcher.cs">
<Link>Minimatcher.cs</Link>
</Compile>
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>
36 changes: 36 additions & 0 deletions src/EditorConfig.Core.NET45/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;

// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("EditorConfig.Core.NET45")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("EditorConfig.Core.NET45")]
[assembly: AssemblyCopyright("Copyright © 2015")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]

// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]

// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("d4fc2924-b345-44a1-b360-821c1478ba50")]

// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]
10 changes: 2 additions & 8 deletions src/EditorConfig.Core/EditorConfig.Core.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -36,12 +36,9 @@
<SignAssembly>true</SignAssembly>
</PropertyGroup>
<PropertyGroup>
<AssemblyOriginatorKeyFile>sign.snk</AssemblyOriginatorKeyFile>
<AssemblyOriginatorKeyFile>..\..\sign.snk</AssemblyOriginatorKeyFile>
</PropertyGroup>
<ItemGroup>
<Reference Include="Minimatch">
<HintPath>..\..\packages\Minimatch.1.1.0.0\lib\portable-net40+sl50+win+wp80\Minimatch.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
Expand All @@ -58,12 +55,9 @@
<Compile Include="EditorConfigParser.cs" />
<Compile Include="IndentSize.cs" />
<Compile Include="IndentStyle.cs" />
<Compile Include="Minimatcher.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<ItemGroup>
<None Include="packages.config" />
<None Include="sign.snk" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
Expand Down
5 changes: 2 additions & 3 deletions src/EditorConfig.Core/EditorConfigParser.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
using System.Text;
using System.Text.RegularExpressions;
using System.Threading.Tasks;
using Minimatch;

namespace EditorConfig.Core
{
Expand All @@ -27,7 +26,7 @@ public class EditorConfigParser
/// </summary>
public static readonly Version Version = new Version(VersionString);

private readonly Options _globOptions = new Options { MatchBase = true, Dot = true, NoExt = true };
private readonly EditorConfigMinimatcherOptions _globOptions = new EditorConfigMinimatcherOptions { MatchBase = true, Dot = true, NoExt = true };

/// <summary>
/// The configured name of the files holding editorconfig values, defaults to ".editorconfig"
Expand Down Expand Up @@ -95,7 +94,7 @@ from kv in section

private bool IsMatch(string glob, string fileName, string directory)
{
var matcher = new Minimatcher(glob, _globOptions);
var matcher = new EditorConfigMinimatcher(glob, _globOptions);
var isMatch = matcher.IsMatch(fileName);
Debug.WriteLine("{0} :: {1} \t\t:: {2}", isMatch ? "?" : "?", glob, fileName);
return isMatch;
Expand Down
Loading

0 comments on commit d0182e4

Please sign in to comment.