Socket
Socket
Sign inDemoInstall

@prettier/cli

Package Overview
Dependencies
Maintainers
14
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@prettier/cli - npm Package Compare versions

Comparing version 0.1.2 to 0.1.3

dist/constants.d.ts

7

dist/bin.js
#!/usr/bin/env node
import { bin, color } from "specialist";
import { PRETTIER_VERSION } from "./constants.js";
import { normalizeOptions } from "./utils.js";

@@ -11,3 +12,3 @@ import { run } from "./index.js";

.colors(true)
.package("prettier", "3.1.0")
.package("prettier", PRETTIER_VERSION)
/* USAGES */

@@ -126,3 +127,5 @@ .usage(`${color.cyan("prettier")} ${color.yellow("[file/dir/glob...]")} ${color.green("[options]")}`)

})
.option("--parallel", 'Process files in parallel\nDefaults to "false"')
.option("--no-parallel", 'Process files in parallel\nDefaults to "true"', {
default: true,
})
.option("--parallel-workers <int>", 'Number of parallel workers to use\nDefaults to "0"')

@@ -129,0 +132,0 @@ .option("--require-pragma", 'Require either "@prettier" or "@format" to be present in the file\'s first docblock comment in order for it to be formatted\nDefaults to "false"')

@@ -62,2 +62,4 @@ import yaml from "js-yaml";

continue;
if (!isObject(config))
continue;
return normalizePrettierOptions(config, folderPath);

@@ -64,0 +66,0 @@ }

@@ -7,2 +7,3 @@ import stringify from "json-sorted-stringify";

import { getPrettierConfigsMap, getPrettierConfigResolved } from "./config_prettier.js";
import { PRETTIER_VERSION, CLI_VERSION } from "./constants.js";
import Known from "./known.js";

@@ -29,4 +30,4 @@ import Logger from "./logger.js";

Known.addFolders(foldersExtraPaths);
const prettierVersion = "3.1.0"; //TODO: Hard-coding this is error-prone
const cliVersion = "0.1.0"; //TODO: Hard-coding this is error-prone
const prettierVersion = PRETTIER_VERSION;
const cliVersion = CLI_VERSION;
const pluginsVersions = ""; //TODO

@@ -33,0 +34,0 @@ const editorConfigs = options.editorConfig ? await getEditorConfigsMap(foldersPathsTargets) : {};

@@ -6,3 +6,3 @@ {

"license": "MIT",
"version": "0.1.2",
"version": "0.1.3",
"type": "module",

@@ -9,0 +9,0 @@ "bin": {

@@ -18,3 +18,3 @@ # prettier-cli

```sh
prettier src --check # Like before, but faster
prettier . --check # Like before, but faster
```

@@ -25,3 +25,3 @@

```sh
npx prettier@next src --check
npx prettier@next . --check
```
#!/usr/bin/env node
import { bin, color } from "specialist";
import { PRETTIER_VERSION } from "./constants.js";
import { normalizeOptions } from "./utils.js";

@@ -14,3 +15,3 @@ import { run } from "./index.js";

.colors(true)
.package("prettier", "3.1.0")
.package("prettier", PRETTIER_VERSION)
/* USAGES */

@@ -177,3 +178,5 @@ .usage(`${color.cyan("prettier")} ${color.yellow("[file/dir/glob...]")} ${color.green("[options]")}`)

})
.option("--parallel", 'Process files in parallel\nDefaults to "false"')
.option("--no-parallel", 'Process files in parallel\nDefaults to "true"', {
default: true,
})
.option("--parallel-workers <int>", 'Number of parallel workers to use\nDefaults to "0"')

@@ -180,0 +183,0 @@ .option(

@@ -63,2 +63,3 @@ import yaml from "js-yaml";

if (!config) continue;
if (!isObject(config)) continue;
return normalizePrettierOptions(config, folderPath);

@@ -65,0 +66,0 @@ } catch {

@@ -7,2 +7,3 @@ import stringify from "json-sorted-stringify";

import { getPrettierConfigsMap, getPrettierConfigResolved } from "./config_prettier.js";
import { PRETTIER_VERSION, CLI_VERSION } from "./constants.js";
import Known from "./known.js";

@@ -36,4 +37,4 @@ import Logger from "./logger.js";

const prettierVersion = "3.1.0"; //TODO: Hard-coding this is error-prone
const cliVersion = "0.1.0"; //TODO: Hard-coding this is error-prone
const prettierVersion = PRETTIER_VERSION;
const cliVersion = CLI_VERSION;
const pluginsVersions = ""; //TODO

@@ -40,0 +41,0 @@ const editorConfigs = options.editorConfig ? await getEditorConfigsMap(foldersPathsTargets) : {};

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc