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

mvdan-sh

Package Overview
Dependencies
Maintainers
1
Versions
19
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mvdan-sh - npm Package Compare versions

Comparing version 0.0.6 to 0.0.7

2

package.json
{
"name": "mvdan-sh",
"version": "0.0.6",
"version": "0.0.7",
"description": "A shell parser and formatter (POSIX/Bash/mksh)",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -21,8 +21,13 @@ # mvdan-sh

// what kind of command did we parse?
var stmt = f.StmtList.Stmts[0]
console.log(syntax.NodeType(stmt.Cmd)) // CallExpr
// print out the syntax tree
syntax.DebugPrint(f)
console.log()
// change 'foo' to 'bar'
stmt.Cmd.Args[1].Parts[0].Value = "bar"
// replace all single quoted string values
syntax.Walk(f, function(node) {
if (syntax.NodeType(node) == "SglQuoted") {
node.Value = "bar"
}
return true
})

@@ -29,0 +34,0 @@ // print the code back out

Sorry, the diff of this file is too big to display

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