Skip to content

Don't reset custom metadata when not specified#89

Merged
lmars merged 1 commit intomasterfrom
dont-reset-custom-meta
Jul 26, 2015
Merged

Don't reset custom metadata when not specified#89
lmars merged 1 commit intomasterfrom
dont-reset-custom-meta

Conversation

@lmars
Copy link
Copy Markdown
Contributor

@lmars lmars commented Jul 26, 2015

If I do the following:

tuf add --custom '{"foo":"bar"}' foo.txt
tuf add bar.txt
tuf add

I expect foo.txt to keep the metadata I give it, but that doesn't currently happen as tuf add will set metadata of all staged files to nil.

I have updated the logic to maintain custom metadata if the user hasn't specified any.

If I do the following:

```
tuf add --custom '{"foo":"bar"}' foo.txt
tuf add bar.txt
tuf add
```

I expect foo.txt to keep the metadata I give it, but that doesn't
currently happen as `tuf add` will set metadata of all staged files to
nil.

I have updated the logic to maintain custom metadata if the user hasn't
specified any.

Signed-off-by: Lewis Marshall <lewis@lmars.net>
@titanous
Copy link
Copy Markdown
Contributor

LGTM.

lmars added a commit that referenced this pull request Jul 26, 2015
Don't reset custom metadata when not specified
@lmars lmars merged commit 55659a6 into master Jul 26, 2015
@lmars lmars deleted the dont-reset-custom-meta branch July 26, 2015 14:41
rdimitrov added a commit to rdimitrov/go-tuf that referenced this pull request Jan 25, 2024
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