godotengine / godot-proposals

Godot Improvement Proposals (GIPs)
MIT License
1.14k stars 93 forks source link

Suggested dependencies for Godot version #7432

Open phil-hudson opened 1 year ago

phil-hudson commented 1 year ago

Describe the project you are working on

2d cross platform mobile first game

Describe the problem or limitation you are having in your project

Almost everyday in the Discord, we have users contact us asking about external dependency requirements, e.g. Android Studio, what JDK version to use, additional plugins etc.

Describe the feature / enhancement and how it helps to overcome the problem or limitation

It would be good, if for each Godot version, the version had suggested installable dependencies, and there was an easy way of checking if you had those dependencies in stalled.

Much in the same way that export templates works, we could do the same for JDK and other required deps.

Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams

For each Godot version, have a config file, much like requirements.txt or package.json

Allow the user to inspect if their local environment is matching Godot requirements

Possibly, provide a way for the user to install them, or at least direct them to the correct resources

If this enhancement will not be used often, can it be worked around with a few lines of script?

It probably would be used often, due to the amount of support requests we receive in mobile-dev on Discord

Is there a reason why this should be core and not an add-on in the asset library?

It's pretty core functionality

Calinou commented 1 year ago

I'm not sure how this could be done in a standardized fashion. We already have a bunch of places in the editor that perform their own dependency checks (Blender, fbx2glTF, export presets). As a result, I don't see how this should be done with a configuration file.

What you're probably looking for is making the Install Android Build Template menu in the editor check for the JDK and Android SDK version configured in the Editor Settings before attempting to do anything.

stephannv commented 1 year ago

Based on my experience with web development: This problem is solved this using dot files, eg: .ruby-version, .node-version, .tool-versions, and then external tools (eg. asdf, rbenv, rvm, nvm) detect these files and switch version or print message on console like "ruby 3.2.1 isn't installed". There are setup scripts too, Ruby on Rails devs are used to run bin/setup to install project dependencies, create database, etc.

Maybe you can make an external tool/addon/custom script to solve this problem, and a good and updated project documentation also helps.

phil-hudson commented 1 year ago

What you're probably looking for is making the Install Android Build Template menu in the editor check for the JDK and Android SDK version configured in the Editor Settings before attempting to do anything.

I think this would be a good start, but should there be a centralised place in Godot for all dependencies?