{"id":27107802,"url":"https://github.com/basemax/js-logs-remover-go","last_synced_at":"2026-05-09T14:12:32.562Z","repository":{"id":286416981,"uuid":"961337340","full_name":"BaseMax/js-logs-remover-go","owner":"BaseMax","description":"js-logs-remover is a command-line utility written in Go that removes specified `console` logging methods (e.g., `console.log()`, `console.error()`) from JavaScript/TypeScript files within a directory. This tool is useful for cleaning up log statements before deploying or publishing code.","archived":false,"fork":false,"pushed_at":"2025-04-06T11:16:39.000Z","size":11,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-06T11:21:50.734Z","etag":null,"topics":["console","console-log","console-logger","go","golang","javascript","js"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/BaseMax.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-04-06T09:54:21.000Z","updated_at":"2025-04-06T11:16:42.000Z","dependencies_parsed_at":"2025-04-06T11:21:51.881Z","dependency_job_id":"00bc86ac-4f4f-4589-b425-ddc5ea322b60","html_url":"https://github.com/BaseMax/js-logs-remover-go","commit_stats":null,"previous_names":["basemax/js-logs-remover"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BaseMax%2Fjs-logs-remover-go","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BaseMax%2Fjs-logs-remover-go/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BaseMax%2Fjs-logs-remover-go/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BaseMax%2Fjs-logs-remover-go/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/BaseMax","download_url":"https://codeload.github.com/BaseMax/js-logs-remover-go/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247553239,"owners_count":20957434,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["console","console-log","console-logger","go","golang","javascript","js"],"created_at":"2025-04-06T21:28:08.232Z","updated_at":"2026-05-09T14:12:32.517Z","avatar_url":"https://github.com/BaseMax.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# js-logs-remover in Go\n\n`js-logs-remover` is a command-line utility written in Go that removes specified `console` logging methods (e.g., `console.log()`, `console.error()`) from JavaScript/TypeScript files within a directory. This tool is useful for cleaning up log statements before deploying or publishing code.\n\n## Features\n\n- Removes specified `console` methods from JavaScript, TypeScript, JSX, and TSX files.\n- Processes files recursively within directories, excluding certain common directories such as `node_modules`, `.git`, `dist`, and `build`.\n- Supports both specified log methods and a global \"all\" option to remove all defined `console` methods.\n\n## Installation\n\nTo install `js-logs-remover`, you must have Go installed on your machine.\n\n1. Clone the repository:\n\n   ```bash\n   git clone https://github.com/BaseMax/js-logs-remover-go.git\n   ```\n\n2. Navigate to the directory:\n\n   ```bash\n   cd js-logs-remover-go\n   ```\n\n3. Build the Go application:\n\n   ```bash\n   go build\n   ```\n\nAfter building, you will have a js-logs-remover binary in the project directory.\n\n## Usage\n\nRun the tool from the command line:\n\n```bash\n$ js-logs-remover [path] [log-methods]\n```\n\n`[path]`: The directory or file path where you want to remove the logs from. If no path is provided, it defaults to the current directory (.).\n\n`[log-methods]`: A comma-separated list of console methods you want to remove (e.g., log,error,warn). If you specify all, it will remove all known console methods.\n\n## Example Usage\n\nRemove specific console methods: To remove console.log and console.warn from all .js, .ts, .jsx, and .tsx files within the src directory:\n\n```bash\n$ js-logs-remover src log,warn\n```\n\nRemove all console methods: To remove all console methods (like console.log, console.error, etc.) from all files in the src directory:\n\n```bash\n$ js-logs-remover src all\n```\n\nProcess the current directory: To process the current directory and remove console.log:\n\n```bash\n$ js-logs-remover . log\n```\n\n### Excluded Directories\n\nThe following directories are automatically excluded from processing:\n\n- node_modules\n- .git\n- dist\n- build\n\n## License\n\nThis project is licensed under the MIT License - see the LICENSE file for details.\n\n## Copyright\n\n© 2025 Max Base. All rights reserved.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbasemax%2Fjs-logs-remover-go","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbasemax%2Fjs-logs-remover-go","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbasemax%2Fjs-logs-remover-go/lists"}