Fault-lang / Fault

a language for building system dynamic models

Home Page:https://fault.tech

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Trouble getting it running on Windows

hwayne opened this issue Β· comments

Windows doesn't have make natively. I installed it this way:

New-Item -Type File "fault.Dockerfile"
docker build -t fault-lang/fault-z3 --no-cache -f fault.Dockerfile .

It'll probably crash and burn the moment I try to update to a newer build but that's a future Hillel problem.

At this point I realized I also didn't have bash and couldn't run fault-lang.sh. I tried to copy the docker run to

docker run -v (resolve-path .) fault-lang/fault-z3 -f=(resolve-path .\example.fspec)

But this gave me "must provide path of file to compile".

Oh Windows~~~~ 😭

I was looking at this the other night while grumbling about filepaths ... I'm almost 100% sure the problem here is that I forgot to use Go's module for cross platform path surgery (see --> https://github.com/Fault-lang/Fault/blob/main/util/util.go#L65)

I don't have a Windows machine to test this on but this PR (#30) might help? Want to pull the branch and test it out for me?

On second thought I might need to think about this a bit more. Since its running on Docker that means the correct path separator is '/' but you're entering a path string with '\' ..... πŸ€”

Have confirmed the switch to Go Releaser builds fixed this issue (also was ages ago need to be better about closing issues πŸ˜…πŸ˜…πŸ˜…)