blob: ef7776559aba0b82b95252ab1d08b709f340c385 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
using System.Management.Automation;
namespace HyperBooru.PowerShell;
[Alias("ghbuf")]
[Cmdlet(VerbsCommon.Get, "HyperBooruUploadedFile")]
public class GetUploadedFileCmdlet : SessionCmdlet {
[Parameter(Position = 1, Mandatory = true)]
public Guid MediaId { get; set; }
protected override void ProcessRecord() =>
WriteObject(Session.Media.GetUploadedFilesAsync(MediaId).GetAwaiter().GetResult());
}
|