public inbox for goredo-devel@lists.cypherpunks.ru
Atom feed
From: Sergey Matveev <stargrave@stargrave•org>
To: goredo-devel@lists.cypherpunks.ru
Subject: Re: Nested dirs for non existing targets
Date: Fri, 15 Apr 2022 19:23:03 +0300 [thread overview]
Message-ID: <Ylmb6LtUTZ3VXCkP@stargrave.org> (raw)
In-Reply-To: <3f4c959c-feb7-9033-97dc-f1c6d2fb3da0@acha.ninja>
[-- Attachment #1: Type: text/plain, Size: 1764 bytes --]
*** Andrew Chambers [2022-04-14 23:30]:
>One way would be for
>goredo to store the dependency information in the directory containing the
>do file instead of the directory containing the target.
That heavily complicates everything. If you have dependency information
stored near the target itself, then finding it is trivial:
for foo/bar/baz/TGT
dependency information is in foo/bar/baz/.redo/TGT.rec
But if you store it "near" the .do file, then:
for foo/bar/baz/TGT
.do file is: foo/default.do,
so depinfo is in: foo/.redo/bar_baz_TGT.rec (for example)
and for finding it, you have to traverse from foo/bar/baz/ directory to
uppper levels finding that bar_baz_TGT.rec file.
And you can not just call find_do_file(foo/bar/baz/TGT) and go to that
directory, because another .do file can appear after that.
foo/bar/default.do appeared
and it should be the default one for foo/bar/baz/TGT
but still only foo/.redo/bar_baz_TGT.rec has dependency information
And when you rerun your target, foo/bar/.redo/baz_TGT.rec will appear...
but what to do with the left foo/.redo/bar_baz_TGT.rec? Search for
possible obsolete dependency information and delete it? It will be
impossible to do that atomically: you can not rename temporary file to
foo/bar/.redo/baz_TGT.rec and delete foo/.redo/bar_baz_TGT.rec at once.
That leads to the desire of some centralized storage, as apenwarr/redo
did. But its author decided that it was a bad idea:
https://redo.readthedocs.io/en/latest/FAQImpl/#how-does-redo-store-dependencies
Well, spacefrogg@ actually wrote about exactly all of that too.
--
Sergey Matveev (http://www.stargrave.org/)
OpenPGP: CF60 E89A 5923 1E76 E263 6422 AE1A 8109 E498 57EF
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
next prev parent reply other threads:[~2022-04-15 16:23 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-04-14 2:05 Nested dirs for non existing targets Andrew Chambers
2022-04-14 7:18 ` goredo
2022-04-14 11:01 ` Andrew Chambers
2022-04-14 11:30 ` Andrew Chambers
2022-04-14 12:01 ` goredo
2022-04-14 12:05 ` Andrew Chambers
2022-04-14 14:29 ` goredo
2022-04-15 16:23 ` Sergey Matveev [this message]
2022-04-15 16:22 ` Sergey Matveev