Git Product home page Git Product logo

cures-condec-bitbucket's Introduction

cures-condec-bitbucket

Continuous integration Codacy Badge Codecoverage GitHub contributors Commitizen friendly semantic-release

The ConDec Bitbucket plugin provides decision knowledge support for pull requests. A pull request and its associated feature branch are related to one (or more) Jira issues. The ConDec Bitbucket plugin enables developers to view decision knowledge relevant for the Jira issue(s) directly within the pull request. This supports the developers in keeping the documented decision knowledge and the implementation of decisions consistent. Further, the plugin checks and enforces the completeness of the documented decision knowledge prior to merging. That is, the branch can only be merged back to mainline, if the decision knowledge has a certain quality. For example, the developers responsible for implementing a task must have at least one issue (decision problem) and one decision documented (will be configurable by the rationale manager in the future).

Installation

Prerequisites

The following prerequisites are necessary to compile the plug-in from source code:

Compilation via Terminal

The source code is compiled via terminal. Navigate into the cures-condec-bitbucket folder and run the following command:

atlas-mvn package

The .jar file is created.

Run the plug-in locally via:

atlas-run

Download of Precompiled .jar-File

The precompiled .jar-File for the latest release can be found here: https://github.com/cures-hub/cures-condec-bitbucket/releases/latest

Usage

Application Link between Bitbucket and Jira

To share decision knowledge between Jira and Bitbucket, they need to be linked via an application link. The authentication type needs to be OAuth (impersonation).

Pull Requests

The ConDec Bitbucket plugin integrates in the pull request page. The merge check can be enabled for single repositories. Configuration of the merge check Configuration possibility of the decision knowledge completeness merge check in the repository settings

The branch can only be merged if at least one decision problem and one decision is documented for every associated Jira issue.

Bitbucket ConDec plug-in Pull request view with disabled merge possibility

Bitbucket ConDec plug-in Pull request view with detailed documentation hint

Contribution

General Development Setup

Install all npm modules:

npm install

Commits and Releases

to support the release and commit standards you may install commitizen globally:

npm install commitizen -g

and after staging the files run:

git cz

or use it locally via:

npm run commit

to make a standard release:

npm run release

Setup of Coding Styling

esLint

if npm install doesn't show you the esLint errors try the following:

first install eslint to get linting errors shown globally

npm install eslint -g

then:

eslint --init

which will create a .eslintrc file now some code should be appear with errors like unused variables etc eventually some Eslint plugin has to be installed for your editor of choice

Prettier

Next we want the code to autoformat on save. For this we use Prettier, but with the rules from esLint and the defined rules from the .prettierc file. This step depends on the editor but for visual studio code you don't need to install the prettier plugin. just use the following settings:

{
    "editor.formatOnSave": true,
    "[javascript]": {
        "editor.formatOnSave": false,
    },
    "eslint.autoFixOnSave": true,
    "eslint.validate": [
        "javascript"
    ],
}

This ensures that javascript files are formated with esLint and not with the editor.

PreCommit Hook

Husky should ensure that only correctly linted code will be commited and pushed. This also works when commiting with commitizen. The pre-commit hook does only throw an error if one exists. To display potential errors run:

npm run lint:js

and to fix them:

npm run lint:fix

The fixed files have to be staged again before commiting.

cures-condec-bitbucket's People

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.