From 790befd893f7f8d3881d8673c4f14e5c03b343d0 Mon Sep 17 00:00:00 2001 From: matrss Date: Fri, 8 Sep 2023 15:47:16 +0000 Subject: [PATCH] Added a comment: get file by branch and path in bare repository --- ..._9914f6f6c99757927eed9b5d0217908e._comment | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 doc/git-annex-get/comment_1_9914f6f6c99757927eed9b5d0217908e._comment diff --git a/doc/git-annex-get/comment_1_9914f6f6c99757927eed9b5d0217908e._comment b/doc/git-annex-get/comment_1_9914f6f6c99757927eed9b5d0217908e._comment new file mode 100644 index 0000000000..762626b1ae --- /dev/null +++ b/doc/git-annex-get/comment_1_9914f6f6c99757927eed9b5d0217908e._comment @@ -0,0 +1,19 @@ +[[!comment format=mdwn + username="matrss" + avatar="http://cdn.libravatar.org/avatar/59541f50d845e5f81aff06e88a38b9de" + subject="get file by branch and path in bare repository" + date="2023-09-08T15:47:16Z" + content=""" +Hey! + +Is there any way to `git annex get` a file in a specific branch when I have a bare repository? + +Since `git show :` works I tried that notation in `get`, but that is not recognized. + +It is also not possible to combine `--branch` with a path as far as I can tell. + +My next idea was to figure out the key of the file first and then get that, but `git annex lookupkey` does not work in a bare repository either. + +I could parse the key from the output of `git show`, but then I would need to deal with git-annex internals like if it is a symlink or a pointer file, which feels a bit wrong. +But since that would be possible I don't see a reason why e.g. lookupkey does not work. Is there any way to achieve this? +"""]]