GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - ficoos/python-gerrit: Python bindings for Gerrit

BranchesTags
Open more actions menu

Latest commit

 

History

7 Commits
7 Commits

Folders and files

NameName
Last commit message
Last commit date
gerrit
gerrit
 
 
.gitignore
.gitignore
 
 
LICENCE
LICENCE
 
 
README.md
README.md
 
 
setup.py
setup.py
 
 

Repository files navigation

python-gerrit

Gerrit bindings for python

The bindings are still a work in progress!

How to use

  • Connect to a server:
    import gerrit
    import paramiko

    pkey = paramiko.RSAKey(filename="/home/foo/.ssh/id_rsa.pub")
    username = "Bob"
    host = "example.com"
    port = 29418  # Default Gerrit ssh port

    g = Gerrit(host, port, username, pkey)
  • Query for changes:
    g = Gerrit(host, port, username, pkey)

    # Query for all changes in project 'bar' including comments
    changes = g.query("project:bar", options=[QueryOptions.Comments])
    for change in changes:
    	print change
  • Add a reviewer:
    g = Gerrit(host, port, username, pkey)

    # Query for all changes in project 'bar' including the current patch-set
    changes = g.query("project:bar", options=[QueryOptions.CurrentPatchSet])
    for change in changes:
    	revision = change['currentPatchSet']['revision']
    	g.set_reviewers(revision, add=[username])
  • Add a review
    g = Gerrit(host, port, username, pkey)

    # Query for all changes in project 'bar' including the current patch-set
    changes = g.query("project:bar", options=[QueryOptions.CurrentPatchSet])
    for change in changes:
    	revision = change['currentPatchSet']['revision']
    	g.review(revision, message="Hello World!")

About

Python bindings for Gerrit

Resources

Readme
License
Activity

Stars

3 stars

Watchers

2 watching

Forks

2 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.