Added a comment
authorkyle <kyle@web>
Mon, 25 Jan 2021 14:52:54 +0000 (14:52 +0000)
committeradmin <admin@branchable.com>
Mon, 25 Jan 2021 14:52:54 +0000 (14:52 +0000)
doc/bugs/git_annex_config_doesn__39__t_support_leading_dash/comment_1_2325ca78ab6270dcb2d98348a5e1c974._comment [new file with mode: 0644]

diff --git a/doc/bugs/git_annex_config_doesn__39__t_support_leading_dash/comment_1_2325ca78ab6270dcb2d98348a5e1c974._comment b/doc/bugs/git_annex_config_doesn__39__t_support_leading_dash/comment_1_2325ca78ab6270dcb2d98348a5e1c974._comment
new file mode 100644 (file)
index 0000000..e4640b4
--- /dev/null
@@ -0,0 +1,37 @@
+[[!comment format=mdwn
+ username="kyle"
+ avatar="http://cdn.libravatar.org/avatar/7d6e85cde1422ad60607c87fa87c63f3"
+ subject="comment 1"
+ date="2021-01-25T14:52:54Z"
+ content="""
+> `git annex config --set <option> <value>` interprets a value with a
+> leading dash as if it were an option. Adding `--` doesn't help.
+
+I can get by the \"Invalid option\" error using `--`:
+
+```
+$ git annex config --set annex.youtube-dl-options -x
+Invalid option `-x' [...]
+
+$ git annex config --set annex.youtube-dl-options -- -x
+git-annex: annex.youtube-dl-options is not a configuration setting that can be stored in the git-annex branch
+
+$ git annex version --raw
+8.20201129
+```
+
+`annex.youtube-dl-options` isn't one of the limited set of options that `git annex config` supports though:
+
+```
+globalConfigs =
+    [ annexConfig \"autocommit\"
+    , annexConfig \"synccontent\"
+    , annexConfig \"synconlyannex\"
+    , annexConfig \"resolvemerge\"
+    , annexConfig \"largefiles\"
+    , annexConfig \"dotfiles\"
+    , annexConfig \"addunlocked\"
+    ]
+```
+
+"""]]