Simple printing interface for jira
Project description
Jira does not provide a nice printable layout for tickets and nicer printing options are costly. This script just wraps the jira-api to allow formatting using jinja2 templates. This way, tickets can easily be formatted in a printer friendly way.
Getting started
The jiraprinter works on python3 only.
Jiraprinter is on pypi, so you can simply run
pip install jiraprinter
To install it. This will also create the two commands jira.py and prepare_token used below.
You can run the command line tool by calling
$ jira.py export <Ticket-Id> [<Ticket-Id> ...]
Here, angle brackets (<>) denote variable parameters and square brackets ([]) denote optional parameters. This is similar to unix man pages. You can start the web-interface for selecting tickets and printing them by calling
$ jira.py select
The web-interface will then be available at localhost:8080.
Setting your credentials
It is recommended that you put the URL of your jira server as well as your credentials into separate environment variables. Your user credentials need to be passed in base 64 encoding, which can be done using the prepare_token.py script:
$ prepare_token.py Please enter your jira user name: myname Please enter your jira password: fowkeofoakjdfolai
That last name is your jira credentials in base 64 encoding. It is recommended that you set your jira credentials and the url of the server in your bashrc (if you use bash). To do so, add the following lines to your ~/.bashrc file.
export JIRAURL=https://jira.mycompany/rest/api/2 export JIRACREDENTIALS=fowkeofoakjdfolai
Obviously, both the URL and the credentials are completely made up.
Authentication error
Error messages are typically rather long and complex. If you see a 401 status code somewhere at the end of the stacktrace, that means that you’re not correctly authenticated. In that case, you might want to check your user name and password.
Travis
Test status on current master:
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file jiraprinter-0.0.1.tar.gz
.
File metadata
- Download URL: jiraprinter-0.0.1.tar.gz
- Upload date:
- Size: 4.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 373248e69515a0615500d5292dd582af1c6eea524262e75d0c06bbce202b3192 |
|
MD5 | 5c3b627321335d4c4c6cbd504720d25a |
|
BLAKE2b-256 | 66a907660d3c7847d5b1ce60a55b8e2b998303a656804f945c8cfe174e709c14 |