Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
@layerzerolabs/export-deployments
Advanced tools
Export hardhat deploy deployments file into typescript
yarn add @layerzerolabs/export-deployments
pnpm add @layerzerolabs/export-deployments
npm install @layerzerolabs/export-deployments
This package comes with a CLI interface and registers an executable called @layerzerolabs/export-deployments
:
# When installed locally
@layerzerolabs/export-deployments --help
# Or using npx, preferred
npx @layerzerolabs/export-deployments
// generateSafe is an error-safe function that returns an Either<Error, OutputFile[]> object
import { generateSafe } from "@layerzerolabs/export-deployments";
// if throwing an error is desired, generate is a better option
import { generate } from "@layerzerolabs/export-deployments";
generateSafe({
deploymentsDir: "./my/deployments",
outDir: "./generated",
});
If filtering of networks is necessary, createIncludeDirent
utility can be used to construct a quick filtering function:
import {
createIncludeDirent,
generateSafe,
} from "@layerzerolabs/export-deployments";
const includedNetworks = ["arbitrum-mainnet"];
const excludedNetworks = ["telos-testnet"];
generateSafe({
deploymentsDir: "./my/deployments",
outDir: "./generated",
includeNetworkDir: createIncludeDirent(includedNetworks, excludedNetworks),
});
Similar goes for deployment files:
import {
createIncludeDirent,
generateSafe,
} from "@layerzerolabs/export-deployments";
// createIncludeDirent will handle the json extension internally
const includedContracts = ["MyContract", "OtherContract.json"];
const excludedContracts = ["TopSecret"];
generateSafe({
deploymentsDir: "./my/deployments",
outDir: "./generated",
includeDeploymentFile: createIncludeDirent(
includedContracts,
excludedContracts,
),
});
FAQs
Export hardhat deploy deployments file into typescript
The npm package @layerzerolabs/export-deployments receives a total of 221 weekly downloads. As such, @layerzerolabs/export-deployments popularity was classified as not popular.
We found that @layerzerolabs/export-deployments demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
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.
Research
Security News
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.