Skip to content

Conversation

@ninjamuffin99
Copy link
Contributor

closes #635

Adds a --progress flag to the git clone command, which will spit out the information / progress of the cloning operation.

This implementation will run a while loop that reads the available bytes as they come in and spits them out to the Sys.stdout, and will continue until it gets an EOF error (git clone operation finished), which then it will read all of the bytes + exit code and return it as usual.

p.stdin.close();

// In certain cases of git clones, it will hang on reading from stderr
// if we don't read from it. So we will always try to read from it.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The reason this was solved with threads on windows is that the same thing could happen with p.stdout and p.stderr at the same time, in which case the only solution is to read from both simultaneously (with separate threads).

However, the threads caused issues on Linux so I made it windows only in: b8c24a7. I suspect the same issue is also behind these crashes: #591

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Neko has been patched so I have reapplied that original fix for all platforms. That should handle the stderr/stdout issue.

@skial skial mentioned this pull request Aug 21, 2024
1 task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Display progress for Git based installs

2 participants