Robin Shen opened 4 years ago
|
|||||
Robin Shen changed title 4 years ago
|
|||||
Do you plan on adding two-way sync between onedev and cloud git hostings? As I see it, you could have a page in project settings with two fileds:
Right now we're trying to implement this behaviour with a job, that runs git push triggered on any commit, plus an external webhook running on the same machine as onedev, triggering git fetch in /opt/onedev/site/projects/X/git path. But this is kind of complex to set up manually, and also you need to modify git config for fetch to import remote commits in local bare repo. Would be nice to have this feature automatically out of box. |
|||||
This deserves a separate feature request. Filed as issue #66 |
|||||
挺好的 |
|||||
The linked issue #66 does not open. |
|||||
By the way, just a suggestion. I think this and many other tasks like this could be implemented using build jobs but some kind of preconfigured as templates or something like this and then added IU elements in Web interface to easily turn it on/off with some necessary configuration. Maybe some kind of tutorial on how an example job like this could be made as a template and added to web interface as function would be a huge help. I am sure people would contribute many useful jobs like this. |
|||||
Contributions are very welcomed. This can be implemented as job suggestion, or step type. If it is generic enough, we can ship it together with OneDev. |
|||||
OneDev referenced from other issue 3 years ago
|
|||||
@kobit I plan to implement the plugin to import from GitHub first to make sure necessary facilities are in-place to support this type of task. Then based on this plugin, it will be much easier for others to contribute importing from GitLab/BitBucket etc. Please watch on issue #321 to get notified for GitHub import. |
|||||
Great, thanks a lot. Will you add importing issues as well or just importing code repository? |
|||||
Issues will also be imported. |
|||||
Robin Shen changed state to 'Closed' 3 years ago
|
|||||
@kobit build #1563 is able to import repositories and issues from GitHub. Closing this issue now. To request importing from other products, please file separate issue for specific product. |
|||||
Hi, it works! However, there is one flaw in the implementation. I cannot import projects as private projects. The form forces me to set "Public Role" which automatically makes the project publicly visible. I would like to import some private projects, visible and accessible only to selected users within 1dev. Another thingsuggestion. The project automatically adjusts project name adding either github user or github organization in front. Would it be possible to have a pull down field with a list of groups and assign the project to a specific group instead? This is how GitLab works and it is very useful. I guess, my concerns are mainly because I have hundreds of projects to import from GitHub and adjusting them one by one is very tedious. It would be great with above changes to automate the process as much as possible. |
|||||
Thanks for testing it out.
|
|||||
ad. 1. Yes, exactly. Right now it is not possible to leave this field empty during import, so all projects automatically become public. I would like to be able to import projects as private. If you allow empty value in this field, it would solve the problem. |
|||||
This field will not affect private repositories. I just tested importing from two repositories, one is private and another is public. And OneDev only sets the default role for the public project after importing. |
|||||
Ah, ok. So this settings is ignored for private projects and only set for public? Still, I think allowing an empty value here would be useful to import all projects as private, regardless whether they are public on GitHub. And it would also be useful if there was some additional explanation under the field: "Specify default role for public repositories. Only applied to public projects at the source system." Or something like this. One more thing I noticed. After the import is complete, the import view should probably close and switch over to list of projects or something like this. |
|||||
I'd like not to make the import configuration too complicated. If one wants to import public as private, they can either change it at GitHub side, or remove the default role after import. The import view is left here in case user wants to import more projects. Also user may want to check some notice (missing label mapping, user accounts etc) after import to retry it after adjustment. |
|||||
Thank you for responding. Allowing empty field instead of mandatory filled with something does not add any complication. |
|||||
Hmm... you are right. Will make this optional in next patch release, together with extra explanation. |
|||||
Thank you so much. I appreciate your support. |
Type |
New Feature
|
Priority |
Normal
|
Assignee |
Able to import projects from other products such as GitHub/GitLab/BitBucket etc.