dub
dub copied to clipboard
fatal: '--detach' cannot be used with '-b/-B/--orphan' when referencing branch w/ git repository dependency.
trafficstars
Adding the following reference to my dub.sdl
dependency "numem" repository="git+https://github.com/Inochi2D/numem.git" version="~i2d08"
causes the operation to fail with
fatal: '--detach' cannot be used with '-b/-B/--orphan'
Additionally while cleaning up after itself it fails to delete files with an access denied error.
Error G:\Users\cli-l\AppData\Local\dub\packages\numem\~i2d08\numem\.git\objects\pack\pack-a49445ab8a5c158b02592e980832c3cf0cb48845.idx: Access is denied.
Full exception: std.file.FileException@std\file.d(1065): G:\Users\cli-l\AppData\Local\dub\packages\numem\~i2d08\numem\.git\objects\pack\pack-a49445ab8a5c158b02592e980832c3cf0cb48845.idx: Access is denied.
The file is likely still open at the point of deletion in https://github.com/dlang/dub/blob/master/source/dub/internal/git.d#L164; that or dub should ask for higher priviledges from the user on Windows.