From 5fa8df331e4a1489d95c94713fb2e33417be0018 Mon Sep 17 00:00:00 2001 From: Alex Rattray Date: Wed, 12 Apr 2017 18:51:08 -0700 Subject: [PATCH] Add cli option for --no-semi (#1223) --- bin/prettier.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/bin/prettier.js b/bin/prettier.js index a0c284c4..a75c9979 100755 --- a/bin/prettier.js +++ b/bin/prettier.js @@ -15,6 +15,7 @@ const argv = minimist(process.argv.slice(2), { "write", "stdin", "use-tabs", + "semi", "single-quote", "bracket-spacing", "jsx-bracket-same-line", @@ -121,6 +122,7 @@ function getTrailingComma() { const options = { useTabs: argv["use-tabs"], + semi: argv["semi"], printWidth: getIntOption("print-width"), tabWidth: getIntOption("tab-width"), bracketSpacing: argv["bracket-spacing"], @@ -185,6 +187,7 @@ if (argv["help"] || (!filepatterns.length && !stdin)) { " --print-width Specify the length of line that the printer will wrap on. Defaults to 80.\n" + " --tab-width Specify the number of spaces per indentation-level. Defaults to 2.\n" + " --use-tabs Indent lines with tabs instead of spaces. Defaults to false.\n" + + " --no-semi Do not print semicolons, except at the beginning of lines which may need them. Defaults to false.\n" + " --single-quote Use single quotes instead of double.\n" + " --bracket-spacing Put spaces between brackets. Defaults to true.\n" + " --jsx-bracket-same-line Put > on the last line. Defaults to false.\n" +