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.
electron-lets-move
Advanced tools
[![npm version](https://badge.fury.io/js/electron-lets-move.svg)](https://badge.fury.io/js/electron-lets-move)
A module that offers to automatically move your Electron app to the Applications folder if opened from another location. Inspired by LetsMove for MacOS.
This module is designed to be used within Electron on macOS, it can be included in a cross platform Electron app and is a no-op on the Windows and Linux platforms.
npm install --save electron-lets-move
You should call the moveToApplications
method as soon as possible after the app
ready event in the main process. Ideally before the user has any chance to interact
with the application.
moveToApplications
returns a promise that will resolve when the application is
in the correct location, the user asked not to move or an error occurred. You can
also provide an optional node-style callback as the only parameter.
const {app} = require('electron');
const {moveToApplications} = require('electron-lets-move');
app.on('ready', function() {
moveToApplications(function(err, moved) {
if (err) {
// log error, something went wrong whilst moving the app.
}
if (!moved) {
// the user asked not to move the app, it's up to the parent application
// to store this information and not hassle them again.
}
// do the rest of your application startup
});
});
import {app} from 'electron';
import {moveToApplications} from 'electron-lets-move';
app.on('ready', async () => {
try {
const moved = await moveToApplications();
if (!moved) {
// the user asked not to move the app, it's up to the parent application
// to store this information and not hassle them again.
}
} catch (err) {
// log error, something went wrong whilst moving the app.
}
// do the rest of your application startup
});
Electron LetsMove is released under the MIT license. It is simple and easy to understand and places almost no restrictions on what you can do with it. More Information
FAQs
[![npm version](https://badge.fury.io/js/electron-lets-move.svg)](https://badge.fury.io/js/electron-lets-move)
The npm package electron-lets-move receives a total of 0 weekly downloads. As such, electron-lets-move popularity was classified as not popular.
We found that electron-lets-move 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.