Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
This repo will hold some utilities that can be used in addition to Nx.
When working with a monorepo style of development, all apps are in a single repository. In Nx land, there are two important building blocks, apps and libs. Apps are deployable artifacts that are build up out of a number of different libs. A lib can be a feature module, some reusable code, component library, ...
When developing with such a repo, it can get hard to get an overview over all these different files. Let's say that I'm working on app1, I don't want to open up all the other apps in the monorepo in my IDE. But, due to the flat structure of apps in a single directory, it is impossible to avoid this.
Reasons I want to avoid this is:
Git supports a feature called sparse checkouts. In this scenario, you can create a file called 'sparse-checkout' where, using some globs, you can instruct git which folders to checkout and which ones to 'hide'. This means the folders are not visible on the file system!
Nx exposes some script that can help us build, test, lint, ... only affected apps or generate a dependency graph of the entire monorepo. Using these scripts, you can find out all the dependencies of a certain app.
Combining both features, the nx-etc 'checkout' functionality will checkout out only the files linked to a certain app.
yarn add --dev nx-etc
or
npm install --save-dev nx-etc
Note: We avoid having this installed globally, as we do with (almost) any package.
First of all, you need to enable sparse checkouts. Do this using
git config core.sparseCheckout true
To checkout one project use:
npx nx-etc checkout ${appName}
Note: When checking out an app, with dependant libs, the other libs and apps will be hidden! See below to checkout everything again.
To checkout multiple projects use:
npx nx-etc checkout ${appName1} ${appName2}
To checkout everything use:
npx nx-etc checkout
FAQs
This repo will hold some utilities that can be used in addition to Nx.
The npm package nx-etc receives a total of 0 weekly downloads. As such, nx-etc popularity was classified as not popular.
We found that nx-etc demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.