Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

git-format-staged

Package Overview
Dependencies
Maintainers
1
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

git-format-staged - npm Package Compare versions

Comparing version 2.0.0 to 2.1.0

2

package.json
{
"name": "git-format-staged",
"version": "2.0.0",
"version": "2.1.0",
"description": "Git command to transform staged files according to a command that accepts file content on stdin and produces output on stdout.",

@@ -5,0 +5,0 @@ "scripts": {

@@ -64,3 +64,3 @@ # git-format-staged

$ git-format-staged --formatter 'prettier --stdin' 'src/*.js'
$ git-format-staged --formatter 'prettier --stdin --stdin-filepath "{}"' 'src/*.js'

@@ -88,2 +88,12 @@ That will format all files under `src/` and its subdirectories using

The formatter command may include a placeholder, `{}`, which will be replaced
with the path of the file that is being formatted. This is useful if your
formatter needs to know the file extension to determine how to format or to
lint each file. For example:
$ git-format-staged -f 'prettier --stdin --stdin-filepath "{}"' '*.js' '*.css'
Do not attempt to read or write to `{}` in your formatter command! The
placeholder exists only for referencing the file name and path.
### Check staged changes with a linter without formatting

@@ -90,0 +100,0 @@

Sorry, the diff of this file is not supported yet

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