Skip to main content

Simple command-line client unifying access to Atlassian® services.

Project description

https://img.shields.io/travis/bkryza/atlssncli.svg https://img.shields.io/pypi/v/atlssncli.svg https://img.shields.io/pypi/l/atlssncli.svg https://img.shields.io/pypi/pyversions/atlssncli.svg

Simple command-line client unifying access to Atlassian ® services.

Overview

atlssncli is a simple command-line utility written in Python enabling easy, context-based access to various features of Atlassian® services over REST API. The context can be specified in the configuration file in terms of current board or project, and also is extracted automatically from the Git branch of the current working directory.

The goal of this project is to provide a concise command-line interface for everyday tasks involving sprint, issue and build management. atlssncli focuses on simplicity over completeness, to provide as quick as possible access to most commonly used features, assuming that more complex can be achieved otherwise, e.g. using web interface or other command line clients.

Please note, that atlssncli is tested with Jira® version 7.12.3 and Bamboo® version 6.9.2 only.

Installation

pip install atlssncli

Configuration

Configuration file should be placed in ~/.atlssncli/config.ini:

[common]
username = username
password = password
version = 6
active_project = BKP

[jira]
endpoint = https://jira.example.com/rest/api/latest

[agile]
endpoint = https://jira.example.com/rest/agile/latest
board = 7
sprint_duration = 14

[bamboo]
endpoint = https://bamboo.example.com/rest/api/latest
component1 = BKP-CMP1
component2 = BKP-CMP2
component3 = BKP-CMP3

Autocompletion

Bash

Add the following line to your ~/.bashrc:

eval "$(_ATLSSN_COMPLETE=source_bash atlssn)"

Zsh

Add the following line to your ~/.zshrc:

eval "$(_ATLSSN_COMPLETE=source_zsh atlssn)"

Basic usage

Command reference

info

Show information about services.

Show information about JIRA® service

atlssn info jira

Show information about Bamboo® service

atlssn info bamboo

agent

Bamboo® agents information, REST API for agents only supports a single method.

Show information about Bamboo® agents

atlssn agent list

project

Manage projects in the Jira® and Bamboo® services.

List all available projects

atlssn project list

Select currently active project

atlssn project select <project_key>

Get information about specific project

atlssn project info [<project_key>]

List project components

atlssn project list-components [<project_key>]

List project issue types

atlssn project list-issue-types [<project_key>]

board - manage Jira® boards

Get board backlog

atlssn board backlog [-a|--assignee <user_id>] [-q|--jql <jql_query>]

# Examples
atlssn board backlog -q 'status = "Open" AND assignee = "bkryza"'
atlssn board backlog -a bkryza

Get board list

atlssn board list

Set default board

atlssn board select <board_id>

Get board status

atlssn board status [<board_id>]

sprint - manage sprints

Below commands, which accept optional sprint_id, will act on active sprint when sprint_id is not provided.

List all sprints or sprints in a given state

atlssn sprint list [--active|--future|--closed]

Create sprint

atlssn sprint create [-n|--name <name>]
                     [-s|--start-date YYYY-MM-DD]
                     [-d|--duration <days>]

Rename sprint

atlssn sprint rename <sprint_id> <new_name>

Start sprint

atlssn sprint start <sprint_id> [<start_date> [<duration>]]

Stop sprint

atlssn sprint stop <sprint_id>

Get sprint status

atlssn sprint status [<sprint_id>]

List sprint issues

atlssn sprint issues [<sprint_id>]

List sprint issues by assignee

atlssn sprint issues [<sprint_id>] --assignee johndoe

List sprint issues by status

atlssn sprint issues [<sprint_id>] --resolved --closed

issue - manage issues

Get issue types for active project

**atlssn issue types

Get issue types for specific project

**atlssn issue types <project_id>

Create issue

**atlssn issue create <summary> [-t|--type <issue_type>]
                              [-a|--assignee <username>]
                              [-r|--reporter <username>]
                              [-i|--priority <priority>]
                              [-l|--labels <label>,<label>,...,<label>]
                              [-d|--description <text>]
                              [-x|--fix-versions <versions>]
                              [-c|--components <component>,...,<component>]

Edit issue

**atlssn issue edit <issue_id> [-t|--type <issue_type>]
                             [-a|--assignee <username>]
                             [-r|--reporter <username>]
                             [-i|--priority <priority>]
                             [-l|--labels <label>,<label>,...,<label>]
                             [-d|--description <text>]
                             [-x|--fix-versions <versions>]
                             [-c|--components <component>,...,<component>]

Get issue status

atlssn issue status <issue_id>

Assign issue

atlssn issue assign <issue_id> <username>

Get issue changelog

**atlssn issue changelog <issue_id>

Add issue comment

**atlssn issue comment <issue_id> <comment>

Change issue state

**atlssn issue update <issue_id> <comment>

List issue attachments

**atlssn issue attachments <issue_id>

Add issue attachment

**atlssn issue attach <issue_id> <file_path>

Delete issue attachment

**atlssn issue detach <issue_id> <file_name>

List possible issue transitions

**atlssn issue transitions <issue_id>

Transition issue to different state

**atlssn issue transition <issue_id> <state_name>

List possible issue resolutions

**atlssn issue resolutions <issue_id>

Resolve issue

**atlssn issue resolve <issue_id> <resolution>

Create branch from issue

**atlssn issue branch <issue_id> <state_name>

List Git branches for issue

**atlssn issue branches <issue_id>

TODO

  • Refactor output formatting to enable custom formatters

  • Add OAuth support

  • Move todo’s to GitHub issues

License

Copyright 2019-present Bartosz Kryza <bkryza@gmail.com>

Licensed under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an “AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

All Atlassian® services referenced in this project are registered trademarks of Atlassian Corporation Plc.

The author of this project is not affiliated in any way with Atlassian Corporation Plc.

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

atlssncli-0.0.3.tar.gz (27.1 kB view details)

Uploaded Source

File details

Details for the file atlssncli-0.0.3.tar.gz.

File metadata

  • Download URL: atlssncli-0.0.3.tar.gz
  • Upload date:
  • Size: 27.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.50.0 CPython/3.8.5

File hashes

Hashes for atlssncli-0.0.3.tar.gz
Algorithm Hash digest
SHA256 932b479e9eb530367c2b249bdf420f845d178f874978101dd8a97f11c6b0edc5
MD5 8ec3ce5a59e70d0c210c41b44e7d1ee9
BLAKE2b-256 73dc93a6da7f942afe3495c0703ca4645861451778d66fecea41fdc4cd8138fd

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