diff options
| author | Jake Mannens <jake@asger.xyz> | 2026-05-18 16:59:16 +1000 |
|---|---|---|
| committer | Jake Mannens <jake@asger.xyz> | 2026-05-18 16:59:16 +1000 |
| commit | ab46387d4d02e30b171a7c2fa07947b41ec691a0 (patch) | |
| tree | 0e3311e320de78476917e073d4f2ef954624a24a /AddImplicitTag.cs | |
| parent | 7b17bd8ef7ee8b3391fea3bf7a9e1866be92e81b (diff) | |
Diffstat (limited to 'AddImplicitTag.cs')
| -rw-r--r-- | AddImplicitTag.cs | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/AddImplicitTag.cs b/AddImplicitTag.cs new file mode 100644 index 0000000..50f6cfc --- /dev/null +++ b/AddImplicitTag.cs @@ -0,0 +1,17 @@ +using HyperBooru.ApiClient; +using System.Management.Automation; + +namespace HyperBooru.PowerShell; + +[Alias("ahbit")] +[Cmdlet(VerbsCommon.Add, "HyperBooruImplicitTag")] +public class AddImplicitTagCmdlet : PSCmdlet { + [Parameter(Mandatory = true)] public required HBSession Session { get; set; } + [Parameter(Mandatory = true)] public required Guid TagDefinitionId { get; set; } + [Parameter(Mandatory = true)] public required Guid[] ImplicitTagId { get; set; } + + protected override void ProcessRecord() => + Session.Tag.AddImplicitTagsAsync(TagDefinitionId, ImplicitTagId) + .GetAwaiter() + .GetResult(); +} |
