bouncepaw / mycorrhiza

🍄📑 Filesystem and git-based wiki engine for the independent web written in Go and using Mycomarkup as its primary markup language.
https://mycorrhiza.wiki
GNU Affero General Public License v3.0
305 stars 26 forks source link

Rename hypha renames git repo instead #220

Closed iacore closed 4 months ago

iacore commented 6 months ago
mkdir www.aaa
cd www.aaa
git init
git commit --allow-empty -m "hi"
git branch wiki
git worktree add wiki.git wiki
mycorrhiza .

Now, in Mycorrhiza (Web UI),

You will see that the directory www.aaa has changed to www.bbb.

bouncepaw commented 6 months ago

It's not about git, it's about filepaths. It's a known problem, but I've been neglecting it, thanks for reminding!

ORYLY commented 5 months ago

To clarify, will the planned solution for the filepath problem also fix the genealogy feature documented in https://mycorrhiza.wiki/help/en/hypha#Genealogy , which seems dependent on filepaths to model subhypha and superhypha relationships ?

For example, when following the Fruit/Apple example from the help page, I get the following directory structure:

# ls -R1 wiki.git/
wiki.git/:
fruit
fruit.myco

wiki.git/fruit:
apple.myco

But after restarting the server (or reindexing), the genealogy relationship is gone completely:

bouncepaw commented 5 months ago

The subhypha is named "fruitapple" (and displayed as "Fruitapple").

What? How does that happen? Please tell me everything

ORYLY commented 5 months ago

Sorry! I'm guessing my problem is with Windows paths if it's working for everyone else but me.

I compile and run mycorrhiza through MSYS2 (still using Windows go toolchain), and I suppose backslash path separators are getting into the program somewhere. I'll log a new issue after checking on a Linux distro and WSL.

ORYLY commented 5 months ago

Yup, running a pure Windows executable was the problem. Genealogy and subdirectories work just fine when running mycorrhiza in a Linuxy environment.