From e400a0bebe21c41a0085b688653cf631bec0ef13 Mon Sep 17 00:00:00 2001 From: Hamish Duff <99325835+duffh@users.noreply.github.com> Date: Thu, 9 Nov 2023 20:47:58 +0000 Subject: [PATCH 01/11] Merge `main` into `v.next` (#1318) Co-authored-by: William Bohrmann <118313312+williambohrmann3@users.noreply.github.com> Co-authored-by: Andy Weis Co-authored-by: Zack Allen <16495151+ZackAllen@users.noreply.github.com> Co-authored-by: Morten Nielsen <1378165+dotMorten@users.noreply.github.com> Co-authored-by: William Bohrmann Co-authored-by: Preeti Co-authored-by: Morten Nielsen Co-authored-by: Greg De Stigter Co-authored-by: Teja Balu <83402878+tejabalu@users.noreply.github.com> --- .github/workflows/Open_PR.yml | 61 +++++++++++++++++++ .../AddCustomDynamicEntityDataSource.xaml.cs | 2 +- .../WPF.Viewer/ArcGIS.WPF.Viewer.Net.csproj | 8 ++- .../AddCustomDynamicEntityDataSource.xaml.cs | 2 +- .../AddCustomDynamicEntityDataSource.xaml.cs | 2 +- 5 files changed, 71 insertions(+), 4 deletions(-) create mode 100644 .github/workflows/Open_PR.yml diff --git a/.github/workflows/Open_PR.yml b/.github/workflows/Open_PR.yml new file mode 100644 index 0000000000..02af5172f1 --- /dev/null +++ b/.github/workflows/Open_PR.yml @@ -0,0 +1,61 @@ +name: Sync v.next with main + +# PRs are completed with squash and merge option - this commit will be cherry-picked for v.next. +on: + push: + branches: + - main + +jobs: + sync_branches: + runs-on: ubuntu-latest + steps: + + # Clone just the main branch of the samples repo. + - name: Checkout code + uses: actions/checkout@v2 + with: + ref: main + fetch-depth: 2 + + # Cherry-pick the most recent commit from main into v.next. + - name: Cherry-pick from main into v.next + env: + GITHUB_TOKEN: ${{ secrets.BOT_TOKEN }} + run: | + # Configure the bot's git identity. + git config --global user.name "ArcGIS Maps SDK [bot]" + git config --global user.email "arcgis-maps-sdk-bot@esri.com" + + # Store the commit hash of the most recent commit from main. + COMMIT_HASH=$(git rev-parse HEAD) + + # Name the target branch. + SYNC_BRANCH="sync/$COMMIT_HASH" + + # Pull v.next and branch off with the cherry-picked commit. + git fetch --depth=2 origin v.next + git switch v.next + git branch $SYNC_BRANCH + git switch $SYNC_BRANCH + git cherry-pick $COMMIT_HASH + + # Push the new head branch to the remote and try to open a PR. + git push -u origin $SYNC_BRANCH + if ! git diff --quiet v.next; then + echo "Diff detected." + gh pr create \ + --title "[Automated] Sync v.next with main" \ + --body "This PR was automaticaly opened to update v.next with the most recent commit from main." \ + --head "$SYNC_BRANCH" \ + --base "v.next" || CANNOT_OPEN_PR=$? + if [ -n "$CANNOT_OPEN_PR" ]; then + echo "Failed to open PR." + git branch -D $SYNC_BRANCH + else + echo "PR successfully opened." + fi + else + echo "No diff detected." + git branch -D $SYNC_BRANCH + fi diff --git a/src/MAUI/Maui.Samples/Samples/Layers/AddCustomDynamicEntityDataSource/AddCustomDynamicEntityDataSource.xaml.cs b/src/MAUI/Maui.Samples/Samples/Layers/AddCustomDynamicEntityDataSource/AddCustomDynamicEntityDataSource.xaml.cs index 1fe562bad7..0a44ec5ee0 100644 --- a/src/MAUI/Maui.Samples/Samples/Layers/AddCustomDynamicEntityDataSource/AddCustomDynamicEntityDataSource.xaml.cs +++ b/src/MAUI/Maui.Samples/Samples/Layers/AddCustomDynamicEntityDataSource/AddCustomDynamicEntityDataSource.xaml.cs @@ -30,7 +30,7 @@ namespace ArcGIS.Samples.AddCustomDynamicEntityDataSource public partial class AddCustomDynamicEntityDataSource { // Path to AIS Traffic Data json file. - private readonly string _localJsonFile = DataManager.GetDataFolder("a8a942c228af4fac96baa78ad60f511f", "AIS_MarineCadastre_SelectedVessels_CustomDataSource.json"); + private readonly string _localJsonFile = DataManager.GetDataFolder("a8a942c228af4fac96baa78ad60f511f", "AIS_MarineCadastre_SelectedVessels_CustomDataSource.jsonl"); public AddCustomDynamicEntityDataSource() { diff --git a/src/WPF/WPF.Viewer/ArcGIS.WPF.Viewer.Net.csproj b/src/WPF/WPF.Viewer/ArcGIS.WPF.Viewer.Net.csproj index 0c9fcb81d1..025095d1fd 100644 --- a/src/WPF/WPF.Viewer/ArcGIS.WPF.Viewer.Net.csproj +++ b/src/WPF/WPF.Viewer/ArcGIS.WPF.Viewer.Net.csproj @@ -2,7 +2,7 @@ WinExe - net8.0-windows10.0.19041.0 + net8.0-windows10.0.19041.0;net472 true true True @@ -18,6 +18,7 @@ 10.0.19041.0 $(DefineConstants);TRACE;NET_CORE_3 1701;1702;CA1416 + AnyCPU @@ -67,6 +68,11 @@ + + + + + PreserveNewest diff --git a/src/WPF/WPF.Viewer/Samples/Layers/AddCustomDynamicEntityDataSource/AddCustomDynamicEntityDataSource.xaml.cs b/src/WPF/WPF.Viewer/Samples/Layers/AddCustomDynamicEntityDataSource/AddCustomDynamicEntityDataSource.xaml.cs index c9db7fd37c..cf26e698ef 100644 --- a/src/WPF/WPF.Viewer/Samples/Layers/AddCustomDynamicEntityDataSource/AddCustomDynamicEntityDataSource.xaml.cs +++ b/src/WPF/WPF.Viewer/Samples/Layers/AddCustomDynamicEntityDataSource/AddCustomDynamicEntityDataSource.xaml.cs @@ -33,7 +33,7 @@ namespace ArcGIS.WPF.Samples.AddCustomDynamicEntityDataSource public partial class AddCustomDynamicEntityDataSource { // Path to AIS Traffic Data json file. - private readonly string _localJsonFile = DataManager.GetDataFolder("a8a942c228af4fac96baa78ad60f511f", "AIS_MarineCadastre_SelectedVessels_CustomDataSource.json"); + private readonly string _localJsonFile = DataManager.GetDataFolder("a8a942c228af4fac96baa78ad60f511f", "AIS_MarineCadastre_SelectedVessels_CustomDataSource.jsonl"); public AddCustomDynamicEntityDataSource() { diff --git a/src/WinUI/ArcGIS.WinUI.Viewer/Samples/Layers/AddCustomDynamicEntityDataSource/AddCustomDynamicEntityDataSource.xaml.cs b/src/WinUI/ArcGIS.WinUI.Viewer/Samples/Layers/AddCustomDynamicEntityDataSource/AddCustomDynamicEntityDataSource.xaml.cs index 75d81a8584..f883640ec6 100644 --- a/src/WinUI/ArcGIS.WinUI.Viewer/Samples/Layers/AddCustomDynamicEntityDataSource/AddCustomDynamicEntityDataSource.xaml.cs +++ b/src/WinUI/ArcGIS.WinUI.Viewer/Samples/Layers/AddCustomDynamicEntityDataSource/AddCustomDynamicEntityDataSource.xaml.cs @@ -32,7 +32,7 @@ namespace ArcGIS.WinUI.Samples.AddCustomDynamicEntityDataSource public partial class AddCustomDynamicEntityDataSource { // Path to AIS Traffic Data json file. - private readonly string _localJsonFile = DataManager.GetDataFolder("a8a942c228af4fac96baa78ad60f511f", "AIS_MarineCadastre_SelectedVessels_CustomDataSource.json"); + private readonly string _localJsonFile = DataManager.GetDataFolder("a8a942c228af4fac96baa78ad60f511f", "AIS_MarineCadastre_SelectedVessels_CustomDataSource.jsonl"); public AddCustomDynamicEntityDataSource() { From 223e4f92e459d7d864bce0604423a9f5a07dde6a Mon Sep 17 00:00:00 2001 From: Hamish Duff <99325835+duffh@users.noreply.github.com> Date: Mon, 13 Nov 2023 14:10:10 +0000 Subject: [PATCH 02/11] New sample: Define clustering feature reduction (#1316) --- ...gFeatureReductionToAPointFeatureLayer.xaml | 87 +++++++++ ...atureReductionToAPointFeatureLayer.xaml.cs | 179 +++++++++++++++++ ...ngfeaturereductiontoapointfeaturelayer.jpg | Bin 0 -> 64592 bytes .../readme.md | 43 ++++ .../readme.metadata.json | 39 ++++ src/MAUI/readme.md | 1 + .../Resources/FeaturedSamples.xml | 5 +- ...ngFeatureReductionToAPointFeatureLayer.jpg | Bin 0 -> 57550 bytes ...gFeatureReductionToAPointFeatureLayer.xaml | 96 +++++++++ ...atureReductionToAPointFeatureLayer.xaml.cs | 184 ++++++++++++++++++ .../readme.md | 43 ++++ .../readme.metadata.json | 39 ++++ src/WPF/readme.md | 1 + .../ArcGIS.WinUI.Viewer.csproj | 8 +- ...ngFeatureReductionToAPointFeatureLayer.jpg | Bin 0 -> 62554 bytes ...gFeatureReductionToAPointFeatureLayer.xaml | 85 ++++++++ ...atureReductionToAPointFeatureLayer.xaml.cs | 183 +++++++++++++++++ .../readme.md | 43 ++++ .../readme.metadata.json | 39 ++++ src/WinUI/readme.md | 1 + 20 files changed, 1070 insertions(+), 6 deletions(-) create mode 100644 src/MAUI/Maui.Samples/Samples/Layers/AddClusteringFeatureReductionToAPointFeatureLayer/AddClusteringFeatureReductionToAPointFeatureLayer.xaml create mode 100644 src/MAUI/Maui.Samples/Samples/Layers/AddClusteringFeatureReductionToAPointFeatureLayer/AddClusteringFeatureReductionToAPointFeatureLayer.xaml.cs create mode 100644 src/MAUI/Maui.Samples/Samples/Layers/AddClusteringFeatureReductionToAPointFeatureLayer/addclusteringfeaturereductiontoapointfeaturelayer.jpg create mode 100644 src/MAUI/Maui.Samples/Samples/Layers/AddClusteringFeatureReductionToAPointFeatureLayer/readme.md create mode 100644 src/MAUI/Maui.Samples/Samples/Layers/AddClusteringFeatureReductionToAPointFeatureLayer/readme.metadata.json create mode 100644 src/WPF/WPF.Viewer/Samples/Layers/AddClusteringFeatureReductionToAPointFeatureLayer/AddClusteringFeatureReductionToAPointFeatureLayer.jpg create mode 100644 src/WPF/WPF.Viewer/Samples/Layers/AddClusteringFeatureReductionToAPointFeatureLayer/AddClusteringFeatureReductionToAPointFeatureLayer.xaml create mode 100644 src/WPF/WPF.Viewer/Samples/Layers/AddClusteringFeatureReductionToAPointFeatureLayer/AddClusteringFeatureReductionToAPointFeatureLayer.xaml.cs create mode 100644 src/WPF/WPF.Viewer/Samples/Layers/AddClusteringFeatureReductionToAPointFeatureLayer/readme.md create mode 100644 src/WPF/WPF.Viewer/Samples/Layers/AddClusteringFeatureReductionToAPointFeatureLayer/readme.metadata.json create mode 100644 src/WinUI/ArcGIS.WinUI.Viewer/Samples/Layers/AddClusteringFeatureReductionToAPointFeatureLayer/AddClusteringFeatureReductionToAPointFeatureLayer.jpg create mode 100644 src/WinUI/ArcGIS.WinUI.Viewer/Samples/Layers/AddClusteringFeatureReductionToAPointFeatureLayer/AddClusteringFeatureReductionToAPointFeatureLayer.xaml create mode 100644 src/WinUI/ArcGIS.WinUI.Viewer/Samples/Layers/AddClusteringFeatureReductionToAPointFeatureLayer/AddClusteringFeatureReductionToAPointFeatureLayer.xaml.cs create mode 100644 src/WinUI/ArcGIS.WinUI.Viewer/Samples/Layers/AddClusteringFeatureReductionToAPointFeatureLayer/readme.md create mode 100644 src/WinUI/ArcGIS.WinUI.Viewer/Samples/Layers/AddClusteringFeatureReductionToAPointFeatureLayer/readme.metadata.json diff --git a/src/MAUI/Maui.Samples/Samples/Layers/AddClusteringFeatureReductionToAPointFeatureLayer/AddClusteringFeatureReductionToAPointFeatureLayer.xaml b/src/MAUI/Maui.Samples/Samples/Layers/AddClusteringFeatureReductionToAPointFeatureLayer/AddClusteringFeatureReductionToAPointFeatureLayer.xaml new file mode 100644 index 0000000000..f707182dd0 --- /dev/null +++ b/src/MAUI/Maui.Samples/Samples/Layers/AddClusteringFeatureReductionToAPointFeatureLayer/AddClusteringFeatureReductionToAPointFeatureLayer.xaml @@ -0,0 +1,87 @@ + + + + + +