Skip to main content

"Socle de fonctions utilisées dans les scripts python de gestion d'infrastructure."

Project description

Build Status License Language

Scrippy, my Scrangourou friend

scrippy_git

Git client for the Scrippy framework.

Prerequisites

Python Modules

List of Required Modules

The modules listed below will be automatically installed.

  • GitPython

Installation

Manual

git clone https://codeberg.org/scrippy/scrippy-git.git
cd scrippy-git
python -m pip install -r requirements.txt
make install

With pip

pip install scrippy-git

Usage

The scrippy_git.git module provides the Repo object for easy manipulation of a Git repository.

import os
from scrippy_git import git

username = "git"
host = "gitlab.monty.py"
port = 2242
reponame = "luiggi.vercotti/monty_python.git"
branch = "master"

repo = git.Repo(username, host, port, reponame)
local_path = os.path.join(workspace_path, "monty_python")
repo.clone(branch=branch, path=local_path)

test_fname = os.path.join(local_path, "dead_parrot.txt")
with open(test_fname, mode="w") as test_file:
  test_file.write("Nobody expects the Spanish inquisition !")
  commit_message = "Inquisition shall not be expected"
  repo.commit_push(commit_message)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

scrippy-git-1.1.75.tar.gz (4.8 kB view details)

Uploaded Source

Built Distribution

scrippy_git-1.1.75-py3-none-any.whl (4.5 kB view details)

Uploaded Python 3

File details

Details for the file scrippy-git-1.1.75.tar.gz.

File metadata

  • Download URL: scrippy-git-1.1.75.tar.gz
  • Upload date:
  • Size: 4.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.13

File hashes

Hashes for scrippy-git-1.1.75.tar.gz
Algorithm Hash digest
SHA256 4fec7171711c9c8212b45a6ed458b3f83122f2c4674b1122fba4dafaf04c3c25
MD5 57bedde305d377f3c67245370d4cec82
BLAKE2b-256 cd7922a85e7eed94e640aa2cce395b8342d3cb619d4524c9e92d87c59af3b42b

See more details on using hashes here.

File details

Details for the file scrippy_git-1.1.75-py3-none-any.whl.

File metadata

File hashes

Hashes for scrippy_git-1.1.75-py3-none-any.whl
Algorithm Hash digest
SHA256 a012f186467dc86873d344f6d951832b9c64756c70cc8d219e7a8b672a67e3b3
MD5 e19a3f7bb12b1cf54f9674367a53d731
BLAKE2b-256 3505f670724a98b79f040a6da429580ef1a9a68edd2fc5c5d1ee0ba1634a830f

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page