Merge remote-tracking branch 'origin/main' into darc-main-fc6e47e2-7b69-4464-b65f-8f67ca26b4e8
This commit is contained in:
Коммит
e652068e5e
|
@ -677,6 +677,7 @@
|
|||
<Ditto
|
||||
SessionId="$(BuildSessionId)"
|
||||
Condition="'$(IsMacEnabled)' == 'true'"
|
||||
CopyFromWindows="true"
|
||||
ToolExe="$(DittoExe)"
|
||||
ToolPath="$(DittoPath)"
|
||||
Source="%(_DirectoriesToPublish.SourceDirectory)"
|
||||
|
@ -1563,6 +1564,7 @@
|
|||
SessionId="$(BuildSessionId)"
|
||||
Condition="'$(IsMacEnabled)' == 'true'"
|
||||
AdditionalArguments="-x -k"
|
||||
CopyFromWindows="true"
|
||||
Source="%(_CompressedAppleBindingResourcePackage.Identity)"
|
||||
Destination="$(_IntermediateDecompressionDir)/%(Filename)"
|
||||
>
|
||||
|
@ -1610,6 +1612,7 @@
|
|||
SessionId="$(BuildSessionId)"
|
||||
Condition="'$(IsMacEnabled)' == 'true'"
|
||||
AdditionalArguments="-x -k"
|
||||
CopyFromWindows="true"
|
||||
Source="%(_CompressedPlugIns.Identity)"
|
||||
Destination="$(_IntermediateDecompressionDir)/%(Filename)%(Extension)"
|
||||
>
|
||||
|
@ -1656,6 +1659,7 @@
|
|||
SessionId="$(BuildSessionId)"
|
||||
Condition="'$(IsMacEnabled)' == 'true'"
|
||||
AdditionalArguments="-x -k"
|
||||
CopyFromWindows="true"
|
||||
Source="%(_CompressedAppleFrameworks.Identity)"
|
||||
Destination="$(_IntermediateFrameworksDir)/%(Filename)%(Extension)"
|
||||
>
|
||||
|
|
|
@ -13,6 +13,16 @@ namespace Xamarin.MacDev.Tasks
|
|||
|
||||
public string? AdditionalArguments { get; set; }
|
||||
|
||||
// If the input directory should be copied from Windows to the Mac in
|
||||
// a remote build. In some cases we only maintain empty files on
|
||||
// Windows to keep track of modified files, so that we don't have to
|
||||
// transfer the entire file back to Windows, and in those cases we
|
||||
// don't want to copy the empty content back to the Mac. In other
|
||||
// cases the input comes from Windows, and in that case we want to
|
||||
// copy the entire input to the Mac - so we need an option to select
|
||||
// the mode.
|
||||
public bool CopyFromWindows { get; set; }
|
||||
|
||||
[Required]
|
||||
public ITaskItem? Source { get; set; }
|
||||
|
||||
|
|
|
@ -35,6 +35,9 @@ namespace Xamarin.MacDev.Tasks
|
|||
if (!Directory.Exists(Source.ItemSpec))
|
||||
return Enumerable.Empty<ITaskItem> ();
|
||||
|
||||
if (!CopyFromWindows)
|
||||
return Enumerable.Empty<ITaskItem> ();
|
||||
|
||||
// TaskRunner doesn't know how to copy directories to Mac but `ditto` can take directories (and that's why we use ditto often).
|
||||
// If Source is a directory path, let's add each file within it as an TaskItem, as TaskRunner knows how to copy files to Mac.
|
||||
return Directory.GetFiles (Source.ItemSpec, "*", SearchOption.AllDirectories)
|
||||
|
|
Загрузка…
Ссылка в новой задаче