Skip to content

Migrate shelljs to execa (#12) #17

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 31, 2025
Merged

Conversation

mattfsourcecode
Copy link
Owner

@mattfsourcecode mattfsourcecode commented Jan 31, 2025

Migrate from shelljs to execa to Resolve Dependency Warnings

Why this change?

Installing the module previously displayed the following warnings:

npm WARN deprecated inflight@1.0.6: This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful.
npm WARN deprecated glob@7.2.3: Glob versions prior to v9 are no longer supported

These warnings were caused by shelljs, which depends on outdated packages (inflight and glob@7). While shelljs maintainers have stated this does not pose a security risk, removing these deprecated dependencies is preferable for long-term maintainability.

What was changed?

  • Replaced shelljs with execa, a modern and well-maintained alternative for running shell commands in Node.js.
  • Updated all references to shell.exec(), shell.cd(), and shell.rm() with equivalent execa or fs functions.
  • Updated devDependencies.

Benefits of execa over shelljs

✅ Actively maintained and widely used.
✅ Better error handling and debugging capabilities.
✅ No reliance on deprecated dependencies.

This migration removes unnecessary package warnings and ensures the project remains up-to-date with maintained dependencies.


Closes #12

@mattfsourcecode mattfsourcecode merged commit 9aaac90 into master Jan 31, 2025
@mattfsourcecode mattfsourcecode deleted the migrate-shelljs-to-execa branch January 31, 2025 02:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Deprecation warnings for inflight and glob nested dependencies
1 participant