aptly icon indicating copy to clipboard operation
aptly copied to clipboard

fix:failed to edit repo

Open cccccarl opened this issue 3 years ago • 2 comments

return when the repo cant be found and err !=nil

Fixes #

Requirements

All new code should be covered with tests, documentation should be updated. CI should pass.

Description of the Change

The repo cant be edited

Checklist

  • [ ] unit-test added (if change is algorithm)
  • [ ] functional test added/updated (if change is functional)
  • [ ] man page updated (if applicable)
  • [ ] bash completion updated (if applicable)
  • [ ] documentation updated
  • [ ] author name in AUTHORS

cccccarl avatar Jul 18 '22 06:07 cccccarl

Codecov Report

Merging #1093 (0eafa62) into master (c9f5763) will increase coverage by 14.20%. The diff coverage is 0.00%.

@@             Coverage Diff             @@
##           master    #1093       +/-   ##
===========================================
+ Coverage   52.11%   66.31%   +14.20%     
===========================================
  Files          73      141       +68     
  Lines       11272    15890     +4618     
===========================================
+ Hits         5874    10538     +4664     
+ Misses       4832     4603      -229     
- Partials      566      749      +183     
Impacted Files Coverage Δ
api/repos.go 0.00% <0.00%> (ø)
cmd/snapshot_show.go 78.29% <0.00%> (ø)
cmd/snapshot_diff.go 84.52% <0.00%> (ø)
console/terminal.go 100.00% <0.00%> (ø)
cmd/snapshot_rename.go 84.44% <0.00%> (ø)
cmd/snapshot_merge.go 89.85% <0.00%> (ø)
cmd/mirror_show.go 84.03% <0.00%> (ø)
systemd/activation/packetconns.go 0.00% <0.00%> (ø)
cmd/api.go 100.00% <0.00%> (ø)
cmd/publish_switch.go 81.67% <0.00%> (ø)
... and 96 more

:mega: Codecov can now indicate which changes are the most critical in Pull Requests. Learn more

codecov[bot] avatar Jul 25 '22 13:07 codecov[bot]

I don't quite get what's the problem here, I would expect that when the repo already exists with the same name that it is not renamed and this is exactly how it is implementad at the moment. This is also the same behaviour as in the cli: https://github.com/aptly-dev/aptly/blob/master/cmd/repo_rename.go#L30

randombenj avatar Aug 08 '22 08:08 randombenj