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.76.tar.gz (4.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

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

Uploaded Python 3

File details

Details for the file scrippy_git-1.1.76.tar.gz.

File metadata

  • Download URL: scrippy_git-1.1.76.tar.gz
  • Upload date:
  • Size: 4.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.20

File hashes

Hashes for scrippy_git-1.1.76.tar.gz
Algorithm Hash digest
SHA256 ef8749a3cee9a4a4f445c8379700c38689ce56e88b7bd9a2f5c5a3ce776c32bd
MD5 d4b896111ddd81646ffef42834a0bd30
BLAKE2b-256 b96d471a5e8babdb10682653cdb067d71aae4764d472b74104df21a9c458ca09

See more details on using hashes here.

File details

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

File metadata

  • Download URL: scrippy_git-1.1.76-py3-none-any.whl
  • Upload date:
  • Size: 4.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.20

File hashes

Hashes for scrippy_git-1.1.76-py3-none-any.whl
Algorithm Hash digest
SHA256 155f4aee49210fd4005ce90e48a5f05c2f61d31bc3fd61e9416cc9a1f46752ad
MD5 9f2f11a53330180462ef3c8a46f499a4
BLAKE2b-256 7c4c977782d8d10dc5da284c9bfc989bd18d61fc11bee04393c4d433056536d1

See more details on using hashes here.

Supported by

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