Skip to content

Commit

Permalink
Merge branch 'release/0.9.2'
Browse files Browse the repository at this point in the history
  • Loading branch information
emmanuelmathot committed Jun 9, 2021
2 parents 787dd5b + c5a1793 commit b376ae0
Show file tree
Hide file tree
Showing 5 changed files with 33 additions and 6 deletions.
27 changes: 26 additions & 1 deletion .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -619,7 +619,32 @@
"moduleLoad": false
}
},

{
"name": "Copy calibrated",
"type": "coreclr",
"request": "launch",
"preLaunchTask": "build",
// If you have changed target frameworks, make sure to update the program path.
"program": "${workspaceFolder}/src/Stars.Console/bin/Debug/netcoreapp3.1/Stars.dll",
"args": [
"copy",
"https://supervisor.charter.uat.esaportal.eu/catalog/calls/call-100/calibratedDatasets/S2A_MSIL1C_20200615T060641_N0209_R134_T45WWS_20200615T080720-calibrated/S2A_MSIL1C_20200615T060641_N0209_R134_T45WWS_20200615T080720-calibrated.json",
"-v",
"-af",
"red",
"-r",
"4",
"--output",
"/tmp/charter"
],
"cwd": "${workspaceFolder}/src",
// For more information about the 'console' field, see https://aka.ms/VSCode-CS-LaunchJson-Console
"console": "internalConsole",
"stopAtEntry": false,
"logging": {
"moduleLoad": false
}
},
{
"name": ".NET Core Attach",
"type": "coreclr",
Expand Down
2 changes: 1 addition & 1 deletion src/Stars.Console/Operations/CopyOperation.cs
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ private async Task<object> CopyNode(IResource node, IRouter router, object state
throw new AggregateException(deliveryReport.AssetsExceptions.Values);

if (deliveryReport.ImportedAssets.Count() > 0)
stacItemNode.StacItem.MergeAssets(deliveryReport);
stacItemNode.StacItem.MergeAssets(deliveryReport, true);
else continue;
}
break;
Expand Down
2 changes: 1 addition & 1 deletion src/Stars.Console/Terradue.Stars.Console.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFrameworks>netcoreapp3.1;net5.0</TargetFrameworks>
<Version>0.9.0</Version>
<Version>0.9.2</Version>
<Version Condition=" '$(VersionSuffix)' != '' ">$(Version)-$(VersionSuffix)</Version>
<VersionSuffix>$(VersionSuffix)</VersionSuffix>
<AssemblyName>Stars</AssemblyName>
Expand Down
6 changes: 4 additions & 2 deletions src/Stars.Services/StacResourceExtensions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,13 @@ namespace Terradue.Stars.Services
public static class StacResourceExtensions
{

public static void MergeAssets(this StacItem stacItem, IAssetsContainer assetContainer)
public static void MergeAssets(this StacItem stacItem, IAssetsContainer assetContainer, bool removeIfNotInContainer = false)
{
if ( removeIfNotInContainer )
stacItem.Assets.Clear();
foreach (var asset in assetContainer.Assets)
{
if (stacItem.Assets.ContainsKey(asset.Key))
if (stacItem.Assets.ContainsKey(asset.Key) )
{
stacItem.Assets.Remove(asset.Key);
}
Expand Down
2 changes: 1 addition & 1 deletion src/Stars.Services/Terradue.Stars.Services.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<TargetFramework>netstandard2.1</TargetFramework>
<Title>Terradue.Stars</Title>
<Description>Stars is a set of services for working with Spatio Temporal Catalog such as STAC but not only</Description>
<Version>0.9.0</Version>
<Version>0.9.2</Version>
<!-- <VersionSuffix>beta.1</VersionSuffix> -->
<AssemblyName>Terradue.Stars.Services</AssemblyName>
<PackageId>Terradue.Stars</PackageId>
Expand Down

0 comments on commit b376ae0

Please sign in to comment.