Name | giphon JSON |
Version |
0.2.0
JSON |
| download |
home_page | None |
Summary | Copy locally a Gitlab group or instance |
upload_time | 2024-05-24 13:33:16 |
maintainer | None |
docs_url | None |
author | None |
requires_python | >=3.7 |
license | None |
keywords |
clone
copy
gitlab
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
![Logo](https://raw.githubusercontent.com/kabooboo/giphon/0.2.0/docs/assets/logo.png)
![PyPI - Python Version](https://img.shields.io/pypi/pyversions/giphon) [![Black](https://img.shields.io/badge/code%20style-black-black.svg)](https://pypi.org/project/black/) ![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/kabooboo/giphon/test.yml?label=tests)
[![Hatch project](https://img.shields.io/badge/%F0%9F%A5%9A-Hatch-4051b5.svg)](https://github.com/pypa/hatch) ![PyPI](https://img.shields.io/pypi/v/giphon) ![PyPI - License](https://img.shields.io/pypi/l/giphon) ![GitHub Repo stars](https://img.shields.io/github/stars/kabooboo/giphon?style=social)
---
✨ Giphon is the contraction of 🦊 _Gitlab_ and 🫗 _siphon_. This CLI tools allows users
to recursively clone all projects in a given Gitlab group or instance.
## Motivation
This project aims to provide a tool capable of replicating a Gitlab group's
structure into a directory structure.
Locally cloned projects enable users to use familiar CLI tools such as `grep`
and `sed` directly into the projects' tree structure.
## Demo
![Usage GIF](https://raw.githubusercontent.com/kabooboo/giphon/0.2.0/docs/assets/usage.gif)
## Installation
To install `giphon`, simply run:
```sh
pip install --user giphon
```
And if you wish to use giphon by simply calling `giphon`, you can set-up an
alias in your `.bashrc` (or other, if you have another shell):
```sh
echo 'alias giphon="/usr/bin/env python3 -m giphon"' >> ~/.bashrc
```
## Parameters
The `giphon` tool allows for the following parameters:
- **namespace** (CLI: `--namespace`): The Gitlab namespace to be cloned. `/`
defaults to the whole instance.
- **output** (CLI: `--output`): The target path to clone the repositories to.
- **gitlab_token**: (CLI: `--gitlab-token`, env: `GITLAB_TOKEN`): The Personal
Access Token authenticating the user.
- **gitlab_url**: (CLI: `--gitlab-url`, env: `GITLAB_URL`): The URL of the Gitlab
instance to clone the repositories from. Defaults to `"https://gitlab.com"`
- **fetch_repositories**: (CLI: `--fetch-repositories`/`--no-fetch-repositories`):
Whether to fetch remotes on repositories that already exist.
- **save_ci_variables**: (CLI: `--save-ci-variables`/`--no-save-ci-variables`):
Whether to download CI/CD variables to a .env directory.
- **clone_archived** (CLI: `--clone-archived`/`--no-clone-archived`): Whether
to also clone archived repository.
- **clone_through_ssh**: (CLI: `--clone-through-ssh`/`--no-clone-through-ssh`):
Whether to use the SSH protocol or the HTTPS protocol to clone the git
repositories
- **gitlab_username** (CLI: `--gitlab-username`, env: `GITLAB_USERNAME`): The
username to use, when cloning through HTTPS.
- **verbose**: (CLI: `--verbose`/`-v`): The level of verbosity
## Running programmatically
You can import the main function from `giphon` as such:
```python
from pathlib import Path
from giphon.siphon import siphon
siphon(
namespace=Path("my-namespace"),
output=Path("~/Projects"),
gitlab_token="",
gitlab_url="https://gitlab.com",
fetch_repositories=True,
save_ci_variables=False,
clone_archived=False,
verbose=False,
)
```
The function takes as inputs the same parameters from the CLI tool.
---
Logo is © from [**Midjourney**](https://midjourney.com)
Raw data
{
"_id": null,
"home_page": null,
"name": "giphon",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.7",
"maintainer_email": null,
"keywords": "clone, copy, gitlab",
"author": null,
"author_email": "Gabriel Creti <gabrielcreti@gmail.com>",
"download_url": "https://files.pythonhosted.org/packages/2b/7f/c1bf5ce5beafdb254330f7b8802feb2606dfd84542125bc6068322fd874d/giphon-0.2.0.tar.gz",
"platform": null,
"description": "![Logo](https://raw.githubusercontent.com/kabooboo/giphon/0.2.0/docs/assets/logo.png)\n![PyPI - Python Version](https://img.shields.io/pypi/pyversions/giphon) [![Black](https://img.shields.io/badge/code%20style-black-black.svg)](https://pypi.org/project/black/) ![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/kabooboo/giphon/test.yml?label=tests)\n[![Hatch project](https://img.shields.io/badge/%F0%9F%A5%9A-Hatch-4051b5.svg)](https://github.com/pypa/hatch) ![PyPI](https://img.shields.io/pypi/v/giphon) ![PyPI - License](https://img.shields.io/pypi/l/giphon) ![GitHub Repo stars](https://img.shields.io/github/stars/kabooboo/giphon?style=social)\n\n---\n\n\u2728 Giphon is the contraction of \ud83e\udd8a _Gitlab_ and \ud83e\uded7 _siphon_. This CLI tools allows users\nto recursively clone all projects in a given Gitlab group or instance.\n\n## Motivation\n\nThis project aims to provide a tool capable of replicating a Gitlab group's\nstructure into a directory structure.\n\nLocally cloned projects enable users to use familiar CLI tools such as `grep`\nand `sed` directly into the projects' tree structure.\n\n## Demo\n\n![Usage GIF](https://raw.githubusercontent.com/kabooboo/giphon/0.2.0/docs/assets/usage.gif)\n\n## Installation\n\nTo install `giphon`, simply run:\n\n```sh\npip install --user giphon\n```\n\nAnd if you wish to use giphon by simply calling `giphon`, you can set-up an \nalias in your `.bashrc` (or other, if you have another shell):\n\n```sh\necho 'alias giphon=\"/usr/bin/env python3 -m giphon\"' >> ~/.bashrc\n```\n\n## Parameters\n\nThe `giphon` tool allows for the following parameters:\n\n- **namespace** (CLI: `--namespace`): The Gitlab namespace to be cloned. `/`\n defaults to the whole instance.\n- **output** (CLI: `--output`): The target path to clone the repositories to.\n- **gitlab_token**: (CLI: `--gitlab-token`, env: `GITLAB_TOKEN`): The Personal\n Access Token authenticating the user.\n- **gitlab_url**: (CLI: `--gitlab-url`, env: `GITLAB_URL`): The URL of the Gitlab\n instance to clone the repositories from. Defaults to `\"https://gitlab.com\"`\n- **fetch_repositories**: (CLI: `--fetch-repositories`/`--no-fetch-repositories`):\n Whether to fetch remotes on repositories that already exist.\n- **save_ci_variables**: (CLI: `--save-ci-variables`/`--no-save-ci-variables`):\n Whether to download CI/CD variables to a .env directory.\n- **clone_archived** (CLI: `--clone-archived`/`--no-clone-archived`): Whether\n to also clone archived repository.\n- **clone_through_ssh**: (CLI: `--clone-through-ssh`/`--no-clone-through-ssh`):\n Whether to use the SSH protocol or the HTTPS protocol to clone the git\n repositories\n- **gitlab_username** (CLI: `--gitlab-username`, env: `GITLAB_USERNAME`): The\n username to use, when cloning through HTTPS.\n- **verbose**: (CLI: `--verbose`/`-v`): The level of verbosity\n\n## Running programmatically\n\nYou can import the main function from `giphon` as such:\n\n```python\nfrom pathlib import Path\n\nfrom giphon.siphon import siphon\n\nsiphon(\n namespace=Path(\"my-namespace\"),\n output=Path(\"~/Projects\"),\n gitlab_token=\"\",\n gitlab_url=\"https://gitlab.com\",\n fetch_repositories=True,\n save_ci_variables=False,\n clone_archived=False,\n verbose=False,\n)\n```\n\nThe function takes as inputs the same parameters from the CLI tool.\n\n---\n\nLogo is \u00a9 from [**Midjourney**](https://midjourney.com)\n",
"bugtrack_url": null,
"license": null,
"summary": "Copy locally a Gitlab group or instance",
"version": "0.2.0",
"project_urls": {
"Bug Reports": "https://github.com/kabooboo/giphon/issues",
"Documentation": "https://github.com/kabooboo/giphon",
"Homepage": "https://github.com/kabooboo/giphon",
"Source Code": "https://github.com/kabooboo/giphon"
},
"split_keywords": [
"clone",
" copy",
" gitlab"
],
"urls": [
{
"comment_text": null,
"digests": {
"blake2b_256": "99a08f766a3c8181a07db31ba82a7f4d93c2681538f06d56cbaad430be4b1adc",
"md5": "25a0971e52c1fd3e6e352c1259e73ebe",
"sha256": "f968ed4ada2c883ad9ac007c83dab6b66c96aae85ed90bc2881d0db8e5568a73"
},
"downloads": -1,
"filename": "giphon-0.2.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "25a0971e52c1fd3e6e352c1259e73ebe",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.7",
"size": 13370,
"upload_time": "2024-05-24T13:33:18",
"upload_time_iso_8601": "2024-05-24T13:33:18.275100Z",
"url": "https://files.pythonhosted.org/packages/99/a0/8f766a3c8181a07db31ba82a7f4d93c2681538f06d56cbaad430be4b1adc/giphon-0.2.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "2b7fc1bf5ce5beafdb254330f7b8802feb2606dfd84542125bc6068322fd874d",
"md5": "3175d5a213e4aa86f4267a59d6b1b738",
"sha256": "31ece60f89734d5aef0e557d707d65030d08e56dedc705196a01e91cb095424b"
},
"downloads": -1,
"filename": "giphon-0.2.0.tar.gz",
"has_sig": false,
"md5_digest": "3175d5a213e4aa86f4267a59d6b1b738",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.7",
"size": 16536,
"upload_time": "2024-05-24T13:33:16",
"upload_time_iso_8601": "2024-05-24T13:33:16.769562Z",
"url": "https://files.pythonhosted.org/packages/2b/7f/c1bf5ce5beafdb254330f7b8802feb2606dfd84542125bc6068322fd874d/giphon-0.2.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-05-24 13:33:16",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "kabooboo",
"github_project": "giphon",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"requirements": [],
"lcname": "giphon"
}