{"id":29260074,"url":"https://github.com/a-jean-andreasian/not_gitmodules","last_synced_at":"2025-07-04T07:07:37.123Z","repository":{"id":266223068,"uuid":"897713915","full_name":"a-jean-andreasian/not_gitmodules","owner":"a-jean-andreasian","description":"gitmodules but simple","archived":false,"fork":false,"pushed_at":"2025-06-15T11:10:35.000Z","size":3357,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-06-15T12:18:25.810Z","etag":null,"topics":["ci-cd","devops","git","gitmodules"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/a-jean-andreasian.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-12-03T05:29:49.000Z","updated_at":"2025-06-15T11:12:25.000Z","dependencies_parsed_at":"2025-05-01T14:35:42.691Z","dependency_job_id":"767c729e-8443-4a68-bace-c3745894375f","html_url":"https://github.com/a-jean-andreasian/not_gitmodules","commit_stats":null,"previous_names":["armen-jean-andreasian/not_gitmodules","a-jean-andreasian/not_gitmodules"],"tags_count":9,"template":false,"template_full_name":null,"purl":"pkg:github/a-jean-andreasian/not_gitmodules","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/a-jean-andreasian%2Fnot_gitmodules","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/a-jean-andreasian%2Fnot_gitmodules/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/a-jean-andreasian%2Fnot_gitmodules/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/a-jean-andreasian%2Fnot_gitmodules/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/a-jean-andreasian","download_url":"https://codeload.github.com/a-jean-andreasian/not_gitmodules/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/a-jean-andreasian%2Fnot_gitmodules/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":263464231,"owners_count":23470476,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ci-cd","devops","git","gitmodules"],"created_at":"2025-07-04T07:07:29.280Z","updated_at":"2025-07-04T07:07:37.115Z","avatar_url":"https://github.com/a-jean-andreasian.png","language":"Python","readme":"# \u003cimg src=\"https://raw.githubusercontent.com/a-jean-andreasian/not_gitmodules/refs/heads/master/.github/logo_v2.png\" alt=\"Not Gitmodules!\" height=\"30\" /\u003e Not Gitmodules\n\n---\n\n\n## Introduction\n\n- Not Gitmodules is a **lightweight**, **production-friendly** and **open-source** Python utility\n  designed to simplify managing external modules in\n  your project.\n- It's a replacement for Git Submodule which is: up to **10x faster**, **safer**, **simpler**, **cleaner** and the most\n  importantly - **without headaches**.\n\n---\n\n## Effortlessness\n\nEverything you need to do is:\n\n1. Install Not Gitmodules. Clone this repo from GitHub or install from PyPi\n2. Create a simple YAML file.\n\nNot Gitmodules will handle the rest for you.\n\n---\n\n## Why Not Gitmodules?\n\n1. **Simplicity**: Minimalistic design and no unnecessary complexities.\n2. **Production-Ready**: Explicitly licensed for production use.\n3. **Dependency-Free**: Uses only Python's built-in tools.\n4. **OS-Agnostic**: Works seamlessly on Linux, MacOS and any other platforms where Python is available by default.\n\n---\n\n## Still have questions?\n\nWatch the introduction video on YouTube, where Snoop Dogg will explain everything!\n\n[![](https://markdown-videos-api.jorgenkh.no/youtube/QkFxP_6NA84)](https://youtu.be/QkFxP_6NA84)\n\n---\n\n## Usage\n\n\n\n### Part 1: Installation\n\nChoose the most convenient way to install Not Gitmodules:\n\n1. **Clone** (or download) this repository and include it to your project and use **as a part of your project's code:**\n\n   ```\n   git clone git@github.com:Armen-Jean-Andreasian/not_gitmodules.git\n   ```\n\n\n2. **Install via a package manager** and use **as a Python package** _(example with pip)_:\n\n   ![PyPI](https://img.shields.io/pypi/v/not-gitmodules)\n    ```bash  \n    pip install not-gitmodules\n    ```  \n    - And, yeah, don't forget to add it to `requirements.txt` in advance, if you don't use Poetry.\n\n---\n\n### Part 2: Preparation\n\n1. Create a YAML file in your project's root directory.\n\n- Tip: Naming it `notgitmodules.yaml` lets you use it without explicitly specifying it in the command.\n\n2. Define the submodules following the pattern:\n\n```yaml\nfolder_to_save: # Destination folder for this group of modules\n  module1: module1.url # directory_name: url (ssh or https)\n  module2: module2.url\n\nanother_folder:\n  module3: module3.url\n```\n\nExample:\n\n```yaml\n# directory_name: url (ssh or https)  \nutils:\n  file_manager: https://github.com/not-gitmodules/notgitmodules-file-manager-py\n  file_encryptor: https://github.com/not-gitmodules/notgitmodules-file-encryptor-py\n\nservices:\n  forsaken_mail: https://github.com/malaohu/forsaken-mail\n  sim_mail: https://github.com/Webador/SlmMail\n```  \n\nThe example above will download and create this structure:\n\n```\nutils/\n    file_manager/\n        ... (containing of the repo)\n    file_encryptor/\n        ...\n\nservices:\n    forsaken_mail/\n        ...\n    sim_mail/\n        ...\n```\n\n---\n\n### Part 3: Installation\n\n| Flag (all of them are optional)              | Description                                                                                                                                                                                                            | Example                                                                                                                                |\n|----------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------|\n| `-y`, `--yaml-path`                          | Specify a custom path for the YAML file. \u003cbr\u003eBy default, it looks for `notgitmodules.yaml` in the current working directory. \u003cbr\u003eNaming it `notgitmodules` is a matter of best practices; you can name it as you want. | • `not_gitmodules -y /path/to/custom_notgitmodules.yaml`: Uses a custom YAML file located at `/path/to/custom_notgitmodules.yaml`      |\n| `-t`, `--threaded` _**(default behaviour)**_ | Enable threaded execution, where repositories are cloned in parallel (using threads). \u003cbr\u003eThis flag is mutually exclusive with `-s`. \u003cbr\u003e This is the default behavior if neither `-t` nor `-s` is specified.          | • `not_gitmodules -t`: Clones repositories in parallel using threads \u003cbr\u003e • `not_gitmodules --threaded`: Same as `-t`, using long form |\n| `-s`, `--sequential`                         | Enable sequential execution, where repositories are cloned one by one in the order they appear in the YAML file. This flag is mutually exclusive with `-t`.                                                            | • `not_gitmodules -s`: Clones repositories one by one in order \u003cbr\u003e • `not_gitmodules --sequential`: Same as `-s`, using long form     |\n\n#### More command examples:\n\n- ### Default command:\n\nThis will look for `notgitmodules.yaml` in the project root and create a directory named `my_gitmodules` in the root to\ndownload the modules into, in parallel mode using threads.\n\n```bash  \nnot_gitmodules install\n```\n\n- ### Command pattern:\n\n```bash  \nnot_gitmodules install --yaml-path \u003c/path/to/notgitmodules.yaml\u003e  --\u003cexecution_type\u003e \n```  \n\nor\n\n```bash  \nnot_gitmodules install -y \u003c/path/to/notgitmodules.yaml\u003e  --sequential\n```\n\n\n\u003e Note: Usually with undefined amount of workers in `ThereadPool` in parallel mode take more than **52%** less time than in\nparallel mode.\n\n---\n\n### Part 4. Dockerizing\n\n\n```dockerfile  \nFROM python:3.10-slim  \n\n# Install git for not_gitmodules\nRUN apt-get update \u0026\u0026 apt-get install -y git  \n\nRUN pip install --no-cache-dir -r requirements.txt   \n\n# copy the notgitmodules.yaml file (default). Modify accordingly.\nCOPY notgitmodules.yaml .\n\n# install modules using not_gitmodules.\nRUN not_gitmodules install -y notgitmodules.yaml -t\n\nWORKDIR /app  \n  \nCOPY . .\n\nCMD [\"python\", \"main.py\"]\n```\n\n---\n\n## Good to Know\n\n1. Not Gitmodules **doesn't require to keep the folders** with modules. You can safely .gitignore or delete them.\n2. **Do not use matching names** for the repositories in `notgitmodules.yaml` file. In that case only the first repository\n   will be downloaded and the second one will be skipped.\n3. Not Gitmodules **needs** `Git` and `PyYAML` for functioning.\n4. Not Gitmodules, just like Gitmodules, **doesn't automatically install the dependencies of submodules** _(such as requirements.txt for Python or package.json for JavaScript)_.\n5. Not Gitmodules **doesn't download the sub-dependency submodules** (if they are not defined properly for Git).\n    - Reason: it's practically inefficient, may lead to bugs and bottlenecks, and better to maintain manually.\n    - Solution: Include the sub-dependency submodule to YAML file manually.\n6. Not Gitmodules keeps the view of keeping the project structure clean. All submodules among one\n   project/microservice need to go to one folder. It's recommended to use dependency injection in case of having nested `not_gitmodules`.\n7. **Possible bottleneck** with private repositories.\n    -  If cloning fails, but you have access to the repository, provide the HTTPS repo URL instead of SSH url in YAML file.\n8. If your python version is incompatible with `PyYAML==6.0` try to install the compatible version of `PyYAML`.  \n\n---\n\n\u003cdiv style=\"text-align: center;\"\u003e\n  \u003cimg src=\"https://raw.githubusercontent.com/a-jean-andreasian/not_gitmodules/refs/heads/master/.github/pic1.png\" width=\"300\" height=\"300\"\u003e\n\u003c/div\u003e\n\n---\n\n## ![License](https://img.shields.io/badge/license-Custom-blue)\n\nThis project is licensed under a **Custom License**. See the [LICENSE](./LICENSE) file for full details.\n\nKey points:\n\n- You may use this project for commercial or personal purposes.\n\n---\n\n## Author\n\nArmen-Jean Andreasian, 2024\n\n---\n\n\u003cdiv style=\"text-align: center;\"\u003e\n  \u003cimg src=\"https://raw.githubusercontent.com/a-jean-andreasian/not_gitmodules/refs/heads/master/.github/pic2.png\" /\u003e\n\u003c/div\u003e\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fa-jean-andreasian%2Fnot_gitmodules","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fa-jean-andreasian%2Fnot_gitmodules","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fa-jean-andreasian%2Fnot_gitmodules/lists"}