planetis-m / naylib

Yet another raylib Nim wrapper
MIT License
233 stars 10 forks source link

'atlas' installation messes up files #146

Closed matkuki closed 3 weeks ago

matkuki commented 4 weeks ago

Hi,

Specs:

Running:

atlas init atlas use "https://github.com/planetis-m/naylib"

causes the git repo for naylib in the dependencies directory to get messed up. It looks like the after install hook does something wrong, but that is my guess.

planetis-m commented 4 weeks ago

What's exactly wrong with it? AFAIK with atlas it should run the branch:

after install: when defined(atlas): localInstallTask()

The localInstallTask is tested by the CI:

task test, "Runs the test suite": localInstallTask()

And the other branch is also taken by the examples CI which installs naylib as a dependency.

planetis-m commented 4 weeks ago

It could be an issue with path handling. It needs to use quoteShell somewhere.

Can you open raylib.nim in your installation and post the raylibDir constant in the 5th line?

planetis-m commented 4 weeks ago

I tried to install in a path that has spaces but atlas doesn't even run correctly. If your path is irregular report the issue to atlas.

matkuki commented 4 weeks ago

My project path: E:\Nim\naylib\text_editor

5th line in raylib.nim:

const raylibDir = Path(r"E:\Nim\naylib\text_editor\dependencies\naylib\src\raylib")
planetis-m commented 4 weeks ago

Seems ok? And what's the error?

(The after install task doesn't touch directories, it only overwrites this constant.)

matkuki commented 4 weeks ago

One thing is, the entire src/raylib subdirectory is missing. This is what is in the atlas installed src directory: image ... and this is what is in the nimble installed package: image And the git log of the atlas repo shows this (TortoiseGit): image I didn't do anything in any of the directories, this is just after atlas use ....

matkuki commented 3 weeks ago

Had the same thing happen when installing sdl2 with atlas. Reported this to atlas repo: https://github.com/nim-lang/atlas/issues/135