Closed leeebo closed 1 day ago
One more thing, maybe we should have Jihulab
and Gitee
dependent on each other, and when one option is set the other one will not be possible to set.
One more thing, maybe we should have
Jihulab
andGitee
dependent on each other, and when one option is set the other one will not be possible to set.
Yes, make sense. I want to do that, but I don't know the syntax, that's why I write else if
here
Will fix it
One more thing, maybe we should have
Jihulab
andGitee
dependent on each other, and when one option is set the other one will not be possible to set.Yes, make sense. I want to do that, but I don't know the syntax, that's why I write
else if
hereWill fix it
This should be only for summary text so it is OK to put there just if
.
TBH, I am unsure about the syntax as well, but if you need some help, I can dig a bit more into how to implement this.
@jakub-kocka Now users can exclusively check or uncheck the Git Mirror
like below:
English Language:
Chinese Language:
I have tested it on my Windows11 PC, it works as expected, the log as bellow: Setup Log 2024-06-27 #003.txt
However, it should be noted that since the submodule of the submodule may specify the URL from github directly (like below, release/v5.3, cmock's submodules are from github), even if the user chooses Git mirror, these submodules still download from github. As suggested by @wujiangang, we may need to run a command like git config - global url.https://jihulab.com/esp-mirror.insteadOf https://github.com
to fix it, then unset it after installation. @jakub-kocka @georgik what's your opinion?
@leeebo Nice work! Thank you for the improvements.
I agree with changing the git URL. If it may wait a bit longer we can fix this in the scope of the task with git clone
fix (internal tracker IDF-10228 - it is planned for Q3) so this PR can be eventually merged.
@jakub-kocka Comment has been added in the jira, let's wait for your fix
@jakub-kocka Comment has been added in the jira, let's wait for your fix
@leeebo, thank you.
So this PR is ready to merge, right?
LGTM as far as I can tell.
@leeebo Do you think this mirror would be useful to mention at https://docs.espressif.com/projects/esp-idf/en/latest/esp32/get-started/linux-macos-setup.html#step-2-get-esp-idf? We have later on that page Github mirror for downloadable tools but no alternative mentioned to cloning from Github.
Thank you @dobairoland for the review. I am merging this and will release the latest IDF version offline installer and online installer.
@dobairoland Thanks for your suggestions, I think finally we should mention the mirrors at https://docs.espressif.com/projects/esp-idf/en/latest/esp32/get-started/linux-macos-setup.html#step-2-get-esp-idf, we currently need an additional step to change the submodule's submodule URL from github to jihulab.
How about adding a new script like tools/set-submodules-to-jihulab.sh
? in esp-idf
we currently need an additional step to change the submodule's submodule URL from github to jihulab.
No, I don't think that is necessary. We use relative paths here: https://github.com/espressif/esp-idf/blob/master/.gitmodules. That means that the submodules URLs will point to the same page domain the root repository was cloned from. The same way it works for our Github & Gitlab. I don't see why it wouldn't work for other mirrors as well.
@dobairoland For the ESP-IDF's submodules it's OK, but for submodules's submodule, eg. CMock has submodule vendor/unity
and vendor/unity
, which using specified URL instead of relative paths. https://github.com/ThrowTheSwitch/CMock/blob/eeecc49ce8af123cf8ad40efdb9673e37b56230f/.gitmodules
Ok, I see. I wouldn't add a script to ESP-IDF which is not even needed directly by it. But I'm sure we can have such helper script in another repository.
Depending on the number of such submodules we can consider to submit PRs into them.
This PR aims to add another git mirror for users to choose
Jihulab is a Chinese localization of Gitlab public repository,
Espressif maintained an official mirror there https://jihulab.com/esp-mirror/espressif/esp-idf,
Which has the same submodule relative paths as the Github repo.