[Request] Add Git-extras
Hey luke,
How about git-extras? https://github.com/tj/git-extras
it has a install.cmd, so it should be ~easy~. I can probably do it this weekend
Yes, please submit a pull request if you can get it working. Thanks.
I was thinking about ways to implement this. Scoop does not seem well-suited for an app that basically installs over another app.
I can think of two possibilities how to implement this:
- Create
git-with-extrasmanifest, which is thegitmanifest withgit-extrasinstallation step added. Would install alongside normalgitand override its shim. Seems the most straightforward, but comes at the cost of having two full copies of gits installed, one clean and one with git-extras. - Create a
git-extrasmanifest that:
- Depends on
git - On installation, patches the current installed version of
git - Overrides the
gitshim with one that first checks if the current version ofgitis patched, and if not, patches it. It then forwards everything to realgit. This has the obvious disadvantage of patchinggitlazily in casegitis newer thangit-extras. Also seems rather complicated. But only one version of git is installed.
What do you think is better?
@JanPokorny, I ended up going with option 2 in my bucket while testing. Not sure what the best way to do the Git shim patching though. 🤔
Overall option 1 seems easier to implement, but I think option 2 is better. Also, not sure to do on uninstall. ~Other than a scoop reset git maybe? Because there isn't an uninstaller.~ Scoop reset doesn't do what I expected...
@pxgamer Your solution also has a problem with updating -- updating git removes the extras. (That's why I mentioned the need for lazy patching.)
Looking at it now, keeping two copies of git does not really seem like a big deal, compared to patching it on demand. Scoop actually has direct support for two apps providing the same shims (that's what scoop reset is for). Thus, I believe that creating git-with-extras is the way to go.
Yeah, I think that makes the most sense. Would be good to see a PR if you want to do it. 👌
The only issue is for things that depend on the git package, then you'd end up with 2 lots of Git.
@pxgamer I plan on creating the package in the near future (it's the exam period now...).
As Scoop itself depends on git, you would need to have it installed alongside git-with-extras. As git-with-extras is a superset of git, it should not break anything even if some tool uses git-with-extras while expecting vanilla git.
@pxgamer Hello, the "near future" is here. I have created a PR for bit: https://github.com/ScoopInstaller/Main/pull/1501. It's actually more than you've been asking for, but it can be easily aliased to git.
@JanPokorny, thanks for this! Will take a look. (By the way, changed from @pxgamer to @owenvoke). 👍🏻
@owenvoke My apologies, looks like it includes only a subset of git-extras commands
Oh well, still looks good. 👌🏻
Ha, looking good guys, sorry, this one fell through my TODOs list, and work moved me off PC :(
Hello! Is git-extras or git-with-extras available somewhere?
No sadly not in any official bucket, if you search here for 'git-extras': https://rasa.github.io/scoop-directory/search you can try installing one of those manifests from a personal bucket, they both install slightly differently so do read the manifests before installing.