Skip to content
Snippets Groups Projects
Commit 28d8fc46 authored by Georges Racinet's avatar Georges Racinet
Browse files

RepositoryService.WriteRef: special ref target can be any revision

Found out about this while testing with the Rails app. Of course,
it is natural for symbolic refs, and doesn't sound very logical
with normal refs, a result of under-specification ultimately due
to the fact that Gitaly simply uses `git update-ref`.

We keep refusing ref target revisions for keep-arounds because
we are much surer that the Rails app will only use full SHAs as
target revisions. Also, it swallows exceptions, avoiding failures
if `WriteRef` refuses to create the keep-around
(see `Gitlab::Git::KeepAround`).

We should have a Gitaly comparison test for this, but we already
have RSpec tests in the Rails app, so this can be in a follow-up.
parent 5cc50c9c
No related branches found
No related tags found
1 merge request!49GitLab special refs: second round of implementation
Pipeline #19517 passed with warnings
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment