libgit2 / libgit2/libgit2sharp
Can't push all tags
Đang mở
Chưa có ai nhận issue này.
- Ngôn ngữ chính
- C#
- Star
- 3.5k
- Fork
- 925
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Mô tả
When I try to push all tags, I get this exception:
LibGit2Sharp.LibGit2SharpException: not a valid reference 'refs/tags/*'
at LibGit2Sharp.Core.Ensure.HandleError(Int32 result)
at LibGit2Sharp.Core.Proxy.git_remote_push(RemoteHandle remote, IEnumerable`1 refSpecs, GitPushOptions opts)
at LibGit2Sharp.Network.Push(Remote remote, IEnumerable`1 pushRefSpecs, PushOptions pushOptions)
at CallSite.Target(Closure , CallSite , Object , Object , Object , Object )
Here's my PowerShell code:
$pushOptions = New-Object -TypeName 'LibGit2Sharp.PushOptions'
$repo = New-Object 'LibGit2Sharp.Repository' ($RepoRoot)
$remote = $repo.Network.Remotes | Where-Object { $_.Name -eq 'origin' }
$repo.Network.Push($remote, 'refs/tags/*', $pushOptions)
I've also tried using refs/tags/*:refs/tags/* as the refspec, but that fails too. I can push individual tags with refspec refs/tags/tag_name.
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Hướng nghiên cứu
Bắt đầu với ví dụ PowerShell và entry point Repository.Network.Push, so sánh refspec của từng tag riêng lẻ với các dạng wildcard được trình bày trong issue. Tái hiện exception bằng PushOptions và refs/tags/*, sau đó lần theo cách refspec được xử lý. Hoàn thành khi push tất cả các tag thành công mà không gặp lỗi tham chiếu không hợp lệ.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- csharp, git
- Lĩnh vực
- devtools
- Loại issue
- Lỗi
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 38/100