Todoの良くないところは消し込んだ後にデータが見えなくなってしまうことです。そうなるとただ消化するのが目的になってしまい、後で振り返るのが難しくなります。本来はレポーティングこそが大事なはずです。 そこで使ってみたいのがGit-todosです。TodoをGitを使って管理するソフトウェアです。

Git-todosの使い方

Git-todosはGitリポジトリの中で実行します。

$ git-todos add
? Title (Required) テストのタスク
? Description 説明文
✔ A Todo has been added
✔ You rock! ?

listコマンドでタスクの一覧が表示できます。

$ git-todos list

1) テストのタスク
2) 記事を書く

You've got this ?

設定ファイルは .todos.yml になります。

$ cat .todos.yml 
todos:
- title: テストのタスク
  description: 説明文
  marked: false
  id: 0
- title: 記事を書く
  description: 20日までにやる
  marked: false
  id: 0

finish を使ってタスクを完了できます。この際、自動的にリポジトリにコミットしてくれます。

$ git-todos finish
? Select an item (Use arrow keys) テストのタスク
? Type of change that you're committing (Required) feat
? Denote the scope of this change 
? Short description テストのタスク
? Longer description of the change 
? List any issues closed by this change 
✔ Your work has been commited
✔ A Todo has been removed
✔ You're smart enough! ?

Gitなのでログも追えます。

$ git log
commit 223b250fb4c9a24a2061c21d29dcb2c4e14bd6f0
Author: Atsushi Nakatsugawa <atsushi @moongift.jp>
Date:   Sun Dec 17 22:31:28 2017 +0900

    feat: テストのタスク

Git-todosはコマンド一つ一つに対してコミットが発生するのでタスクの状態を履歴管理できるようになります。履歴を閲覧するインタフェースはないので自作あるいはログを見る必要があるのは残念ですが、まず履歴管理されていることが大事でしょう。

Git-todosはGo製のオープンソース・ソフトウェア(Apache Licnese 2.0)です。

ahmed-taj/git-todos: A Git based Todos App for Developers