aboutsummaryrefslogtreecommitdiff
path: root/doc/devblog
diff options
context:
space:
mode:
authorGravatar Joey Hess <joeyh@joeyh.name>2017-09-15 15:54:20 -0400
committerGravatar Joey Hess <joeyh@joeyh.name>2017-09-15 15:54:20 -0400
commitc26b2eb2a4f261fd903b02d397737cf6a3a0196b (patch)
treeba85c32cc1e7a77ba7077ae82004509ca79611dc /doc/devblog
parent4c88513e1894c4d02dd7b1cc5dc1e3d536429f13 (diff)
devblog
Diffstat (limited to 'doc/devblog')
-rw-r--r--doc/devblog/day_472__removing_empty_directories.mdwn20
1 files changed, 20 insertions, 0 deletions
diff --git a/doc/devblog/day_472__removing_empty_directories.mdwn b/doc/devblog/day_472__removing_empty_directories.mdwn
new file mode 100644
index 000000000..563a347c3
--- /dev/null
+++ b/doc/devblog/day_472__removing_empty_directories.mdwn
@@ -0,0 +1,20 @@
+After doing some fine-tuning of webdav export on Wednesday, I noticed a
+problem: There seems to be no way in the webdav spec to delete a collection
+(directory) only when it's empty like `rmdir(2)` does.
+It would be possible to check the contents of the collection before
+deleting it, but that's complex (involving XML parsing) and race-prone.
+
+So, I decided to add a remote method to delete a directory, and make
+git-annex keep track of when a directory in an export is empty, and delete
+it. While it does complicate the design some to need to do this, that seems
+better than complicating the implementation of remotes like webdav. And
+some remotes may not have a `rmdir(2)` equivilant or a way to check if a
+directory is empty.
+
+Spent most of today implementing that, including some rather hairy
+eSQL to maintain a table of exported directories.
+
+Still not quite done with export..
+
+Today's work was sponsored by Trenton Cronholm on
+[Patreon](https://patreon.com/joeyh)