Package: gmdm
GmDmA GameMaker Dependency Management systemInstallationTo install this project as a global Python package, you need to have Python installed on your system. Then, follow these steps:Install the package usingpip install gmdmOtherwise, you can create a virtual environment By following these steps:Create a virtual environment usingpython -m venv venvActivate the virtual environment usingsource venv/bin/activate(Linux/Mac) orvenv\Scripts\activate(Windows)Install the package usingpip install gmdmIn the second way, you will have to activate the virtual environment every time you want to usegmdmUsageNow that you have installed this package, you will have to set up the projects that do the imports (current project) to work with it.For any GameMaker project to be compatible with GmDm, you don't have to create agmdm.ymlfile inside each GameMaker project's folder.
This file is optional. It defines the yyp file name, optionally imports and exports, if any, of your GameMaker project(s).It simply tells GmDm that this project imports a GameMaker "Folder" or Group of resources from other projects.
These other projects should be GmDm compatible.Projects to be imported are looked up in multiple directories:${GMDM_IMPORT_DIRS}env variable. Which is string of paths delimited by ;Absolute path.relative to current directory.~/Documents/GameMakerStudio2/Projects.Basic UsageTo make your project GmDm compatible at least it should have this content at minimum:File: C:/path/to/My Project/My Project.yypFile: C:/path/to/My Project/gmdm.ymlname: My Project.yypAnother example where you define a project that is to be a dependency for other projects:name: Core.yyp
exports:
  - Sprites/My Group
  - Objects/My Group
  - Scripts/My GroupNow to import the project's exports:name: Second Project.yyp
imports:
    - path/to/coreBasically the same as:name: Second Project.yyp
imports:
    - path/to/core:
      - Sprites/My Group
      - Objects/My Group
      - Scripts/My GroupFor advance usage, you can see the filegmdm.yml.EXAMPLE.Now you can usegmdm sync, or any of these commands when inside your project directory:gmdmsync--fake# displays operations without actually performing any. Useful for visualization of what will happen.gmdmsync# performs reimporting (newely modified assets from the imported projects)To show the help, you can use the following command:gmdm --helpAdvanced UsageConsider usingtoin order to have the same path from multiple projects.name: Project1.yyp
imports:
  - path/to/project2:
    - My Main Folder/My Folder:
      to: Extensions/My Project 2 Folder
  - ../project3:
    - My Main Folder/My Different Folder:
      to: Extensions/My Project 3 Folder
  - !ENV '${MY_DIR}/project5'

  - AWellKnownProjectNotesDo:Keep things simple.Use this for your own local machine package management.Know what you are importing.Do not:Do not import the same assets or folders that have the same assets from multiple projects.Do not import the same folder path from multiple projects. Usetoin this case.Other:Zombie files are kept.GmDm is intelligent enough to handle renamed imports when syncing.If a project does not have specific exports, it is thoroughly imported.If a project does not have a gmdm.yml file, it will still be able to be a dependency.For best usage, clone the repos of projects, that you want as dependencies, to a specific directory. Then use gmdm to import them. It is best to set up an environment variableGMDM_IMPORT_DIRS=/d/Projects/;/e/GameMaker/ContributingThis project is open for contributions. If you want to contribute, please follow these steps:Fork this repository and create a new branchMake your changes and commit them with a descriptive messagePush your branch to your forked repositoryCreate a pull request and explain your changesLicenseThis project is licensed under the MIT License. See the LICENSE file for more details.