You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
#lockdown Nick.Penwarden #rb none ========================== MAJOR FEATURES + CHANGES ========================== Change 3035988 on 2016/07/01 by James.Brinkerhoff Hotfix from CL 3032831 for UHT compile error on Windows 10 machines Change 3034711 on 2016/06/30 by Peter.Sauerbrei latest provision to go with latest certificate Change 3032018 on 2016/06/28 by Shon.Love #ocn, #mcp: Fixed create clan call. Change 3031372 on 2016/06/28 by David.Nikdel #Ocean: Post-Integration fixup commit Change 3030867 on 2016/06/28 by Scott.Bowen #ocean - Integrate changes from //WEX/... to allow importing Json attributes to apply to an item when created on Mcp. Change 3030859 on 2016/06/28 by Shon.Love #ocn, #mcp: Fixed Mac compiler errors. Change 3030595 on 2016/06/28 by Shon.Love #ocn, #mcp: Updated Groups implementation to interact with latest API. Change 3030549 on 2016/06/28 by Shon.Love #ocn, #mcp: Fixed nullptr-dereference if an async method disappeared/changed while still referenced by a blueprint. Crash would happen if you put your mouse of the 'missing async method' node in the blueprint editor. Change 3028705 on 2016/06/27 by Ian.Fox Duplicating 3027482 from //Orion/Main Read TaggedPropertyRedirects from all config files to allow plugins to register property redirectors You'll need this before you grab the latest OGF or your catalog prices will go away, so here it is now #ue4 #tests none Change 2993102 on 2016/05/27 by James.Brinkerhoff Hotfix from CL 2985226 for UE-30995 - Player built walls have default material (for Orlando's material error X8000) Change 2989818 on 2016/05/25 by James.Brinkerhoff Hotfix from 2989681 for UHT rebuilding when it doesn't need to Change 2984539 on 2016/05/19 by James.Brinkerhoff Making some changes to the script to generate the changelist description for copying up streams to UE4 Main based on game dev stream needs - Adding a lockdown parameter - Calculating the last changelist for game dev streams from the second of the input changelist range - Ignoring case for CodeReview and RB tags - Defining a separate source stream for game dev streams Change 2984055 on 2016/05/19 by James.Brinkerhoff Merging //UE4/Ocean-Staging to //Ocean/Main [CL 3040652 by James Brinkerhoff in Main branch]
106 lines
3.7 KiB
C#
106 lines
3.7 KiB
C#
// Copyright 1998-2016 Epic Games, Inc. All Rights Reserved.
|
|
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.Diagnostics;
|
|
using System.IO;
|
|
using System.Text.RegularExpressions;
|
|
using System.Threading;
|
|
using System.Reflection;
|
|
using System.Linq;
|
|
using AutomationTool;
|
|
using UnrealBuildTool;
|
|
|
|
namespace AutomationTool
|
|
{
|
|
/// <summary>
|
|
/// Generates a changelist description for copying a stream to its parent
|
|
/// </summary>
|
|
[RequireP4]
|
|
public class StreamCopyDescription : BuildCommand
|
|
{
|
|
/// <summary>
|
|
/// Execute the command
|
|
/// </summary>
|
|
public override void ExecuteBuild()
|
|
{
|
|
// Get the source and target streams
|
|
string Stream = ParseParamValue("Stream", P4Env.BuildRootP4);
|
|
string Changes = ParseParamValue("Changes", null);
|
|
string Lockdown = ParseParamValue("Lockdown", "Nick.Penwarden");
|
|
|
|
// Get changes which haven't been copied up from the current stream
|
|
string Descriptions;
|
|
string SourceStream;
|
|
int LastCl;
|
|
if (Changes == null)
|
|
{
|
|
ProcessResult Result = P4.P4(String.Format("interchanges -l -S {0}", Stream), AllowSpew: false);
|
|
Descriptions = Result.Output.Replace("\r\n", "\n");
|
|
SourceStream = Stream;
|
|
|
|
// Get the last submitted change in the source stream
|
|
List<P4Connection.ChangeRecord> ChangeRecords;
|
|
if (!P4.Changes(out ChangeRecords, String.Format("-m1 {0}/...", SourceStream), AllowSpew: false))
|
|
{
|
|
throw new AutomationException("Couldn't get changes for this branch");
|
|
}
|
|
LastCl = ChangeRecords[0].CL;
|
|
}
|
|
else
|
|
{
|
|
ProcessResult Result = P4.P4(String.Format("changes -l {0}", Changes), AllowSpew: false);
|
|
Descriptions = Result.Output.Replace("\r\n", "\n");
|
|
SourceStream = Regex.Replace(Changes, @"(\/(?:\/[^\/]*){2}).*", "$1");
|
|
LastCl = Int32.Parse(Regex.Replace(Changes, ".*,", ""));
|
|
}
|
|
|
|
// Clean any workspace names that may reveal internal information
|
|
Descriptions = Regex.Replace(Descriptions, "(Change[^@]*)@.*", "$1", RegexOptions.Multiline);
|
|
|
|
// Remove changes by the build machine
|
|
Descriptions = Regex.Replace(Descriptions, "[^\n]*buildmachine\n(\n|\t[^\n]*\n)*", "");
|
|
|
|
// Figure out the target stream
|
|
ProcessResult StreamResult = P4.P4(String.Format("stream -o {0}", Stream), AllowSpew: false);
|
|
if (StreamResult.ExitCode != 0)
|
|
{
|
|
throw new AutomationException("Couldn't get stream description for {0}", Stream);
|
|
}
|
|
string Target = P4Spec.FromString(StreamResult.Output).GetField("Parent");
|
|
if(Target == null)
|
|
{
|
|
throw new AutomationException("Couldn't get parent stream for {0}", Stream);
|
|
}
|
|
|
|
// Write the output file
|
|
string OutputDirName = Path.Combine(CommandUtils.CmdEnv.LocalRoot, "Engine", "Intermediate");
|
|
CommandUtils.CreateDirectory(OutputDirName);
|
|
string OutputFileName = Path.Combine(OutputDirName, "Changes.txt");
|
|
using (StreamWriter Writer = new StreamWriter(OutputFileName))
|
|
{
|
|
Writer.WriteLine("Copying {0} to {1} (Source: {2} @ {3})", Stream, Target.Trim(), SourceStream, LastCl);
|
|
Writer.WriteLine("#lockdown {0}", Lockdown);
|
|
Writer.WriteLine();
|
|
Writer.WriteLine("==========================");
|
|
Writer.WriteLine("MAJOR FEATURES + CHANGES");
|
|
Writer.WriteLine("==========================");
|
|
Writer.WriteLine();
|
|
|
|
foreach (string Line in Descriptions.Split('\n'))
|
|
{
|
|
string TrimLine = Line.TrimStart();
|
|
if(!TrimLine.StartsWith("#codereview", StringComparison.OrdinalIgnoreCase) && !TrimLine.StartsWith("#rb", StringComparison.OrdinalIgnoreCase) && !TrimLine.StartsWith("#lockdown", StringComparison.OrdinalIgnoreCase))
|
|
{
|
|
Writer.WriteLine(Line);
|
|
}
|
|
}
|
|
}
|
|
Log("Written {0}.", OutputFileName);
|
|
|
|
// Open it with the default text editor
|
|
Process.Start(OutputFileName);
|
|
}
|
|
}
|
|
}
|