I am following the instructions at tips/publishing_your_files_to_the_public to export trees to a public remote. Often I want to just share a single file publicly with someone, not an entire folder (which is what export supports).
For example I am using git-annex-remote-googledrive and I have created a new folder with public read access from drive.google.com. If I set this folder up as an exporttree remote I could then export a local annexed sub-folder to it. What I really want though is to pick a single file to share publicly with someone and send that to my public folder. Does anyone have thoughts on an existing workflow that might achieve this?
OK. It looks like one way I could achieve this is by following these instructions old method. Basically just
git annex copy --to
the file to a public s3 repo without encryption and without chunking and withpublic=yes
then grab the URL.It seems this should also work for any remote that supports
WHEREIS Key
for getting a URL from any key.git annex export
only exports trees, but you can easily make a tree containing only a single file, and then export that.For example:
If you don't want to commit that you can switch to a temporary branch and build the tree there. Or there are plenty of lower-level git commands to build trees.