devblog/day 601 v7 defaultgit-annexhttp://git-annex.branchable.com/devblog/day_601__v7_default/git-annexikiwiki2020-06-17T01:18:32ZDirect modehttp://git-annex.branchable.com/devblog/day_601__v7_default/comment_1_54af3bf0a521597d49bd8f8ef0ab5555/grawity2020-06-17T01:18:32Z2019-09-15T09:57:57Z
<p>I've been trying to have something resembling direct mode using the recommended "adjusted branch" feature (with annex.thin), and the results aren't really satisfactory:</p>
<ul>
<li><p>If I use <code>annex adjust --unlock --hide-missing</code>, the non-present files are of course missing entirely. No convenient way to <code>annex get</code> them on demand.</p></li>
<li><p>If I use just <code>annex adjust --unlock</code>, or even if I permanently <code>annex unlock</code> everything, the non-present files still appear <em>as regular files</em> (containing /annex/objects inside), which makes it much harder to distinguish whether the file is present or absent. (In v5 direct mode, absent files appeared as broken symlinks.) Additionally, the adjust command is very slow, unlocking maybe 2–3 files per second (they're video files, approx. ~300MB each).</p></li>
</ul>
<p>I don't mind regular (indirect) mode in general, but unfortunately some apps just... don't like symlinks, so I want to have plain unlocked files at least on this particular clone of this particular repo. So it would be great if there was an adjusted branch mode kinda like <code>--hide-missing</code> but which kept missing files as broken symlinks just like the regular mode does.</p>
<p>But if that's not possible, I think I'll be able to use <code>bindfs --resolve-symlinks</code> to achieve a similar result...</p>
comment 2http://git-annex.branchable.com/devblog/day_601__v7_default/comment_2_c2daec80c7834ebb62324d7169c6c158/joey2020-06-17T01:18:32Z2019-09-16T15:58:22Z
<p>The adjust command won't be slow if you set annex.thin as it won't need to
copy the file content.</p>
<p>There are a couple of ways that it might be possible to get symlinks for
not-present unlocked files. I've opened
<span class="createlink"><a href="http://git-annex.branchable.com/ikiwiki.cgi?do=create&from=devblog%2Fday_601__v7_default%2Fcomment_2_c2daec80c7834ebb62324d7169c6c158&page=todo%2Fsymlinks_for_not-present_unlocked_files" rel="nofollow">?</a>symlinks for not-present unlocked files</span> discussing it.</p>
<p>Improving behavior with --hide-missing is also possible
<a href="http://git-annex.branchable.com/todo/better_way_to_get_missing_files/">better way to get missing files</a>, and I think much more likely to
happen.</p>