Skip to content

Commit

Permalink
Merge branch 'release/6.1.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
jstemerdink committed Sep 5, 2022
2 parents 73f9eaa + 96d1787 commit 4ebb92a
Show file tree
Hide file tree
Showing 4 changed files with 40 additions and 21 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -152,3 +152,4 @@ $RECYCLE.BIN/

.vs/
*.orig
modules/
30 changes: 17 additions & 13 deletions EPi.Libraries.BlockSearch.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
<AssemblyOriginatorKeyFile>EPiServer.Libraries.snk</AssemblyOriginatorKeyFile>
</PropertyGroup>
<PropertyGroup>
<TargetFramework>net5.0</TargetFramework>
<TargetFrameworks>net5.0;net6.0</TargetFrameworks>
<GenerateAssemblyInfo>true</GenerateAssemblyInfo>
<GeneratePackageOnBuild>False</GeneratePackageOnBuild>
<NoWin32Manifest>true</NoWin32Manifest>
Expand All @@ -39,24 +39,28 @@
<ProduceReferenceAssembly>False</ProduceReferenceAssembly>
</PropertyGroup>
<ItemGroup>
<Content Include="readme.txt" />
<None Remove="icon.png" />
<None Remove="README.md" />
<None Remove="readme.txt" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="EPiServer.CMS.AspNetCore" Version="12.0.3" />
<PackageReference Include="EPiServer.CMS.Core" Version="12.0.3" />
<PackageReference Include="EPiServer.Framework.AspNetCore" Version="12.0.3" />
<Content Include="icon.png">
<Pack>True</Pack>
<PackagePath>\</PackagePath>
</Content>
<Content Include="README.md">
<Pack>True</Pack>
<PackagePath>\</PackagePath>
</Content>
<Content Include="readme.txt">
<Pack>True</Pack>
<PackagePath>\</PackagePath>
</Content>
</ItemGroup>
<ItemGroup>
<FrameworkReference Include="Microsoft.AspNetCore.App" />
</ItemGroup>
<ItemGroup>
<None Update="icon.png">
<Pack>True</Pack>
<PackagePath>\</PackagePath>
</None>
<None Update="README.md">
<Pack>True</Pack>
<PackagePath>\</PackagePath>
</None>
<PackageReference Include="EPiServer.CMS" Version="12.4.0" />
</ItemGroup>
</Project>
15 changes: 14 additions & 1 deletion Helper.cs
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ namespace EPi.Libraries.BlockSearch
using System;
using System.Collections.Generic;
using System.Globalization;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Text;
Expand All @@ -33,6 +34,8 @@ namespace EPi.Libraries.BlockSearch
using EPiServer.Core.Html;
using EPiServer.DataAbstraction;
using EPiServer.DataAccess;
using EPiServer.HtmlParsing;
using EPiServer.HtmlParsing.Internal;
using EPiServer.Logging;
using EPiServer.Security;
using EPiServer.ServiceLocation;
Expand Down Expand Up @@ -197,9 +200,19 @@ where typeof(PropertyContentArea).IsAssignableFrom(

try
{
string additionalSearchContent = TextIndexer.StripHtml(stringBuilder.ToString(), 0);
HtmlFilter htmlFilter = new HtmlFilter(new StripHtmlFilterRules());

StringBuilder filteredOuput = new StringBuilder();
StringWriter outputWriter = new StringWriter(filteredOuput);

htmlFilter.FilterHtml(new StringReader(stringBuilder.ToString()), outputWriter);
outputWriter.Dispose();

string additionalSearchContent = filteredOuput.ToString();

parent[index: addtionalSearchContentProperty.Name] = additionalSearchContent;

outputWriter.Dispose();
}
catch (EPiServerException epiServerException)
{
Expand Down
15 changes: 8 additions & 7 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,19 +11,20 @@ init:
- set JAVA_HOME=C:\Program Files\Java\jdk15

install:
- choco install gitversion.portable -pre -y
- cmd: nuget sources add -Name EPiServerFeed -Source http://nuget.episerver.com/feed/packages.svc/
- ps: dotnet tool install --global GitVersion.Tool --version 5.*
- ps: dotnet tool install --global dotnet-sonarscanner
- cmd: nuget sources add -Name EPiServerFeed -Source https://nuget.episerver.com/feed/packages.svc/
before_build:
- cmd: nuget restore
- ps: gitversion /l console /output buildserver /updateprojectfiles
build_script:
- dotnet tool install --global dotnet-sonarscanner
- ps: dotnet-gitversion /l console /output buildserver
build_script:
- dotnet sonarscanner begin /k:"jstemerdink:EPi.Libraries.BlockSearch" /n:"EPi.Libraries.BlockSearch" /d:"sonar.host.url=https://sonarcloud.io" /o:"jstemerdink-github" /d:"sonar.login=0b0eec6902ab7d776899f79bfeff15d313dd6e09"
- dotnet pack "EPi.Libraries.BlockSearch.sln" /p:Version=%GitVersion_MajorMinorPatch%;AssemblyVersion=%GitVersion_AssemblySemVer%;FileVersion=%GitVersion_AssemblySemFileVer%;ProductVersion=%GitVersion_MajorMinorPatch%;PackageVersion=%GitVersion_NuGetVersion%
- dotnet build "EPi.Libraries.BlockSearch.sln" --no-restore -c Release -p:Version=%GitVersion_MajorMinorPatch% -p:AssemblyVersion=%GitVersion_AssemblySemVer% -p:FileVersion=%GitVersion_AssemblySemFileVer% -p:ProductVersion=%GitVersion_MajorMinorPatch%
- dotnet pack "EPi.Libraries.BlockSearch.sln" --no-build -c Release -p:PackageVersion=%GitVersion_NuGetVersion%
- dotnet sonarscanner end /d:"sonar.login=0b0eec6902ab7d776899f79bfeff15d313dd6e09"
after_build:
- cmd: appveyor PushArtifact "%APPVEYOR_BUILD_FOLDER%\bin\Release\EPi.Libraries.BlockSearch.%GitVersion_NuGetVersion%.nupkg"
- 7z a EPi.Libraries.BlockSearch.%GitVersion_NuGetVersion%.zip %APPVEYOR_BUILD_FOLDER%\bin\Release\net5.0\EPi.Libraries.BlockSearch.dll
- 7z a EPi.Libraries.BlockSearch.%GitVersion_NuGetVersion%.zip %APPVEYOR_BUILD_FOLDER%\bin\Release\*\*.dll
- cmd: appveyor PushArtifact "EPi.Libraries.BlockSearch.%GitVersion_NuGetVersion%.zip"
before_package:
- ps: >-
Expand Down

0 comments on commit 4ebb92a

Please sign in to comment.