LoginSignup
15
11

More than 5 years have passed since last update.

スラッシュコマンド活用術

Posted at

GitLabのスラッシュコマンド

GitLab slash commands
GitLabのスラッシュコマンドをご存知でしょうか?
GitLabで通常、ボタンやドロップダウンで行えるIssuesまたはMergeRequestの一般的な動作をテキストエリアにコマンドを入力することでショートカットする方法です。

スラッシュコマンドを覚えると非常に便利です。

Command Action
/close issue または merge request をclose
/reopen issue または merge request をReopen
/title <New title> タイトルを変更
/assign @username Assignする
/unassign Assignしない
/milestone %milestone milestoneの設定
/remove_milestone milestoneを外す
/label ~foo ~"bar baz" label(s)の追加
/unlabel ~foo ~"bar baz" Remove all or specific label(s)
/relabel ~foo ~"bar baz" Replace all label(s)
/todo todoに追加
/done todoをdoneへ
/subscribe Subscribe :thumbsup:
/unsubscribe Unsubscribe :thumbsdown:
/due <in 2 days | this Friday | December 31st> due dateを設定
/remove_due_date due dateを外す
/wip Toggle the Work In Progress status

使い方

とっても簡単です。
IssuesやMergeRequestのcommentsの中にコマンドを打ち込みOSXだとCmd + Enter、WindowsだとCtrl + Enterでcommentするだけ

例えばOpenのIssueをCloseする場合

  1. /を入れるだけでインテリセンスが聞きます。
    1.png

  2. /Closeを選択後comment
    2.png

  3. Your commands have been executed!というメッセージが表示で完了
    3.png

リロードすればClosedになっているのが確認できます。
4.png

非常に簡単なので活用していきましょう。特にLabelはよく使います。

15
11
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
15
11