6
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

git commit --allow-empty -m "empty commit"

Last updated at Posted at 2022-02-28

何も変更をしていないけれども、コミットをしたいことありますよね!
私はあります。
PaaS(Platform as a Service)のアレをナニするときですよ。
これ以上は言いますまい。

git commit --allow-empty -m "empty commit"

これです。

ヘルプ

--allow-emptyとはどういう意味なのかを調べてみます。

git help commit

上記のコマンドを実行して出てきたヘルプの中から、--allow-emptyを抜粋しておきます。

--allow-empty
  Usually recording a commit that has the exact same tree as its sole parent commit is a mistake, and the
  command prevents you from making such a commit. This option bypasses the safety, and is primarily for use
  by foreign SCM interface scripts.

記事にした背景

git commit --allow-empty -m "empty commit"

上記を私は覚えられません。
アウトプットをすることで脳が大事なことだと記憶してくれるんです。

elixir.jpというSlackワークスペースの#autoracexというチャンネルで、以前の私の書き込みが役に立ったよ〜 という方がいらっしゃっいました。

スクリーンショット 2022-02-28 22.55.54.png

それで他の方の役に立つことがあるかもしれないとおもいまして、記事にしておきました。

自分自身の記憶のためと、まだ知らないあなたのために書いています。
つまりは
$\huge{愛💜}$
です。

この記事は

Advent Calendar 2022 58日目1の記事です。
I'm looking forward to 12/25,2022 :santa::santa_tone1::santa_tone2::santa_tone3::santa_tone4::santa_tone5:
私のAdvent Calendar 2022 一覧

次回もお楽しみに〜。

花の色はうつりにけりないたづらにわが身世にふるながめせしまに

  1. @kaizen_nagoya さんの「「@e99h2121 アドベントカレンダーではありますまいか Advent Calendar 2020」の改訂版ではありますまいか Advent Calendar 2022 1日目 Most Breakthrough Generator」から着想を得て、模倣いたしました。

6
2
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
6
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?