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

github.com/abranhe/concurrent-benchmark

Package Overview
Dependencies
Alerts
File Explorer
Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

github.com/abranhe/concurrent-benchmark

  • v0.0.0-20220325033651-6bdbd4ac02f4
  • Source
  • Go
  • Socket score

Version published
Created
Source

Work In Progress...

concurrent-benchmark

test lint codeql report-card npm license

Benchmark scripts concurrently.

Description

Right now I am just playing around, but I am planning (maybe) to make something serious in the future.

concurrent-benchmark has the alias cb.

Install

$ yarn global add concurrent-benchmark

Usage

CLI

Let's take fixture.js as an example. It has a setTimeout that waits for 2 seconds.

$ time cb \
    'node fixture.js' \
    'node fixture.js' \
    'node fixture.js' \
    'node fixture.js'

So instead of taking using 1 thread (~8s) we are going to use 4 threads (~2s), one for each command. The output of this will get a few console.logs be something like:

real    0m2.289s
user    0m0.157s
sys     0m0.237s

Where real is the time it took to run the command.

Package

Not yet implemented.

import cb from 'concurrent-benchmark';

cb.run([
  {
    name: 'foo',
    script: 'echo foo',
  },
  {
    name: 'bar',
    script: 'echo bar',
  },
]);

FAQs

Package last updated on 25 Mar 2022

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

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