Observed since 20 Oct, 16:33 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
00akshatsinha00decomment
A CLI tool to remove comments from source code files
A powerful command-line tool that removes comments from your source code files while preserving the functionality of your code. Perfect for cleaning up codebases, preparing code for production, or creating comment-free versions of your files.
You can use this tool directly with npx without installing it globally:
npx 00akshatsinha00decomment -w .
Or install it globally if you prefer:
npm install -g 00akshatsinha00decomment
Remove comments from all files in the current directory:
npx 00akshatsinha00decomment -w .
Remove comments from specific JavaScript files:
npx 00akshatsinha00decomment -w *.js
Preview changes without modifying files:
npx 00akshatsinha00decomment myfile.js
00akshatsinha00decomment [options] <glob...>
Arguments:
glob glob pattern(s) of files to decomment
Options:
-V, --version output the version number
-w, --write overwrite files in-place
-o, --out <dir> write cleaned files to specified directory
-h, --help display help for command
-w, --writeModifies your files directly by removing comments and saving the changes back to the original files.
Example:
npx 00akshatsinha00decomment -w src/**/*.js
Warning: This permanently modifies your files. Make sure you have backups or version control in place.
-o, --out <directory>Creates cleaned versions of your files in a specified output directory while keeping your original files unchanged.
Example:
npx 00akshatsinha00decomment -o cleaned-code src/**/*.js
This creates a cleaned-code directory with comment-free versions of your files.
When you don't specify -w or -o, the tool displays the cleaned content in your terminal without modifying any files.
Example:
npx 00akshatsinha00decomment myfile.js
This tool works with all major programming languages and file types:
The tool automatically detects the file type and uses the appropriate comment removal strategy.
npx 00akshatsinha00decomment -w .
# Only JavaScript files
npx 00akshatsinha00decomment -w "**/*.js"
# Only CSS files
npx 00akshatsinha00decomment -w "**/*.css"
# Multiple file types
npx 00akshatsinha00decomment -w "**/*.{js,css,html}"
# Clean files in src directory
npx 00akshatsinha00decomment -w "src/**/*"
# Clean files in multiple directories
npx 00akshatsinha00decomment -w "src/**/*" "lib/**/*"
# Create cleaned versions in 'dist' folder
npx 00akshatsinha00decomment -o dist "src/**/*.js"
# See what changes would be made without modifying files
npx 00akshatsinha00decomment "src/myfile.js"
The tool removes various types of comments while preserving your code's functionality:
// This is a comment/* This is a comment *//** Documentation comment *//* CSS comment */<!-- HTML comment -->Your code functionality remains completely unchanged:
The tool handles errors gracefully and provides helpful feedback:
You can use powerful glob patterns to specify which files to process:
| Pattern | Description | Example |
|---|---|---|
* | Match any file in current directory | *.js |
** | Match files in any subdirectory | **/*.js |
? | Match single character | file?.js |
{a,b} | Match either a or b | *.{js,css} |
[abc] | Match any character in brackets | file[123].js |
-w-w flag firstnpx 00akshatsinha00decomment -o review-ready "src/**/*.js"
npx 00akshatsinha00decomment -w "dist/**/*.js"
npx 00akshatsinha00decomment -w "legacy/**/*.{js,css,html}"
npx 00akshatsinha00decomment -o examples "src/components/*.js"
If you see "No files found matching the specified patterns":
"**/*.js"If you encounter permission errors:
If the output isn't what you expected:
-w or -o)If your glob pattern isn't matching files:
** is needed for subdirectoriesISC License - see LICENSE file for details.
If you encounter issues or have questions:
Download counts and popularity will appear here as the collector receives them.
| Package / target | Requirement | Relationship |
|---|---|---|
globEnvironment{
"local_name": "glob",
"alias": false,
"peer_metadata": null
} | ^11.0.3 | runtime |
commanderEnvironment{
"local_name": "commander",
"alias": false,
"peer_metadata": null
} | ^14.0.0 | runtime |
strip-commentsEnvironment{
"local_name": "strip-comments",
"alias": false,
"peer_metadata": null
} | ^2.0.1 | runtime |
jestEnvironment{
"local_name": "jest",
"alias": false,
"peer_metadata": null
} | ^29.7.0 | development |
Source distribution
{
"shasum": "8c32d17f3fa3919274981734dcb02eafa3f297c5",
"tarball": "https://registry.npmjs.org/00akshatsinha00decomment/-/00akshatsinha00decomment-1.0.0.tgz",
"fileCount": 5,
"integrity": "sha512-zj1jrYJK+meo2ujmfsiGViYM5hnqG2xfwr6IpfF1D3ZRZrsg4q0xYhCU5iN0CDQHn7dtiH7AfT+GeSrJ2m3mpw==",
"signatures": [
{
"sig": "MEUCIFNAe4Hz4A+zozbQV+ib5uyUREJf3KMdEjG5ujcUo8yRAiEAh2/YuXD56dFB1G88XJAGulV/DDcEB8EnmBH1ttp+1j8=",
"keyid": "SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"
}
],
"unpackedSize": 14171
}Shared repository data · GitHub
Observed since 20 Oct, 16:33 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
package_version:b7effe1b3e66929660c1f18b27c129df935b771190cd2c81b08dfd364efd60f8