vcstool
vcstool copied to clipboard
Could not checkout ref '...': fatal: invalid reference
trafficstars
Sometimes could not checkout ref error happens.
Steps to reproduce:
- Create a repo with
1_2_3_20201010branch (ex: https://github.com/andry81-tests/vcstool-test-A) - Switch to master branch:
git switch --orphan master - Create
.externals:repositories: _externals/1_2_3_20201010: type: git url: https://github.com/andry81-tests/vcstool-test-A version: 1_2_3_20201010 - Import
.externals:vcs import < .externals=== ._externals/1_2_3_20201010 (git) === Could not checkout ref '12320201010': fatal: invalid reference: 12320201010
>git --version
git version 2.24.0.windows.2
Seems bug in the yaml parser, because this works:
repositories:
_externals/1_2_3_20201010:
type: git
url: https://github.com/andry81-tests/vcstool-test-A
version: '1_2_3_20201010'