New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@arcsine/nodesh

Package Overview
Dependencies
Maintainers
1
Versions
34
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@arcsine/nodesh - npm Package Compare versions

Comparing version 1.6.1 to 1.6.2

2

CHANGELOG.md
Changelog
-----------------------------
## 1.6.0
## 1.6.2
Added in gzip/gunzip support

@@ -6,0 +6,0 @@ Supports glob patterns in file matching

@@ -1,1 +0,1 @@

"use strict";Object.defineProperty(exports,"__esModule",{value:!0});const readline=require("readline"),fs=require("fs"),stream_1=require("stream"),async_1=require("./async"),text_1=require("./text");class MemoryStream extends stream_1.Writable{constructor(){super(...arguments),this.store=[]}_write(a,b,c){this.store.push(a),c()}getText(){return Buffer.concat(this.store).toString("utf8")}}class StreamUtil{static memoryWritable(){return new MemoryStream}static toStream(a,b){const c=stream_1.Readable.from(async function*(){for await(const c of a){if(c===void 0){yield;continue}c instanceof Buffer?b&&"binary"!==b?yield text_1.TextUtil.toLine(c):yield c:b&&"text"!==b?yield Buffer.from(text_1.TextUtil.toText(c),"utf8"):yield text_1.TextUtil.toLine(c)}}());return c}static async*readStream(a,b={}){var c;const d=(c=b.mode,null!==c&&void 0!==c?c:"text"),e="string"==typeof a?fs.createReadStream(a,{encoding:"utf8"}):a,f=this.trackStream(e);if("raw"===d)return void(yield{stream:e,completed:f});const g="text"===d?readline.createInterface(e):e;let h,i=!1,j=[];const k=async a=>{var b;("string"==typeof a||a instanceof Buffer)&&j.push(a),null===(b=h)||void 0===b?void 0:b.resolve(null)};for(g.on("end",()=>k(i=!0)),g.on("close",()=>k(i=!0)),"text"===d?g.on("line",a=>k(text_1.TextUtil.toText(a))):g.on("data",a=>k("string"==typeof a?Buffer.from(a):a));!i;)await(h=async_1.AsyncUtil.resolvablePromise()),!b.singleValue&&j.length&&(yield*j,j=[]);b.singleValue&&(j="text"===d?[j.join("\n")]:[Buffer.concat(j)]),j.length&&(yield*j),e.destroyed||e.destroy(),await f}static trackStream(a,b=!0){const c=new Promise((b,c)=>{a.on("finish",b),a.on("end",b),a.on("close",b),a.on("error",c)});return b?async_1.AsyncUtil.trackWithTimer(c):c}static getWritable(a){return"string"!=typeof a&&"write"in a?a:fs.createWriteStream(a,{flags:"w",autoClose:!0})}}exports.StreamUtil=StreamUtil;
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});const readline=require("readline"),fs=require("fs"),stream_1=require("stream"),async_1=require("./async"),text_1=require("./text");class MemoryStream extends stream_1.Writable{constructor(){super(...arguments),this.store=[]}_write(a,b,c){this.store.push(a),c()}getText(){return Buffer.concat(this.store).toString("utf8")}}class StreamUtil{static memoryWritable(){return new MemoryStream}static toStream(a,b){const c=stream_1.Readable.from(async function*(){for await(const c of a){if(c===void 0){yield;continue}c instanceof Buffer?b&&"binary"!==b?yield text_1.TextUtil.toLine(c):yield c:b&&"text"!==b?yield Buffer.from(text_1.TextUtil.toText(c),"utf8"):yield text_1.TextUtil.toLine(c)}}());return c}static async*readStream(a,b={}){var c;const d=(c=b.mode,null!==c&&void 0!==c?c:"text"),e="string"==typeof a?fs.createReadStream(a,{encoding:"text"===d?"utf8":void 0}):a,f=this.trackStream(e);if("raw"===d)return void(yield{stream:e,completed:f});const g="text"===d?readline.createInterface(e):e;let h,i=!1,j=[];const k=async a=>{var b;("string"==typeof a||a instanceof Buffer)&&j.push(a),null===(b=h)||void 0===b?void 0:b.resolve(null)};for(g.on("end",()=>k(i=!0)),g.on("close",()=>k(i=!0)),"text"===d?g.on("line",a=>k(text_1.TextUtil.toText(a))):g.on("data",a=>k("string"==typeof a?Buffer.from(a,"utf8"):a));!i;)await(h=async_1.AsyncUtil.resolvablePromise()),!b.singleValue&&j.length&&(yield*j,j=[]);b.singleValue&&(j="text"===d?[j.join("\n")]:[Buffer.concat(j)]),j.length&&(yield*j),e.destroyed||e.destroy(),await f}static trackStream(a,b=!0){const c=new Promise((b,c)=>{a.on("finish",b),a.on("end",b),a.on("close",b),a.on("error",c)});return b?async_1.AsyncUtil.trackWithTimer(c):c}static getWritable(a){return"string"!=typeof a&&"write"in a?a:fs.createWriteStream(a,{flags:"w",autoClose:!0})}}exports.StreamUtil=StreamUtil;
{
"name": "@arcsine/nodesh",
"version": "1.6.1",
"version": "1.6.2",
"description": "A node-based library, providing Unix shell-like functionality",

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

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