Skip to content
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

Submodule support #161

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

JimSimons-UH
Copy link

Basic support for the case where plugins have their own repos/are submodules.

Diffing and history tested along with basic source control operations.

This is not intended to be a comprehensive implementation but enough to get up and running with the built in visual diff tool for blueprints.

@SRombauts SRombauts self-assigned this Apr 4, 2022
@SRombauts
Copy link
Owner

Thank you for the contribution :)
I am not sure how many people use Content in Plugins, I would be interested into knowing the use case/workflow.
I'll see if I can spend more time developing the plugin in the coming months :)

@ameaninglessname
Copy link

I am not using sub-module in production yet, and i was doing some horrible modifications on perforce source control module to bring the change list support using existing content browser folder structure when i was a beginner🤣.

But what i imagine about this is:

A project is divided into the main module (project repository) and many sub-modules (plugins repository)

every module could contain code and content,
with the idea of GameFeature plugin, this became more true in my understanding: plugins brings more features to the project, event server as DLC. So code and content is needed.

With the LFS, could we manager these binary content files directly with git in the same repository of source code? I haven't dig into this yet. If not may be consider using another SCM tool like perforce just for content? (then mutiple SCM running at the same time is need to be supported...)

With that being said, the project consist of these :

BaseGamePlugin (Could be shared cross projects)
GameFeaturePlugins (Could be shared cross projects) based on BaseGamePlugin or not
ProjectSpecificPlugins (Specific project only) or the project main module itself

So i wish to have the ability to do source control operations in local repository (track the folder structure up and try find a closest repository), just like TortoiseGit does, rather than force to the project repository.

It's fine for me to stick with TortoiseGit, but I just lose the ability to diff blueprints in editor.

This is my personal speaking, correction is welcomed : )

@JimSimons-UH
Copy link
Author

Hi @SRombauts, the main workflow as said above is that in Unreal with larger projects, you develop everything in plugins, especially for DLC where you can split each DLC into a plugin for packaging.

It's convenient to give each plugin its own repo and submodule to it from your main project. This way you can re-use it. Previously with this git plugin you couldn't access the blueprint merge tool as it assumed the root of the project for the repo.

Thanks for the great plugin!

@SRombauts
Copy link
Owner

@xist on Discord's Unreal Slackers
SRombauts following up from earlier, PR#161 does not work.
Right clicking a file in a submodule and choosing a source control command is completely broken.
"Show History" doesn't work, "Diff to Depot" doesn't work. Nothing works.
Right clicking a file in the main git repo does work. I can see history and diff correctly.
I do notice however that there is no "Revert" option, which must be broken.

@jimsimonz
Copy link

There's a chance xist's merge was wrong? It does work but I haven't merged it since pushing this. Maybe needs adding to the refactor from https://github.com/ProjectBorealis/UEGitPlugin too.

@leszczynskim
Copy link

Hi @SRombauts! Is there any chance that this feature will be merged soon?

@Louspirit
Copy link

Louspirit commented Sep 21, 2022

Hello. Does this PR only works with submodule inside the Plugins folder or any folder?
Could solve issue #44

Edit: after some tests, it only works with submodules in the Plugins folder.
Any specific reasons to restrict to that folder @JimSimons-UH ?

@jimsimonz
Copy link

jimsimonz commented Sep 26, 2022

@Louspirit I'm no longer at UH. Hey, I'm Jim Simons (different Github account). It was a quick fix for that specific scenario where all your plugins are submodules.

@Louspirit
Copy link

Ok, Jim. I was only asking if it was easy and not resourceful to check up on any subfolder.
Finally, I found that's a better design to use plugins so I moved my shared content inside one.
Hope that @SRombauts can merge it soon because it works well on my side.

@stilobique
Copy link

Hello,
with my art team I wish use Git submodule, the idea behind this solution is to make some plugin librarie ; and I want use this libraries with many Unreal Project. The best way to easily update each project are to used this plugin with a submodule.
Really usefull to me.

I'm need to make more test, I look to give more feedback quickly.

@Louspirit
Copy link

Louspirit commented Dec 30, 2022

Taking this doesn't work on UE5.1 because the code evolved. Can you make a new PR @jimsimonz (or update this one)?
Or @SRombauts merge it, maybe?

@jimsimonz
Copy link

@Louspirit submodules just work now in the later refactored version at https://github.com/ProjectBorealis/UEGitPlugin

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants