git-fleximod


Namegit-fleximod JSON
Version 0.5.0 PyPI version JSON
download
home_pagehttps://github.com/jedwards4b/git-fleximod
SummaryExtended support for git-submodule and git-sparse-checkout
upload_time2024-02-03 21:02:44
maintainerJim Edwards
docs_urlNone
authorJim Edwards
requires_python>=3.8,<4.0
licenseMIT
keywords git submodule sparse-checkout
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # git-fleximod

Flexible Submodule Management for Git

## Overview

Git-fleximod is a Python-based tool that extends Git's submodule capabilities, offering additional features for managing submodules in a more flexible and efficient way.

## Installation

#TODO    Install using pip:
#        pip install git-fleximod
  If you choose to locate git-fleximod in your path you can access it via command: git fleximod

## Usage

    Basic Usage:
        git fleximod <command> [options]
    Available Commands:
        checkout: Checkout submodules according to git submodule hash configuration.
        status: Display the status of submodules.
        update: Update submodules to the tag indicated in .gitmodules variable fxtag.
        test: Make sure that fxtags and submodule hashes are consistant,
              make sure that official urls (as defined by fxurl) are set
              make sure that fxtags are defined for all submodules
    Additional Options:
        See git fleximod --help for more details.

## Supported .gitmodules Variables

    fxtag: Specify a specific tag or branch to checkout for a submodule.
    fxrequired: Mark a submodule's checkout behavior, with allowed values:
      - T:T: Top-level and required (checked out only when this is the Toplevel module).
      - T:F: Top-level and optional (checked out with --optional flag if this is the Toplevel module).
      - I:T: Internal and required (always checked out).
      - I:F: Internal and optional (checked out with --optional flag).
    fxsparse: Enable sparse checkout for a submodule, pointing to a file containing sparse checkout paths.
    fxurl: This is the url used in the test subcommand to assure that protected branches do not point to forks

## Sparse Checkouts

    To enable sparse checkout for a submodule, set the fxsparse variable
    in the .gitmodules file to the path of a file containing the desired
    sparse checkout paths. Git-fleximod will automatically configure
    sparse checkout based on this file when applicable commands are run.
    See [git-sparse-checkout](https://git-scm.com/docs/git-sparse-checkout#_internalsfull_pattern_set)
    for details on the format of this file.

## Tests

   The git fleximod test action is designed to be used by, for example, github workflows
   to assure that protected branches are consistant with respect to submodule hashes and fleximod fxtags

## Examples

Here are some common usage examples:

Checkout submodules, including optional ones:
```bash
  git fleximod checkout --optional
```

Updating a specific submodule to the fxtag indicated in .gitmodules:

```bash
    git fleximod update submodule-name
```
Example .gitmodules entry:
```ini, toml
    [submodule "cosp2"]
        path = src/physics/cosp2/src
        url = https://github.com/CFMIP/COSPv2.0
        fxsparse = ../.cosp_sparse_checkout
        fxtag = v2.1.4cesm
```
Explanation:

This entry indicates that the submodule named cosp2 at tag v2.1.4cesm
should be checked out into the directory src/physics/cosp2/src
relative to the .gitmodules directory.  It should be checked out from
the URL https://github.com/CFMIP/COSPv2.0 and use sparse checkout as
described in the file ../.cosp_sparse_checkout relative to the path
directory.

Additional example:
```ini, toml
    [submodule "cime"]
        path = cime
        url = https://github.com/jedwards4b/cime
        fxrequired = T:T
        fxtag = cime6.0.198_rme01
```

Explanation:

This entry indicates that the submodule cime should be checked out
into a directory named cime at tag cime6.0.198_rme01 from the URL
https://github.com/jedwards4b/cime.  This should only be done if
the .gitmodules file is at the top level of the repository clone.

## Contributing

We welcome contributions! Please see the CONTRIBUTING.md file for guidelines.

## License

Git-fleximod is released under the MIT License.

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/jedwards4b/git-fleximod",
    "name": "git-fleximod",
    "maintainer": "Jim Edwards",
    "docs_url": null,
    "requires_python": ">=3.8,<4.0",
    "maintainer_email": "jedwards@ucar.edu",
    "keywords": "git,submodule,sparse-checkout",
    "author": "Jim Edwards",
    "author_email": "jedwards@ucar.edu",
    "download_url": "https://files.pythonhosted.org/packages/ad/61/b79079d7f42b37446932b30f964f62d720dc95b08571f2e6b6f7381406e0/git_fleximod-0.5.0.tar.gz",
    "platform": null,
    "description": "# git-fleximod\n\nFlexible Submodule Management for Git\n\n## Overview\n\nGit-fleximod is a Python-based tool that extends Git's submodule capabilities, offering additional features for managing submodules in a more flexible and efficient way.\n\n## Installation\n\n#TODO    Install using pip:\n#        pip install git-fleximod\n  If you choose to locate git-fleximod in your path you can access it via command: git fleximod\n\n## Usage\n\n    Basic Usage:\n        git fleximod <command> [options]\n    Available Commands:\n        checkout: Checkout submodules according to git submodule hash configuration.\n        status: Display the status of submodules.\n        update: Update submodules to the tag indicated in .gitmodules variable fxtag.\n        test: Make sure that fxtags and submodule hashes are consistant,\n              make sure that official urls (as defined by fxurl) are set\n              make sure that fxtags are defined for all submodules\n    Additional Options:\n        See git fleximod --help for more details.\n\n## Supported .gitmodules Variables\n\n    fxtag: Specify a specific tag or branch to checkout for a submodule.\n    fxrequired: Mark a submodule's checkout behavior, with allowed values:\n      - T:T: Top-level and required (checked out only when this is the Toplevel module).\n      - T:F: Top-level and optional (checked out with --optional flag if this is the Toplevel module).\n      - I:T: Internal and required (always checked out).\n      - I:F: Internal and optional (checked out with --optional flag).\n    fxsparse: Enable sparse checkout for a submodule, pointing to a file containing sparse checkout paths.\n    fxurl: This is the url used in the test subcommand to assure that protected branches do not point to forks\n\n## Sparse Checkouts\n\n    To enable sparse checkout for a submodule, set the fxsparse variable\n    in the .gitmodules file to the path of a file containing the desired\n    sparse checkout paths. Git-fleximod will automatically configure\n    sparse checkout based on this file when applicable commands are run.\n    See [git-sparse-checkout](https://git-scm.com/docs/git-sparse-checkout#_internalsfull_pattern_set)\n    for details on the format of this file.\n\n## Tests\n\n   The git fleximod test action is designed to be used by, for example, github workflows\n   to assure that protected branches are consistant with respect to submodule hashes and fleximod fxtags\n\n## Examples\n\nHere are some common usage examples:\n\nCheckout submodules, including optional ones:\n```bash\n  git fleximod checkout --optional\n```\n\nUpdating a specific submodule to the fxtag indicated in .gitmodules:\n\n```bash\n    git fleximod update submodule-name\n```\nExample .gitmodules entry:\n```ini, toml\n    [submodule \"cosp2\"]\n        path = src/physics/cosp2/src\n        url = https://github.com/CFMIP/COSPv2.0\n        fxsparse = ../.cosp_sparse_checkout\n        fxtag = v2.1.4cesm\n```\nExplanation:\n\nThis entry indicates that the submodule named cosp2 at tag v2.1.4cesm\nshould be checked out into the directory src/physics/cosp2/src\nrelative to the .gitmodules directory.  It should be checked out from\nthe URL https://github.com/CFMIP/COSPv2.0 and use sparse checkout as\ndescribed in the file ../.cosp_sparse_checkout relative to the path\ndirectory.\n\nAdditional example:\n```ini, toml\n    [submodule \"cime\"]\n        path = cime\n        url = https://github.com/jedwards4b/cime\n        fxrequired = T:T\n        fxtag = cime6.0.198_rme01\n```\n\nExplanation:\n\nThis entry indicates that the submodule cime should be checked out\ninto a directory named cime at tag cime6.0.198_rme01 from the URL\nhttps://github.com/jedwards4b/cime.  This should only be done if\nthe .gitmodules file is at the top level of the repository clone.\n\n## Contributing\n\nWe welcome contributions! Please see the CONTRIBUTING.md file for guidelines.\n\n## License\n\nGit-fleximod is released under the MIT License.\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Extended support for git-submodule and git-sparse-checkout",
    "version": "0.5.0",
    "project_urls": {
        "Homepage": "https://github.com/jedwards4b/git-fleximod"
    },
    "split_keywords": [
        "git",
        "submodule",
        "sparse-checkout"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "157689321a0e1e0290fbf3a087f96e5ee2367a736691d7131f6aea0e2c6191fd",
                "md5": "5c24be2476da0835c7f2e1d61f3341e9",
                "sha256": "230c8c9cc468b510a6f08465ab4b3d4e1170072a85ef5a7563e5eb31f6bbea51"
            },
            "downloads": -1,
            "filename": "git_fleximod-0.5.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "5c24be2476da0835c7f2e1d61f3341e9",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8,<4.0",
            "size": 17754,
            "upload_time": "2024-02-03T21:02:42",
            "upload_time_iso_8601": "2024-02-03T21:02:42.795586Z",
            "url": "https://files.pythonhosted.org/packages/15/76/89321a0e1e0290fbf3a087f96e5ee2367a736691d7131f6aea0e2c6191fd/git_fleximod-0.5.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "ad61b79079d7f42b37446932b30f964f62d720dc95b08571f2e6b6f7381406e0",
                "md5": "5330c1b11130d9e96b6b9eb42f85dc2a",
                "sha256": "b52b01cfd6ed589259ae4b1f9b1edf1932113c8b8d21cefd225ef4e2f3ef3549"
            },
            "downloads": -1,
            "filename": "git_fleximod-0.5.0.tar.gz",
            "has_sig": false,
            "md5_digest": "5330c1b11130d9e96b6b9eb42f85dc2a",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8,<4.0",
            "size": 15666,
            "upload_time": "2024-02-03T21:02:44",
            "upload_time_iso_8601": "2024-02-03T21:02:44.368695Z",
            "url": "https://files.pythonhosted.org/packages/ad/61/b79079d7f42b37446932b30f964f62d720dc95b08571f2e6b6f7381406e0/git_fleximod-0.5.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-02-03 21:02:44",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "jedwards4b",
    "github_project": "git-fleximod",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "git-fleximod"
}
        
Elapsed time: 0.17369s