Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

updateInfos failed Error: Error: spawn git ENOENT #134

Open
keilladraconis opened this issue Feb 4, 2024 · 4 comments
Open

updateInfos failed Error: Error: spawn git ENOENT #134

keilladraconis opened this issue Feb 4, 2024 · 4 comments
Assignees
Labels
bug with workaround an annoying bug with a temporary hack to work around it while it's beeing fixed

Comments

@keilladraconis
Copy link
Contributor

Describe the bug

OS: Windows 10

When I start CushyStudio, it all seems to work, however the tab next to the couch at the top left is forever spinning and contains an error message:

updateInfos failed Error: Error: spawn git ENOENT at __node_internal_captureLargerStackTrace (node:internal/errors:496:5) at __node_internal_errnoException (node:internal/errors:623:12) at ChildProcess._handle.onexit (node:internal/child_process:284:19) at onErrorNT (node:internal/child_process:477:16) at process.processTicksAndRejections (node:internal/process/task_queues:82:21)

It seems like it's trying to launch Git, but cannot.

I do have git installed and it show up on both PowerShell and Command shell.

@rvion rvion self-assigned this Feb 4, 2024
@rvion rvion added the bug with workaround an annoying bug with a temporary hack to work around it while it's beeing fixed label Feb 4, 2024
@rvion
Copy link
Owner

rvion commented Feb 4, 2024

thanks for the feedback ! that's indeed problematic.
so, Cushy fails to retrieve available updates. is the update script at the root working ?

I'll try to priorize removing the need for git asap

@keilladraconis
Copy link
Contributor Author

Yes, the update script at the root does work. I hate windows, I could figure this issue out on my own on a linux system but windows' pathing is a mystery to me.

@keilladraconis
Copy link
Contributor Author

Alright, well after a bit of thinking I dug around in the batch files and tried the following:

SET GIT_INSTALL_DIR=C:\Program Files\Git\cmd
SET CODE_INSTALL_DIR=C:\Users\keilla\AppData\Local\Programs\Microsoft VS Code\bin
SET "PATH=%NODE_INSTALL_DIR%;%GIT_INSTALL_DIR%;%CODE_INSTALL_DIR%;%PATH%"

There's some kind of confusing re-setting of the path in this script, also alternation between different methods of variable substitution. I think sticking to the fully-quoted %var% is best.

I'm unsure why setting paths this way matters. As you can see vsCode is installed as a user program, where git is installed as a everyone-program.

@rvion
Copy link
Owner

rvion commented Feb 7, 2024

There's some kind of confusing re-setting of the path in this script, also alternation between different methods of variable substitution. I think sticking to the fully-quoted %var% is best.

I'm clearly not good with windows scripting, since I don't use windows myself neither; I'll be more than happy to merge any PR from someone who knows how to make that more robust x)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug with workaround an annoying bug with a temporary hack to work around it while it's beeing fixed
Projects
None yet
Development

No branches or pull requests

2 participants