Add v9.1.1: Device registry and remote blocking system
- Implement DeviceRegistry for remote device management - Add dashboard for device tracking and blocking - Remote device blocking capability with admin control - Support for device aliasing and notes - Enhanced device management interface - Dashboard with real-time device status - Configurable registry URL in build config 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
34
dashboard/node_modules/simple-update-notifier/src/index.ts
generated
vendored
Normal file
34
dashboard/node_modules/simple-update-notifier/src/index.ts
generated
vendored
Normal file
@@ -0,0 +1,34 @@
|
||||
import isNpmOrYarn from './isNpmOrYarn';
|
||||
import hasNewVersion from './hasNewVersion';
|
||||
import { IUpdate } from './types';
|
||||
import borderedText from './borderedText';
|
||||
|
||||
const simpleUpdateNotifier = async (args: IUpdate) => {
|
||||
if (
|
||||
!args.alwaysRun &&
|
||||
(!process.stdout.isTTY || (isNpmOrYarn && !args.shouldNotifyInNpmScript))
|
||||
) {
|
||||
if (args.debug) {
|
||||
console.error('Opting out of running simpleUpdateNotifier()');
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
try {
|
||||
const latestVersion = await hasNewVersion(args);
|
||||
if (latestVersion) {
|
||||
console.error(
|
||||
borderedText(`New version of ${args.pkg.name} available!
|
||||
Current Version: ${args.pkg.version}
|
||||
Latest Version: ${latestVersion}`)
|
||||
);
|
||||
}
|
||||
} catch (err) {
|
||||
// Catch any network errors or cache writing errors so module doesn't cause a crash
|
||||
if (args.debug && err instanceof Error) {
|
||||
console.error('Unexpected error in simpleUpdateNotifier():', err);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
export default simpleUpdateNotifier;
|
||||
Reference in New Issue
Block a user