GithubHelp home page GithubHelp logo

git-merge-request's Introduction

Git Merge Request

Create and list gitlab merge request

Installation

curl -o- "https://raw.githubusercontent.com/greedbell/git-merge-request/master/git-merge-request-install.sh" | /bin/sh

This command will install gmrl to list gitlab merge request, and gmrc to create gitlab merge request.

Usage

Set Environment

GITLAB_API_ADDRESS

the API address of gitlab. Default https://gitlab.com/api/v4.

custom GITLAB_API_ADDRESS

echo "export GITLAB_API_ADDRESS=\"Your Gitlab Api Address\"" >> ~/.bash_profile
source ~/.bash_profile

GITLAB_ACCESS_TOKEN

You must add environment variable GITLAB_ACCESS_TOKEN first,it is used to posting request to gitlab.

first got to Gitlab > Settings > Access Tokens to generate Access Token, attention, the scopes must contain api.

then set the token to environment

echo "export GITLAB_ACCESS_TOKEN=\"Your Gitlab Access Token\"" >> ~/.bash_profile
source ~/.bash_profile

Create Merge Request

Create Merge Request

$ gmrc -h

Usage:
 gmrc [-p <PROJECT NAME>] [-s <SOURCE BRANCH>] [-t <TARGET BRANCH>] [-m <TITLE>] [-d <DISABLE AUTO PUSH>] [-v] [-u] [-h]

Options:
 -p: target project, default current project
 -s: source branch, default current branch
 -t: target branch, default master
 -m: merge request title, default latest commit
 -d: whether disable auto push to remote branch, default true, if false disable
 -v: show version
 -u: check update
 -h: show help

Example 1:
 gmrc -p greedbell/git-merge-request -s test -t master -m title -d
Example 2
 gmrc

List Merge Request

List Merge Request

$ gmrl -h

Usage:
 gmrl [-p <PROJECT NAME>] [-s <STATE>] [-v] [-u] [-h]

Options:
 -p: target project, default current project
 -s: filt merge request, must be on of [all, opened, closed, locked, merged], default opened
 -v: show version
 -u: check update
 -h: show help

Example 1:
 gmrl -p greedbell/git-merge-request -s all
Example 2:
 gmrl

Update Merge Request

Directly use git push origin <BRANCH>

git-merge-request's People

Contributors

greedbell avatar

Stargazers

 avatar  avatar  avatar

Watchers

 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.