-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
vendoring django completion #1836
Conversation
git-subtree-dir: vendor/github.com/django/django git-subtree-split: 32bb1421ae4bf8e3b730be0cb47ee026a72961f7
git-vendor-name: django-completion git-vendor-dir: vendor/github.com/django/django git-vendor-repository: https://github.com/django/django git-vendor-ref: 3.1.6
I kind if want to make my own version of |
Idle hands... You can test it like so. ./repos/ $ mkdir test && cd test && git init .
./repos/test $ git vendor add apm https://github.com/vigo/apm-bash-completion 1.0.0 --debug
./repos/test $ git log
./repos/test $ git vendor list
./repos/test $ git vendor remove apm
./repos/test $ git log
./repos/test $ git vendor list
./repos/test $ git vendor add apm https://github.com/vigo/apm-bash-completion 1.0.0 --debug
./repos/test $ git log
./repos/test $ git vendor list
./repos/test $ git vendor update apm --debug
./repos/test $ git log
./repos/test $ git vendor list
./repos/test $ git diff --stat HEAD~ There might be some edge cases especially when updating. In worst case git will throw you into a cherry-picking mode you can just abort. Using this method would greatly aid working with PR's on vendored libs. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Well done @buhl !
You really put a lot of great work here 😄
Thanks @NoahGorny Before you merge this I have to rebase the branch otherwise it won't merge. Which means I have to do alle the steps again 🤐 |
It seems mergeable to me, but okay! |
I think I tried a merge locally when I started using vendor and it failed because git vendors squashed commit doesn't share the same root commit or something. You are welcome to give it a try and merge it 😄 Let me know if you want to try a merge or I should do the rebase |
nice @NoahGorny |
@buhl, is your fork of git-vendor OK to use? I'm asking b/c the patch has something about |
the fork should be okay to use, but seems like @buhl can even try to merge it upstream- the owner of the original repo (@brettlangdon) seems to be active again! |
Oh man, it has been a long time since i looked at git-vendor. I will look into if they want to accept my changes upstream 😺 |
Description
Some vendored libraries like the bash completion of django resides in the django source-code.
To not have to include the entire django project in bash-it just to get django completion we have to rewrite the commits git vendor creates.
Fair warning: This wont be pretty and I can't recommend this procedure.
this will leave the commit history looking like
git vendor
just did it's thing.But
git vendor update django-completion
wont work. You would have to go through the steps above again to clean out unwanted files.Motivation and Context
#1818 and potentially #1819
However as mentioned earlier this is not really a method I would recommend.
Some more discussion of this problem is needed.
How Has This Been Tested?
Enabled the django completion and checked with the
complete
command.Ran local tests
Checklist:
clean_files.txt
and formatted it usinglint_clean_files.sh
.