-
Hi,
It worked fine, although I wasn't sure if I used the function properly. After updating to version 3.1.30 the following git error is raised: 'fatal: couldn't find remote ref --depth'. This is because the git cmd command changed to:
Which is obviously wrong now. How do I need to change my fetch call in order to fetch a tag with some additional options for the command that may be read from a text file? Many thanks and best regards, |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 2 replies
-
Hi, similar to #1528, you were relying on a security vulnerability that allowed positional arguments to be interpreted as options (the first argument from fetch is meant to be a list of refs) Line 954 in 90c81a5 You need to pass additional options as kwargs. |
Beta Was this translation helpful? Give feedback.
-
@stsewd Thanks for the information. So at the end, if I need to remain backwards compatible and can't change the input file, then the only solution is to change my command to
? I think converting the list to a dictionary is quite complicated as an option may be used with short name or long name, may be written as "--depth=1" or "--depth 1" and may contain multiple values, a single value or no value. Best regards, |
Beta Was this translation helpful? Give feedback.
-
@Byron Many thanks. I think it is clear now for me how to use the "new" fetch function. Unfortunately, I don't know which options are provided to my function as they are read from an input file and I can't change the input file due to compatibility issues and other problems. Therefore my function still looks as follows:
In the past I was using the
This is more or less fine for me, although using the official method feels somehow better. Another option would be to convert my list of |
Beta Was this translation helpful? Give feedback.
@Byron Many thanks. I think it is clear now for me how to use the "new" fetch function. Unfortunately, I don't know which options are provided to my function as they are read from an input file and I can't change the input file due to compatibility issues and other problems. Therefore my function still looks as follows:
In the past I was using the
fetch
method of aRemote
, but I think I need to change that to use git directly:This is more or less fine for me, although using the official method feels somehow …