This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static class PublishUtils | |
{ | |
public static void CreateAndPublishQueue(Database sourceDatabase, Database[] targetDatabases, Language[] targetLanguages, IEnumerable<ID> itemIds, bool skipEvents = false, bool useSecurityDisabler = true) | |
{ | |
Assert.IsNotNull(sourceDatabase, "sourceDatabase"); | |
Assert.IsNotNull(targetDatabases, "targetDatabases"); | |
Assert.IsNotNull(targetLanguages, "targetLanguages"); | |
var publishingCandidates = SetPublishingCandidates(sourceDatabase, targetDatabases, targetLanguages, itemIds); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Param( | |
[string]$pathToPackages | |
) | |
Add-Type -AssemblyName System.IO.Compression.FileSystem | |
function Unzip | |
{ | |
param([string]$zipfile, [string]$outpath) | |
[System.IO.Compression.ZipFile]::ExtractToDirectory($zipfile, $outpath) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Description("Publishes deployed items after deployment using publishing queue.\nPublishing targets are specified in the Parameter as a comma separated list.")] | |
public class PublishDeployedItemsWithPublishingQueue : IPostDeployAction | |
{ | |
/// <summary> | |
/// Borrowed directly from HedgehogDevelopment.SitecoreProject.PackageInstallPostProcessor.BuiltIn.PublishDeployedItems, HedgehogDevelopment.SitecoreProject.PackageInstallPostProcessor | |
/// </summary> | |
private static Database[] GetPublishingTargetDatabases(string parameters) | |
{ | |
if (string.IsNullOrEmpty(parameters)) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8" ?> | |
<configuration xmlns:patch="http://www.sitecore.net/xmlconfig/"> | |
<sitecore> | |
<pipelines> | |
<getScreenShotForURL> | |
<!-- Disable security check --> | |
<processor type="Sitecore.ContentTesting.Pipelines.GetScreenShotForURL.CheckDisabler, Sitecore.ContentTesting"> | |
<patch:delete /> | |
</processor> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using Sitecore.ContentTesting.Pipelines.GetScreenShotForURL; | |
namespace MyLibrary.GetScreenShotForURL | |
{ | |
public class AddTimeoutToScript : GenerateScreenShotProcessor | |
{ | |
public string Timeout { get; set; } | |
private const string StandardExit = "phantom.exit();\r\n});"; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using PdfSharp.Drawing; | |
using PdfSharp.Pdf; | |
using Sitecore.ContentTesting.Pipelines.GetScreenShotForURL; | |
namespace MyLibrary.GetScreenShotForURL | |
{ | |
public class GeneratePdf : GenerateScreenShotProcessor | |
{ | |
public override void Process(GetScreenShotForURLArgs args) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var args = new GetScreenShotForURLArgs(item.ID); | |
CorePipeline.Run("getScreenShotForURL", args); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[DataContract] | |
public class LogMessageRemoteEvent : IHasEventName | |
{ | |
public LogMessageRemoteEvent(string instanceName, string eventName) | |
{ | |
InstanceName = instanceName; | |
EventName = eventName; | |
} | |
// This is the custom data you will be passing between servers |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class LogMessageRemoteMap | |
{ | |
public void Initialize(PipelineArgs args) | |
{ | |
EventManager.Subscribe<LogMessageRemoteEvent>(new Action<LogMessageRemoteEvent>(OnGenericRemoteEvent<LogMessageRemoteEvent>)); | |
} | |
private static void OnGenericRemoteEvent<TEvent>(TEvent @event) where TEvent : IHasEventName | |
{ | |
RemoteEventArgs<TEvent> remoteEventArgs = new RemoteEventArgs<TEvent>(@event); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8" ?> | |
<configuration xmlns:patch="http://www.sitecore.net/xmlconfig/"> | |
<sitecore> | |
<pipelines> | |
<initialize> | |
<processor type="MyNamespace.LogMessageRemoteMap, MyDll" method="Initialize" /> | |
</initialize> | |
</pipelines> | |
</sitecore> | |
</configuration> |
OlderNewer