A few various changes

- Fixed the '-local' flag to accept host and port
- Added a '-debug' flag to accept a file to write debug log messages
- Added some logic which will force the dark background flag on if MacOS is in dark mode
This commit is contained in:
Leon Mika 2022-06-16 22:00:25 +10:00
parent 47e404aff7
commit 41af399215
18 changed files with 191 additions and 68 deletions

View file

@ -56,9 +56,9 @@ outer:
func (p *Provider) Put(ctx context.Context, param models.SSMParameter, override bool) error {
in := &ssm.PutParameterInput{
Name: aws.String(param.Name),
Type: param.Type,
Value: aws.String(param.Value),
Name: aws.String(param.Name),
Type: param.Type,
Value: aws.String(param.Value),
Overwrite: override,
}
if param.Type == types.ParameterTypeSecureString {
@ -71,4 +71,14 @@ func (p *Provider) Put(ctx context.Context, param models.SSMParameter, override
}
return nil
}
}
func (p *Provider) Delete(ctx context.Context, param models.SSMParameter) error {
_, err := p.client.DeleteParameter(ctx, &ssm.DeleteParameterInput{
Name: aws.String(param.Name),
})
if err != nil {
return errors.Wrap(err, "unable to delete SSM parameter")
}
return nil
}