Skip to content

leotabosa/commitlint-example

Repository files navigation

Instructions

Clone this repo with:

git clone [email protected]:leotabosa/commitlint-example.git

Install all dependencies with:

yarn install

Now add a file:

echo  "hello"  >> temp_file

Stage the file and commit (this should fail):

git add temp_file

git commit -m "testing"

Why?

return [
  String(header).startsWith("#"),

  `${error}Commit message should start with '#NNNNN' (task number).`,
];

Now commit with a message matching the expected pattern:

git commit -m "#1 - Testing"