Forgive the top post and short replay but …. Applause! That’s a very creative and somewhat intuitive way to build a bridge!
Nicely done! (But you already knew that!) Sent from my iPhone > On Feb 13, 2025, at 8:21 PM, Nicola Girardi via 9fans <9fans@9fans.net> wrote: > > Quoth Alyssa M via 9fans <9fans@9fans.net>: >> I wondering whether it would be better to have a single control >> file per directory and some kind of sub-protocol going through it. > > It's nice to see I'm not the only one doing something of the kind. I > went with something that seems simpler to me, but it's subjective. I > use a single control file at the root (/ctl) and a helper rc script > (m) to implement non-9P commands that I use both in Linux and Plan > 9. (I don't use .L but I think the approach would still work.) For > example, I say > > % pwd > /mnt/weirdfs/src > % m mv foo bar/baz/ > > This will detect if I'm within the mounted weird fs and output other > commands that I can pipe to rc, e.g., > > % echo rename src/foo src/bar/baz/foo >/weird/fs/ctl > > which when does the rename just using links and not copying and > removing data (as would be the case with dircp and rm). > > (Obviously if you use mv on Linux it would still achieve the same > result but copying and removing all the data.) These “advanced” > commands I use very little often so I don't mind not implementing .L > in my case. > > Possibly a better way would be to use another side channel to talk > to the fs instead of the control file, like when you use con(1) with > /srv/cwfs.cmd but I haven't had reason to invest time in this since > the ctl works. > ------------------------------------------ 9fans: 9fans Permalink: https://9fans.topicbox.com/groups/9fans/T0f2c2342a05a3d6e-M684d26f2ab53947877c3244a Delivery options: https://9fans.topicbox.com/groups/9fans/subscription