New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details
Socket
Book a DemoSign in
Socket

submodules-install

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

submodules-install

Module for automatically installing defined submodules

latest
npmnpm
Version
1.1.0
Version published
Weekly downloads
234
48.1%
Maintainers
1
Weekly downloads
 
Created
Source

submodules-install - NPM Submodules Installer

This module provides a system for calling npm i, yarn install, or a custom command on a list of locations, ultimately providing automatic submodule installation.

Usage

Install via npm:

npm i submodules-install --save

Or Yarn:

yarn add submodules-install

Add an array of strings using glob syntax or specially formatted objects to your package.json:

"submodules": [
  "my_subdir/*",
  "my_subdir2/**",
  {
    "path": "my_subdir3",
    "cmd": "go",
    "args": ["build"]
  }
]

Then run:

npx submodules-install

Alternatively, you may also use preinstall, postinstall, or otherwise:

"scripts": {
  "preinstall": "submodules-install"
}

Submodules Object

If an object is provided to the submodules array, it should match the following structure:

{
  path: String,     // Target glob to search.
  cmd: String,      // Optional. Command to use to run the install. Defaults to npm or yarn if a `yarn.lock` file is found.
  args: [String],   // Optional. Arguments to pass to the command. Defaults to `i` under npm or `install` under yarn.
  contains: String, // Optional. File to find in the glob result directory. Defaults to `package.json` if using npm or yarn.
}

Keywords

submodules-install

FAQs

Package last updated on 05 Jan 2024

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