[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M756RKB756K0PM5WGA9GWB7F":3,"skill-same:01M756RKB756K0PM5WGA9GWB7F":46},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":25,"commitSha":26,"skillDirectory":27,"forksCount":14,"repositoryHtmlUrl":28,"repositoryHomepageUrl":6,"ownerHtmlUrl":29,"ownerBlogUrl":30,"ownerDescription":6,"updatedAt":31,"install":32,"resources":45},"01M756RKB756K0PM5WGA9GWB7F","generate-testability-wrappers",null,"Generate wrapper interfaces and DI registration for hard-to-test static dependencies in C#. Produces IFileSystem, IEnvironmentProvider, IConsole, IProcessRunner wrappers, or guides adoption of TimeProvider and IHttpClientFactory. USE FOR: generate wrapper for static, create IFileSystem wrapper, wrap DateTime.Now, make static testable, make class testable, create abstraction for File.*, generate DI registration, TimeProvider adoption, IHttpClientFactory setup, testability wrapper, mock-friendly interface, mock time in tests, create the right abstraction to mock, how to mock DateTime, test code using File.ReadAllText, what abstraction for Environment, how to make statics injectable, adopt System.IO.Abstractions, make file calls testable. DO NOT USE FOR: detecting statics (use detect-static-dependencies), migrating call sites (use migrate-static-to-wrapper), general interface design not about testability.","weiflycc-cmd\u002Fskills","weiflycc-cmd","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F250846518?v=4","01M756C4PFGZJWKK04WFB9S5XF","威飛工作室","01M756C4QJJ66QDXN2RN6SXY87",0,"MIT","https:\u002F\u002Fgithub.com\u002Fweiflycc-cmd\u002Fskills\u002Fblob\u002Fmain\u002Fplugins\u002Fdotnet-test\u002Fskills\u002Fgenerate-testability-wrappers\u002FSKILL.md",[],[],"2026-11-12 13:55:43",false,"---\nname: generate-testability-wrappers\ndescription: >\n  Generate wrapper interfaces and DI registration for hard-to-test static dependencies in C#.\n  Produces IFileSystem, IEnvironmentProvider, IConsole, IProcessRunner wrappers, or guides adoption\n  of TimeProvider and IHttpClientFactory.\n  USE FOR: generate wrapper for static, create IFileSystem wrapper, wrap DateTime.Now,\n  make static testable, make class testable, create abstraction for File.*, generate\n  DI registration, TimeProvider adoption, IHttpClientFactory setup, testability wrapper,\n  mock-friendly interface, mock time in tests, create the right abstraction to mock,\n  how to mock DateTime, test code using File.ReadAllText, what abstraction for Environment,\n  how to make statics injectable, adopt System.IO.Abstractions, make file calls testable.\n  DO NOT USE FOR: detecting statics (use detect-static-dependencies), migrating call\n  sites (use migrate-static-to-wrapper), general interface design not about testability.\nlicense: MIT\n---\n\n# Generate Testability Wrappers\n\nGenerate wrapper interfaces, default implementations, and DI service registration code for untestable static dependencies. For statics that already have .NET built-in abstractions (`TimeProvider`, `IHttpClientFactory`), guide adoption of the built-in. For statics without built-in alternatives, generate custom minimal wrappers.\n\n## When to Use\n\n- After running `detect-static-dependencies` and identifying which statics to wrap\n- When the user asks to make a class testable by replacing statics with injected abstractions\n- When adopting `TimeProvider` (.NET 8+) or `System.IO.Abstractions`\n- When creating a custom wrapper for `Environment.*`, `Console.*`, or `Process.*`\n\n## When Not to Use\n\n- The user wants to find statics first (use `detect-static-dependencies`)\n- The user wants to bulk-replace call sites (use `migrate-static-to-wrapper`)\n- The static is already behind an interface\n- The project does not use dependency injection and the user does not want to add it\n\n## Inputs\n\n| Input | Required | Description |\n|-------|----------|-------------|\n| Static category | Yes | Which category: `time`, `filesystem`, `environment`, `network`, `console`, `process` |\n| Target framework | Yes | The `TargetFramework` from `.csproj` (affects which built-in abstractions exist) |\n| DI container | No | Which DI framework: `microsoft` (default), `autofac`, `none` (ambient context) |\n| Namespace | No | Target namespace for generated wrapper code |\n\n## Workflow\n\n### Step 1: Determine the abstraction strategy\n\nBased on the category and target framework:\n\n| Category | .NET 8+ | .NET 6-7 | .NET Framework |\n|----------|---------|----------|----------------|\n| Time | `TimeProvider` (built-in) | `TimeProvider` via `Microsoft.Bcl.TimeProvider` NuGet | Custom `ISystemClock` |\n| File system | `System.IO.Abstractions` (NuGet) | Same | Same |\n| HTTP | `IHttpClientFactory` (built-in) | Same | Same |\n| Environment | Custom `IEnvironmentProvider` | Same | Same |\n| Console | Custom `IConsole` | Same | Same |\n| Process | Custom `IProcessRunner` | Same | Same |\n\n### Step 2: Generate built-in abstraction adoption (Time, HTTP)\n\n#### TimeProvider (.NET 8+)\n\nNo wrapper code needed — guide the user:\n\n1. Register in DI:\n```csharp\nbuilder.Services.AddSingleton(TimeProvider.System);\n```\n\n2. Inject into classes:\n```csharp\npublic class OrderProcessor(TimeProvider timeProvider)\n{\n    public bool IsExpired(Order order)\n        => timeProvider.GetUtcNow() > order.ExpiresAt;\n}\n```\n\n3. Test with `FakeTimeProvider`:\n```csharp\n\u002F\u002F Requires Microsoft.Extensions.TimeProvider.Testing NuGet\nvar fakeTime = new FakeTimeProvider(new DateTimeOffset(2026, 1, 15, 0, 0, 0, TimeSpan.Zero));\nvar processor = new OrderProcessor(fakeTime);\nfakeTime.Advance(TimeSpan.FromDays(1));\nAssert.True(processor.IsExpired(order));\n```\n\n#### TimeProvider (pre-.NET 8)\n\nGuide: install `Microsoft.Bcl.TimeProvider` NuGet. Same API as above.\n\n#### IHttpClientFactory\n\nNo wrapper code needed — register typed clients via `builder.Services.AddHttpClient\u003CMyService>()` and inject `HttpClient` directly into the class constructor.\n\n### Step 3: Generate custom wrappers (Environment, Console, Process)\n\nFor categories without built-in abstractions, follow this template:\n\n#### Interface — define the minimal surface\n\nOnly include methods that were actually detected in the codebase. Do NOT generate a wrapper for every possible member — wrap only what is used.\n\n```csharp\nnamespace \u003CNamespace>;\n\n\u002F\u002F\u002F \u003Csummary>\n\u002F\u002F\u002F Abstraction over \u003Cstatic class> for testability. \n\u002F\u002F\u002F \u003C\u002Fsummary>\npublic interface I\u003CWrapperName>\n{\n    \u002F\u002F One method per detected static call\n    \u003Creturn type> \u003CMethodName>(\u003Cparameters>);\n}\n```\n\n#### Default implementation — delegate to the real static\n\n```csharp\nnamespace \u003CNamespace>;\n\n\u002F\u002F\u002F \u003Csummary>\n\u002F\u002F\u002F Default implementation that delegates to \u003Cstatic class>.\n\u002F\u002F\u002F \u003C\u002Fsummary>\npublic sealed class \u003CWrapperName> : I\u003CWrapperName>\n{\n    public \u003Creturn type> \u003CMethodName>(\u003Cparameters>)\n        => \u003CStaticClass>.\u003CMethod>(\u003Carguments>);\n}\n```\n\n#### DI registration\n\n```csharp\n\u002F\u002F In Program.cs or Startup.cs:\nbuilder.Services.AddSingleton\u003CI\u003CWrapperName>, \u003CWrapperName>>();\n```\n\n### Step 4: Generate file system wrapper adoption\n\nPrefer the established `System.IO.Abstractions` NuGet package over custom wrappers:\n\n1. Install the package:\n```\ndotnet add package System.IO.Abstractions\n```\n\n2. Register in DI:\n```csharp\nbuilder.Services.AddSingleton\u003CIFileSystem, FileSystem>();\n```\n\n3. Inject `IFileSystem` into classes:\n```csharp\npublic class ConfigLoader(IFileSystem fileSystem)\n{\n    public string LoadConfig(string path)\n        => fileSystem.File.ReadAllText(path);\n}\n```\n\n4. Test with `MockFileSystem`:\n```\ndotnet add \u003CTestProject> package System.IO.Abstractions.TestingHelpers\n```\n```csharp\nvar mockFs = new MockFileSystem(new Dictionary\u003Cstring, MockFileData>\n{\n    { \"\u002Fconfig.json\", new MockFileData(\"{\\\"key\\\": \\\"value\\\"}\") }\n});\nvar loader = new ConfigLoader(mockFs);\nAssert.Equal(\"{\\\"key\\\": \\\"value\\\"}\", loader.LoadConfig(\"\u002Fconfig.json\"));\n```\n\n### Step 5: Generate ambient context alternative (when DI is not available)\n\nIf the codebase does not use DI (e.g., old console app, library code), offer the ambient context pattern:\n\n```csharp\npublic static class Clock\n{\n    private static readonly AsyncLocal\u003CFunc\u003CDateTimeOffset>?> s_override = new();\n    public static DateTimeOffset UtcNow\n        => s_override.Value?.Invoke() ?? TimeProvider.System.GetUtcNow();\n\n    public static IDisposable Override(DateTimeOffset fixedTime)\n    {\n        s_override.Value = () => fixedTime;\n        return new Scope();\n    }\n    private sealed class Scope : IDisposable\n    {\n        public void Dispose() => s_override.Value = null;\n    }\n}\n```\n\nKey trade-offs: `AsyncLocal\u003CT>` ensures parallel tests don't interfere; production cost is one null check per call; the `static readonly` field is essentially free.\n\n### Step 6: Place generated files\n\nGenerate files following the project's existing conventions:\n- If there is an `Abstractions\u002F` or `Interfaces\u002F` folder, place the interface there\n- If there is an `Infrastructure\u002F` or `Services\u002F` folder, place the implementation there\n- Otherwise, create files next to the code that uses the static\n\nAlways generate:\n1. The interface file (or adoption instructions for built-in abstractions)\n2. The default implementation file\n3. The DI registration snippet (as a code comment at the bottom of the implementation, or as separate instructions)\n\n## Validation\n\n- [ ] Generated interface only wraps statics that were actually detected (not speculative)\n- [ ] Default implementation delegates to the real static with no behavior changes\n- [ ] DI registration uses `AddSingleton` for stateless wrappers, `AddTransient` for stateful ones\n- [ ] NuGet packages are recommended where established libraries exist (System.IO.Abstractions, etc.)\n- [ ] For .NET 8+, `TimeProvider` is recommended over custom `ISystemClock`\n- [ ] Ambient context pattern includes `AsyncLocal\u003CT>`, scoped disposal, and trade-off explanation\n\n## Common Pitfalls\n\n| Pitfall | Solution |\n|---------|----------|\n| Wrapping ALL members of a static class | Only wrap methods actually called in the codebase |\n| Custom time wrapper on .NET 8+ | Use built-in `TimeProvider` instead |\n| Custom file system wrapper | Prefer `System.IO.Abstractions` NuGet — battle-tested, complete |\n| Registering scoped when singleton suffices | Stateless wrappers should be `AddSingleton` |\n| Forgetting test helper packages | `Microsoft.Extensions.TimeProvider.Testing` for time, `System.IO.Abstractions.TestingHelpers` for filesystem |\n| Ambient context without `AsyncLocal` | Non-async `[ThreadStatic]` breaks with `async`\u002F`await` — always use `AsyncLocal\u003CT>` |\n","# Generate Testability Wrappers\n\nGenerate wrapper interfaces, default implementations, and DI service registration code for untestable static dependencies. For statics that already have .NET built-in abstractions (`TimeProvider`, `IHttpClientFactory`), guide adoption of the built-in. For statics without built-in alternatives, generate custom minimal wrappers.\n\n## When to Use\n\n- After running `detect-static-dependencies` and identifying which statics to wrap\n- When the user asks to make a class testable by replacing statics with injected abstractions\n- When adopting `TimeProvider` (.NET 8+) or `System.IO.Abstractions`\n- When creating a custom wrapper for `Environment.*`, `Console.*`, or `Process.*`\n\n## When Not to Use\n\n- The user wants to find statics first (use `detect-static-dependencies`)\n- The user wants to bulk-replace call sites (use `migrate-static-to-wrapper`)\n- The static is already behind an interface\n- The project does not use dependency injection and the user does not want to add it\n\n## Inputs\n\n| Input | Required | Description |\n|-------|----------|-------------|\n| Static category | Yes | Which category: `time`, `filesystem`, `environment`, `network`, `console`, `process` |\n| Target framework | Yes | The `TargetFramework` from `.csproj` (affects which built-in abstractions exist) |\n| DI container | No | Which DI framework: `microsoft` (default), `autofac`, `none` (ambient context) |\n| Namespace | No | Target namespace for generated wrapper code |\n\n## Workflow\n\n### Step 1: Determine the abstraction strategy\n\nBased on the category and target framework:\n\n| Category | .NET 8+ | .NET 6-7 | .NET Framework |\n|----------|---------|----------|----------------|\n| Time | `TimeProvider` (built-in) | `TimeProvider` via `Microsoft.Bcl.TimeProvider` NuGet | Custom `ISystemClock` |\n| File system | `System.IO.Abstractions` (NuGet) | Same | Same |\n| HTTP | `IHttpClientFactory` (built-in) | Same | Same |\n| Environment | Custom `IEnvironmentProvider` | Same | Same |\n| Console | Custom `IConsole` | Same | Same |\n| Process | Custom `IProcessRunner` | Same | Same |\n\n### Step 2: Generate built-in abstraction adoption (Time, HTTP)\n\n#### TimeProvider (.NET 8+)\n\nNo wrapper code needed — guide the user:\n\n1. Register in DI:\n```csharp\nbuilder.Services.AddSingleton(TimeProvider.System);\n```\n\n2. Inject into classes:\n```csharp\npublic class OrderProcessor(TimeProvider timeProvider)\n{\n    public bool IsExpired(Order order)\n        => timeProvider.GetUtcNow() > order.ExpiresAt;\n}\n```\n\n3. Test with `FakeTimeProvider`:\n```csharp\n\u002F\u002F Requires Microsoft.Extensions.TimeProvider.Testing NuGet\nvar fakeTime = new FakeTimeProvider(new DateTimeOffset(2026, 1, 15, 0, 0, 0, TimeSpan.Zero));\nvar processor = new OrderProcessor(fakeTime);\nfakeTime.Advance(TimeSpan.FromDays(1));\nAssert.True(processor.IsExpired(order));\n```\n\n#### TimeProvider (pre-.NET 8)\n\nGuide: install `Microsoft.Bcl.TimeProvider` NuGet. Same API as above.\n\n#### IHttpClientFactory\n\nNo wrapper code needed — register typed clients via `builder.Services.AddHttpClient\u003CMyService>()` and inject `HttpClient` directly into the class constructor.\n\n### Step 3: Generate custom wrappers (Environment, Console, Process)\n\nFor categories without built-in abstractions, follow this template:\n\n#### Interface — define the minimal surface\n\nOnly include methods that were actually detected in the codebase. Do NOT generate a wrapper for every possible member — wrap only what is used.\n\n```csharp\nnamespace \u003CNamespace>;\n\n\u002F\u002F\u002F \u003Csummary>\n\u002F\u002F\u002F Abstraction over \u003Cstatic class> for testability. \n\u002F\u002F\u002F \u003C\u002Fsummary>\npublic interface I\u003CWrapperName>\n{\n    \u002F\u002F One method per detected static call\n    \u003Creturn type> \u003CMethodName>(\u003Cparameters>);\n}\n```\n\n#### Default implementation — delegate to the real static\n\n```csharp\nnamespace \u003CNamespace>;\n\n\u002F\u002F\u002F \u003Csummary>\n\u002F\u002F\u002F Default implementation that delegates to \u003Cstatic class>.\n\u002F\u002F\u002F \u003C\u002Fsummary>\npublic sealed class \u003CWrapperName> : I\u003CWrapperName>\n{\n    public \u003Creturn type> \u003CMethodName>(\u003Cparameters>)\n        => \u003CStaticClass>.\u003CMethod>(\u003Carguments>);\n}\n```\n\n#### DI registration\n\n```csharp\n\u002F\u002F In Program.cs or Startup.cs:\nbuilder.Services.AddSingleton\u003CI\u003CWrapperName>, \u003CWrapperName>>();\n```\n\n### Step 4: Generate file system wrapper adoption\n\nPrefer the established `System.IO.Abstractions` NuGet package over custom wrappers:\n\n1. Install the package:\n```\ndotnet add package System.IO.Abstractions\n```\n\n2. Register in DI:\n```csharp\nbuilder.Services.AddSingleton\u003CIFileSystem, FileSystem>();\n```\n\n3. Inject `IFileSystem` into classes:\n```csharp\npublic class ConfigLoader(IFileSystem fileSystem)\n{\n    public string LoadConfig(string path)\n        => fileSystem.File.ReadAllText(path);\n}\n```\n\n4. Test with `MockFileSystem`:\n```\ndotnet add \u003CTestProject> package System.IO.Abstractions.TestingHelpers\n```\n```csharp\nvar mockFs = new MockFileSystem(new Dictionary\u003Cstring, MockFileData>\n{\n    { \"\u002Fconfig.json\", new MockFileData(\"{\\\"key\\\": \\\"value\\\"}\") }\n});\nvar loader = new ConfigLoader(mockFs);\nAssert.Equal(\"{\\\"key\\\": \\\"value\\\"}\", loader.LoadConfig(\"\u002Fconfig.json\"));\n```\n\n### Step 5: Generate ambient context alternative (when DI is not available)\n\nIf the codebase does not use DI (e.g., old console app, library code), offer the ambient context pattern:\n\n```csharp\npublic static class Clock\n{\n    private static readonly AsyncLocal\u003CFunc\u003CDateTimeOffset>?> s_override = new();\n    public static DateTimeOffset UtcNow\n        => s_override.Value?.Invoke() ?? TimeProvider.System.GetUtcNow();\n\n    public static IDisposable Override(DateTimeOffset fixedTime)\n    {\n        s_override.Value = () => fixedTime;\n        return new Scope();\n    }\n    private sealed class Scope : IDisposable\n    {\n        public void Dispose() => s_override.Value = null;\n    }\n}\n```\n\nKey trade-offs: `AsyncLocal\u003CT>` ensures parallel tests don't interfere; production cost is one null check per call; the `static readonly` field is essentially free.\n\n### Step 6: Place generated files\n\nGenerate files following the project's existing conventions:\n- If there is an `Abstractions\u002F` or `Interfaces\u002F` folder, place the interface there\n- If there is an `Infrastructure\u002F` or `Services\u002F` folder, place the implementation there\n- Otherwise, create files next to the code that uses the static\n\nAlways generate:\n1. The interface file (or adoption instructions for built-in abstractions)\n2. The default implementation file\n3. The DI registration snippet (as a code comment at the bottom of the implementation, or as separate instructions)\n\n## Validation\n\n- [ ] Generated interface only wraps statics that were actually detected (not speculative)\n- [ ] Default implementation delegates to the real static with no behavior changes\n- [ ] DI registration uses `AddSingleton` for stateless wrappers, `AddTransient` for stateful ones\n- [ ] NuGet packages are recommended where established libraries exist (System.IO.Abstractions, etc.)\n- [ ] For .NET 8+, `TimeProvider` is recommended over custom `ISystemClock`\n- [ ] Ambient context pattern includes `AsyncLocal\u003CT>`, scoped disposal, and trade-off explanation\n\n## Common Pitfalls\n\n| Pitfall | Solution |\n|---------|----------|\n| Wrapping ALL members of a static class | Only wrap methods actually called in the codebase |\n| Custom time wrapper on .NET 8+ | Use built-in `TimeProvider` instead |\n| Custom file system wrapper | Prefer `System.IO.Abstractions` NuGet — battle-tested, complete |\n| Registering scoped when singleton suffices | Stateless wrappers should be `AddSingleton` |\n| Forgetting test helper packages | `Microsoft.Extensions.TimeProvider.Testing` for time, `System.IO.Abstractions.TestingHelpers` for filesystem |\n| Ambient context without `AsyncLocal` | Non-async `[ThreadStatic]` breaks with `async`\u002F`await` — always use `AsyncLocal\u003CT>` |\n",{"name":5,"license":15,"description":24},"Generate wrapper interfaces and DI registration for hard-to-test static dependencies in C#. Produces IFileSystem, IEnvironmentProvider, IConsole, IProcessRunner wrappers, or guides adoption of TimeProvider and IHttpClientFactory. USE FOR: generate wrapper for static, create IFileSystem wrapper, wrap DateTime.Now, make static testable, make class testable, create abstraction for File.*, generate DI registration, TimeProvider adoption, IHttpClientFactory setup, testability wrapper, mock-friendly interface, mock time in tests, create the right abstraction to mock, how to mock DateTime, test code using File.ReadAllText, what abstraction for Environment, how to make statics injectable, adopt System.IO.Abstractions, make file calls testable. DO NOT USE FOR: detecting statics (use detect-static-dependencies), migrating call sites (use migrate-static-to-wrapper), general interface design not about testability.\n","main","5810d492c9b301d8227f932bf87b5c954c4fa4d6","plugins\u002Fdotnet-test\u002Fskills\u002Fgenerate-testability-wrappers","https:\u002F\u002Fgithub.com\u002Fweiflycc-cmd\u002Fskills","https:\u002F\u002Fgithub.com\u002Fweiflycc-cmd","weiflycc.com","2026-11-10 03:26:55",{"source":8,"skillName":5,"commands":33,"prompt":43,"zipAvailable":44},[34,37,40],{"tool":35,"command":36},"npx","npx skills add weiflycc-cmd\u002Fskills --skill generate-testability-wrappers",{"tool":38,"command":39},"bunx","bunx skills add weiflycc-cmd\u002Fskills --skill generate-testability-wrappers",{"tool":41,"command":42},"pnpm","pnpm dlx skills add weiflycc-cmd\u002Fskills --skill generate-testability-wrappers","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fweiflycc-cmd\u002Fskills\u002Fblob\u002Fmain\u002Fplugins\u002Fdotnet-test\u002Fskills\u002Fgenerate-testability-wrappers\u002FSKILL.md",true,[],[47,54,61,68,75,82],{"skillNo":48,"name":49,"nameZh":6,"description":50,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":51,"categories":52,"keywords":53,"publishedAt":19},"01M76SGT4WG5682JQJ0V3NSK6X","system-text-json-net11","Provides guidance on new System.Text.Json APIs introduced in .NET 11. It covers typed JsonTypeInfo access via GetTypeInfo\u003CT> and TryGetTypeInfo\u003CT> on JsonSerializerOptions, and the new JsonNamingPolicy.PascalCase static property. Use when serializing or deserializing JSON in .NET 11 applications and needing typed metadata access or PascalCase property naming.","https:\u002F\u002Fgithub.com\u002Fweiflycc-cmd\u002Fskills\u002Fblob\u002Fmain\u002Fplugins\u002Fdotnet11\u002Fskills\u002Fsystem-text-json-net11\u002FSKILL.md",[],[],{"skillNo":55,"name":56,"nameZh":6,"description":57,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":58,"categories":59,"keywords":60,"publishedAt":19},"01M76SGPNZYYV9BCZJW7BF7J8A","nuget-trusted-publishing","Set up NuGet trusted publishing (OIDC) on a GitHub Actions repo — replaces long-lived API keys with short-lived tokens. USE FOR: trusted publishing, NuGet OIDC, keyless NuGet publish, migrate from NuGet API key, NuGet\u002Flogin, secure NuGet publishing. DO NOT USE FOR: publishing to private feeds or Azure Artifacts (OIDC is nuget.org only). INVOKES: shell (powershell or bash), edit, create, ask_user for guided repo setup.","https:\u002F\u002Fgithub.com\u002Fweiflycc-cmd\u002Fskills\u002Fblob\u002Fmain\u002Fplugins\u002Fdotnet\u002Fskills\u002Fnuget-trusted-publishing\u002FSKILL.md",[],[],{"skillNo":62,"name":63,"nameZh":6,"description":64,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":65,"categories":66,"keywords":67,"publishedAt":19},"01M76SGHVNBNVM1DMVDYTMAE5G","dotnet-pinvoke","Correctly call native (C\u002FC++) libraries from .NET using P\u002FInvoke and LibraryImport. Covers function signatures, string marshalling, memory lifetime, SafeHandle, and cross-platform patterns. USE FOR: writing new P\u002FInvoke or LibraryImport declarations, reviewing or debugging existing native interop code, wrapping a C or C++ library for use in .NET, diagnosing crashes, memory leaks, or corruption at the managed\u002Fnative boundary. DO NOT USE FOR: COM interop, C++\u002FCLI mixed-mode assemblies, or pure managed code with no native dependencies.","https:\u002F\u002Fgithub.com\u002Fweiflycc-cmd\u002Fskills\u002Fblob\u002Fmain\u002Fplugins\u002Fdotnet\u002Fskills\u002Fdotnet-pinvoke\u002FSKILL.md",[],[],{"skillNo":69,"name":70,"nameZh":6,"description":71,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":72,"categories":73,"keywords":74,"publishedAt":19},"01M76SGDB9Z3GSB1CFW314NC84","csharp-scripts","Run file-based C# apps with the .NET CLI when the user explicitly wants C#\u002F.NET code without creating a project. Use for C# language\u002FAPI experiments, one-file C# apps, small multi-file C# apps composed with `#:include`\u002F`#:exclude`, or C# file-based apps linked with `#:ref`. Do not use for language-agnostic throwaway scripts, generic computations, Python\u002FPowerShell-style automation, full projects, or existing app integration.","https:\u002F\u002Fgithub.com\u002Fweiflycc-cmd\u002Fskills\u002Fblob\u002Fmain\u002Fplugins\u002Fdotnet\u002Fskills\u002Fcsharp-scripts\u002FSKILL.md",[],[],{"skillNo":76,"name":77,"nameZh":6,"description":78,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":79,"categories":80,"keywords":81,"publishedAt":19},"01M76SG805T8W764WAKB1NP3CJ","thread-abort-migration","Guides migration of .NET Framework Thread.Abort usage to cooperative cancellation in modern .NET. USE FOR: modernizing code that calls Thread.Abort, catching ThreadAbortException, replacing Thread.ResetAbort, replacing Thread.Interrupt for thread termination, resolving PlatformNotSupportedException or SYSLIB0006 after retargeting to .NET 6+, migrating ASP.NET Response.End or Response.Redirect(url, true) which internally call Thread.Abort. DO NOT USE FOR: code that only uses Thread.Join, Thread.Sleep, or Thread.Start without any abort, interrupt, or ThreadAbortException usage — these APIs work identically in modern .NET and need no migration. Also not for projects staying on .NET Framework, or Thread.Abort usage inside third-party libraries you do not control.","https:\u002F\u002Fgithub.com\u002Fweiflycc-cmd\u002Fskills\u002Fblob\u002Fmain\u002Fplugins\u002Fdotnet-upgrade\u002Fskills\u002Fthread-abort-migration\u002FSKILL.md",[],[],{"skillNo":83,"name":84,"nameZh":6,"description":85,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":86,"categories":87,"keywords":88,"publishedAt":19},"01M76SG2588ZJBE5C51HYJJSKV","migrate-nullable-references","Enable nullable reference types in a C# project and systematically resolve all warnings. USE FOR: adopting NRTs in existing codebases, file-by-file or project-wide migration, fixing CS8602\u002FCS8618\u002FCS86xx warnings, annotating APIs for nullability, cleaning up null-forgiving operators, upgrading dependencies with new nullable annotations. DO NOT USE FOR: projects already fully migrated with zero warnings (unless auditing suppressions), fixing a handful of nullable warnings in code that already has NRTs enabled, suppressing warnings without fixing them, C# 7.3 or earlier projects. INVOKES: Get-NullableReadiness.ps1 scanner script.","https:\u002F\u002Fgithub.com\u002Fweiflycc-cmd\u002Fskills\u002Fblob\u002Fmain\u002Fplugins\u002Fdotnet-upgrade\u002Fskills\u002Fmigrate-nullable-references\u002FSKILL.md",[],[]]