Status
検討候補 / future candidate
現時点では実装順・release targetを確定しない。
Goal
repeatableな--exclude PATHを多数指定する用途向けに、exclude path listをfileから読み込む仕組みを検討する。
候補CLI:
dotdoc --exclude-from .dotdoc-exclude "$HOME"
Motivation
--excludeは明示的で小さなCLI contractとして扱いやすい一方、広いscan rootで除外対象が増えるとcommand lineが長くなる。
既存の--exclude semanticsを再利用し、fileは単にliteral path listを供給するだけの最小拡張を第一候補とする。
Preliminary semantics
- file内は1行1pathを基本案とする
- 各pathは既存
--exclude PATHと同じくscan-root-relative
- lexical normalization / absolute path rejection / root escape rejection等は既存
--exclude contractを再利用する
- directoryはsubtree prune、file / symlinkはexact skip
- nonexistent exclude pathは既存contractどおりno-op
--excludeと--exclude-fromは併用可能にする案を基本とする
Open questions
- empty lineを無視するか
# comment syntaxを持つか、それともliteral-onlyに徹するか
- duplicate pathの扱い
- exclude file自体が存在しない / unreadable場合のerror contract
--exclude-fromをrepeatableにするか
- stdin (
--exclude-from -) をサポートするか
Important boundary
初期案ではgitignore互換機能にしない。
以下は別の必要性が確認されるまで導入しない。
- glob (
*, **, ?)
- regex
- negation rule (
!)
.gitignore parser
- directoryごとのignore inheritance
目的は既存のliteral --exclude をfileへ退避できることに限定する。
Non-goals
.gitignore自動利用
- built-in ignore list
- generic config file
- diagnostic kind別ignore
- full ignore engine
Acceptance criteria candidate
Status
検討候補 / future candidate
現時点では実装順・release targetを確定しない。
Goal
repeatableな
--exclude PATHを多数指定する用途向けに、exclude path listをfileから読み込む仕組みを検討する。候補CLI:
dotdoc --exclude-from .dotdoc-exclude "$HOME"Motivation
--excludeは明示的で小さなCLI contractとして扱いやすい一方、広いscan rootで除外対象が増えるとcommand lineが長くなる。既存の
--excludesemanticsを再利用し、fileは単にliteral path listを供給するだけの最小拡張を第一候補とする。Preliminary semantics
--exclude PATHと同じくscan-root-relative--excludecontractを再利用する--excludeと--exclude-fromは併用可能にする案を基本とするOpen questions
#comment syntaxを持つか、それともliteral-onlyに徹するか--exclude-fromをrepeatableにするか--exclude-from -) をサポートするかImportant boundary
初期案ではgitignore互換機能にしない。
以下は別の必要性が確認されるまで導入しない。
*,**,?)!).gitignoreparser目的は既存のliteral
--excludeをfileへ退避できることに限定する。Non-goals
.gitignore自動利用Acceptance criteria candidate
--excludeと同じvalidation / normalization semanticsを適用する--excludeと併用できる--help/ man / README EN・JAを必要に応じて更新するmake testが通る