From f56274bbc0e5045deb88b4709ef7ecc52d72a0ba Mon Sep 17 00:00:00 2001 From: Nicholas Long Date: Thu, 18 Jun 2020 11:47:51 -0600 Subject: [PATCH] update how to include in precommit --- README.md | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 4b338ea..8fce58c 100644 --- a/README.md +++ b/README.md @@ -22,7 +22,10 @@ To run the example: The resulting .mo file can be diffed to the previous file to compare how the modelica-fmt updates the file. ## Usage with pre-commit framework -After adding modelicafmt to your system path, add the following lines to your .pre-commit-config.yaml file under the `repos:` section + +After adding modelicafmt to your system path, add the following lines to your .pre-commit-config.yaml file under the `repos:` section. +Also, make sure to allow modelicafmt to run (especially on Mac). + ```yaml - repo: local @@ -30,6 +33,8 @@ After adding modelicafmt to your system path, add the following lines to your .p - id: modelica-fmt name: Modelica Formatter + types: [file] + files: \.(mo)$ entry: modelicafmt args: ["-w"] language: system