Skip to content

feat: Add .NET Client SDK examples (console + MAUI) - #4

Merged
jsonbailey merged 3 commits into
mainfrom
jb/sdk-2561/client-sdk
Aug 4, 2026
Merged

feat: Add .NET Client SDK examples (console + MAUI)#4
jsonbailey merged 3 commits into
mainfrom
jb/sdk-2561/client-sdk

Conversation

@jsonbailey

@jsonbailey jsonbailey commented Jun 18, 2026

Copy link
Copy Markdown
Contributor

Summary

Migrates both examples from launchdarkly/hello-dotnet-client into examples-dotnet, following the EXAM layout.

Layout

client-sdk/
├── README.md                       # index (Getting Started + Frameworks)
├── getting-started/                # console app (Flag Retrieval)
│   ├── DotNetConsoleApp.csproj
│   ├── Program.cs
│   ├── README.md
│   └── NOTICE                      # Copyright 2023
└── frameworks/
    └── maui/                       # .NET MAUI app (Android & iOS)
        ├── MauiApp.csproj
        ├── global.json             # scoped here, not repo root
        ├── Platforms/ Resources/ ...
        ├── README.md
        └── NOTICE                  # Copyright 2023
  • Partition named after the package (LaunchDarkly.ClientSdkclient-sdk/).
  • Console → getting-started/; MAUI → frameworks/maui/ (per EXAM, frameworks hold runtime-specific examples).
  • global.json (SDK 8.0) scoped to the MAUI dir so it doesn't constrain the other examples.
  • MAUI appsettings.json (holds the mobile key) is gitignored; appsettings.example.json is committed.
  • Per-example NOTICE files carry the old repo's 2023 copyright; all migrated text files BOM-stripped; binary assets (fonts/images) copied as-is.

CI (client.yml, ported from the old repo's recipe)

  • build-and-run (ubuntu): build console, fetch mobile/flag keys, configure MAUI appsettings, install maui-android, build the MAUI APK, run it on an Android emulator (verify-maui-android.sh), and run the console app via verify-hello-app (mobile key).
  • build-maui (macOS): build MAUI for Android + iOS.
  • Actions pinned per convention (third-party → SHA + version; LD actions → major tag).

Notes / caveats

  • The MAUI/emulator CI can't be verified locally (no MAUI workload/emulator here) — it'll get its first real run on this PR; may need an iteration. The console app builds clean locally.
  • This relies on the OIDC trust + use_mobile_key SSM params (/sdk/common/hello-apps/mobile-key), already used by the old repo.
  • Reconciliation with feat: Add .NET Server AI SDK examples #2: when build.yml (introduced in feat: Add .NET Server AI SDK examples #2) lands, its glob should exclude client-sdk/frameworks/maui/ (MAUI can't build in the generic loop); the console is fine to keep in the generic build.

Part of SDK-2559. Covers the migration portion of SDK-2561 (old-repo README repoint + Terraform archive tracked on that ticket).

Jira: SDK-2561


Note

Low Risk
Example and CI-only changes; mobile keys stay out of git via gitignore and SSM-injected CI config. No production auth or server paths modified.

Overview
Adds a new client-sdk/ partition with LaunchDarkly.ClientSdk samples: a getting-started console app and a .NET MAUI app (Android/iOS) that evaluate a boolean flag and react to live flag changes.

CI introduces client-sdk.yml: builds the console app, pulls mobile/flag keys from SSM, writes MAUI appsettings.json, builds the Android APK, runs verify-maui-android.sh on an emulator (UI text check), and verifies the console via verify-hello-app. A macOS job builds MAUI for Android and iOS.

Repo hygiene: appsettings.json is gitignored; root README and examples-dotnet.sln list the new projects; MAUI keeps a scoped global.json (SDK 8.0).

Reviewed by Cursor Bugbot for commit 5ff8fa3. Bugbot is set up for automated code reviews on this repo. Configure here.

@jsonbailey
jsonbailey force-pushed the jb/sdk-2561/client-sdk branch 2 times, most recently from 4ea8326 to 6f4656b Compare June 18, 2026 15:57
@jsonbailey

Copy link
Copy Markdown
Contributor Author

Updated to per-slice CI: the workflow is now client-sdk.yml, path-filtered to client-sdk/**. This supersedes the description's "reconciliation with #2 / exclude MAUI from build.yml" note — there's no generic build.yml to reconcile with anymore.

@jsonbailey
jsonbailey force-pushed the jb/sdk-2561/client-sdk branch from 6f4656b to 1ffd83d Compare June 18, 2026 17:04
@jsonbailey
jsonbailey marked this pull request as ready for review July 22, 2026 20:19
@jsonbailey
jsonbailey requested a review from a team as a code owner July 22, 2026 20:19
Migrates the examples from launchdarkly/hello-dotnet-client into the client-sdk/
partition following the EXAM layout:
- console app -> client-sdk/getting-started/ (Flag Retrieval)
- .NET MAUI app -> client-sdk/frameworks/maui/ (Android & iOS)
Adds the partition README index, per-example NOTICE files (2023), the root README
row, and a gitignore for the MAUI appsettings (keys). Ports the old repo's CI as
client.yml (console build+run via verify-hello-app mobile key; MAUI Android
build+emulator-run on ubuntu; MAUI Android+iOS build on macOS), applying the action
pinning convention. Sourced from hello-dotnet-client (SDK-2561).
@jsonbailey
jsonbailey force-pushed the jb/sdk-2561/client-sdk branch from 1ffd83d to 05323c6 Compare July 31, 2026 21:16
Ports launchdarkly/hello-dotnet-client#21: the macOS runner image no longer ships the Android API 34 platform, so add an InstallAndroidDependencies step before the macOS MAUI Android build.

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 246f130. Configure here.

Comment thread examples-dotnet.sln
A single root examples-dotnet.sln (all 9 example projects across the slices) so the repo loads as one solution in an IDE on clone.
@jsonbailey
jsonbailey force-pushed the jb/sdk-2561/client-sdk branch from 246f130 to 5ff8fa3 Compare August 4, 2026 18:19
@jsonbailey
jsonbailey merged commit e7b7464 into main Aug 4, 2026
4 checks passed
@jsonbailey
jsonbailey deleted the jb/sdk-2561/client-sdk branch August 4, 2026 21:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants