{"id":24300663,"url":"https://github.com/jeeftor/license-manager","last_synced_at":"2026-02-11T22:23:35.120Z","repository":{"id":272647203,"uuid":"917306808","full_name":"jeeftor/license-manager","owner":"jeeftor","description":"CLI application to manage license headers","archived":false,"fork":false,"pushed_at":"2025-02-18T22:14:41.000Z","size":417,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-18T22:25:46.301Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/jeeftor.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-01-15T18:31:41.000Z","updated_at":"2025-02-18T22:14:38.000Z","dependencies_parsed_at":"2025-01-15T21:16:50.681Z","dependency_job_id":"9e779f54-2598-4611-95a3-7eb4feb64ea2","html_url":"https://github.com/jeeftor/license-manager","commit_stats":null,"previous_names":["jeeftor/license-manager"],"tags_count":34,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jeeftor%2Flicense-manager","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jeeftor%2Flicense-manager/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jeeftor%2Flicense-manager/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jeeftor%2Flicense-manager/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jeeftor","download_url":"https://codeload.github.com/jeeftor/license-manager/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":242213776,"owners_count":20090700,"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":[],"created_at":"2025-01-16T23:15:51.702Z","updated_at":"2026-02-11T22:23:30.098Z","avatar_url":"https://github.com/jeeftor.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# License Manager\n[![pre-commit](https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit)](https://github.com/pre-commit/pre-commit)\n[![Go Report Card](https://goreportcard.com/badge/github.com/jeeftor/license-manager)](https://goreportcard.com/report/github.com/jeeftor/license-manager)\n[![License](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)\n\n![GitHub commit activity](https://img.shields.io/github/commit-activity/w/jeeftor/license-manager)\n![GitHub commits since latest release](https://img.shields.io/github/commits-since/jeeftor/license-manager/latest)\n![GitHub Release Date](https://img.shields.io/github/release-date/jeeftor/license-manager)\n![GitHub Downloads (all assets, all releases)](https://img.shields.io/github/downloads/jeeftor/license-manager/total)\n![GitHub Repo stars](https://img.shields.io/github/stars/jeeftor/license-manager)\n\n![docs/logo.png](docs/logo.png)\nA CLI tool and a [Pre-Commit Hook](docs/pre-commit.md) for managing license headers in source code files. This tool helps you add, remove, update, and check license headers across your codebase with ease and precision. It utilizes non-printing Unicode character to mark the start \u0026 end of the License comment such that you can easier update or remove the license information.\n\n[![Go Report Card](https://goreportcard.com/badge/github.com/yourusername/license-manager)](https://goreportcard.com/report/github.com/yourusername/license-manager)\n[![License](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)\n\n## Features\n\n- **Add License Headers**: Automatically add license headers to files that don't have them\n- **Remove License Headers**: Clean up license headers from files\n- **Update License Headers**: Replace existing license headers with new content\n- **Check License Headers**: Verify if files have the correct license headers\n- **Multiple File Support**: Process multiple files using glob patterns\n- **Customizable Comment Styles**: Supports various programming language comment styles\n- **Dry Run Mode**: Preview changes before applying them\n- **Interactive Mode**: Confirm changes for each file\n- **Verbose Output**: Detailed logging for better visibility\n- **Skip Patterns**: Exclude specific files or directories\n- **Preset Header Styles**: Choose from predefined header/footer styles\n\n\n### Fully Tested Languages\nThis is a list of languages that have been ~fully~ mostly tested.\n\n\n| ![Dynamic JSON Badge](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fgist.githubusercontent.com%2Fjeeftor%2Ff639b71257cceeb283a30cba77ee17c9%2Fraw%2Fintegration-status.json\u0026query=cpp.text\u0026label=cpp) | ![Dynamic JSON Badge](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fgist.githubusercontent.com%2Fjeeftor%2Ff639b71257cceeb283a30cba77ee17c9%2Fraw%2Fintegration-status.json\u0026query=csharp.text\u0026label=csharp) | ![Dynamic JSON Badge](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fgist.githubusercontent.com%2Fjeeftor%2Ff639b71257cceeb283a30cba77ee17c9%2Fraw%2Fintegration-status.json\u0026query=css.text\u0026label=css) | ![Dynamic JSON Badge](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fgist.githubusercontent.com%2Fjeeftor%2Ff639b71257cceeb283a30cba77ee17c9%2Fraw%2Fintegration-status.json\u0026query=go.text\u0026label=go) | ![Dynamic JSON Badge](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fgist.githubusercontent.com%2Fjeeftor%2Ff639b71257cceeb283a30cba77ee17c9%2Fraw%2Fintegration-status.json\u0026query=html.text\u0026label=html) |\n|----------|---------|---------|---------|---------|\n| ![Dynamic JSON Badge](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fgist.githubusercontent.com%2Fjeeftor%2Ff639b71257cceeb283a30cba77ee17c9%2Fraw%2Fintegration-status.json\u0026query=ini.text\u0026label=ini) | ![Dynamic JSON Badge](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fgist.githubusercontent.com%2Fjeeftor%2Ff639b71257cceeb283a30cba77ee17c9%2Fraw%2Fintegration-status.json\u0026query=java.text\u0026label=java) | ![Dynamic JSON Badge](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fgist.githubusercontent.com%2Fjeeftor%2Ff639b71257cceeb283a30cba77ee17c9%2Fraw%2Fintegration-status.json\u0026query=javascript.text\u0026label=javascript) | ![Dynamic JSON Badge](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fgist.githubusercontent.com%2Fjeeftor%2Ff639b71257cceeb283a30cba77ee17c9%2Fraw%2Fintegration-status.json\u0026query=kotlin.text\u0026label=kotlin) | ![Dynamic JSON Badge](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fgist.githubusercontent.com%2Fjeeftor%2Ff639b71257cceeb283a30cba77ee17c9%2Fraw%2Fintegration-status.json\u0026query=markdown.text\u0026label=markdown) |\n| ![Dynamic JSON Badge](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fgist.githubusercontent.com%2Fjeeftor%2Ff639b71257cceeb283a30cba77ee17c9%2Fraw%2Fintegration-status.json\u0026query=php.text\u0026label=php) | ![Dynamic JSON Badge](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fgist.githubusercontent.com%2Fjeeftor%2Ff639b71257cceeb283a30cba77ee17c9%2Fraw%2Fintegration-status.json\u0026query=python.text\u0026label=python) | ![Dynamic JSON Badge](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fgist.githubusercontent.com%2Fjeeftor%2Ff639b71257cceeb283a30cba77ee17c9%2Fraw%2Fintegration-status.json\u0026query=ruby.text\u0026label=ruby) | ![Dynamic JSON Badge](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fgist.githubusercontent.com%2Fjeeftor%2Ff639b71257cceeb283a30cba77ee17c9%2Fraw%2Fintegration-status.json\u0026query=rust.text\u0026label=rust) | ![Dynamic JSON Badge](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fgist.githubusercontent.com%2Fjeeftor%2Ff639b71257cceeb283a30cba77ee17c9%2Fraw%2Fintegration-status.json\u0026query=scala.text\u0026label=scala) |\n| ![Dynamic JSON Badge](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fgist.githubusercontent.com%2Fjeeftor%2Ff639b71257cceeb283a30cba77ee17c9%2Fraw%2Fintegration-status.json\u0026query=shell.text\u0026label=shell) | ![Dynamic JSON Badge](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fgist.githubusercontent.com%2Fjeeftor%2Ff639b71257cceeb283a30cba77ee17c9%2Fraw%2Fintegration-status.json\u0026query=swift.text\u0026label=swift) | ![Dynamic JSON Badge](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fgist.githubusercontent.com%2Fjeeftor%2Ff639b71257cceeb283a30cba77ee17c9%2Fraw%2Fintegration-status.json\u0026query=toml.text\u0026label=toml) | ![Dynamic JSON Badge](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fgist.githubusercontent.com%2Fjeeftor%2Ff639b71257cceeb283a30cba77ee17c9%2Fraw%2Fintegration-status.json\u0026query=typescript.text\u0026label=typescript) | ![Dynamic JSON Badge](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fgist.githubusercontent.com%2Fjeeftor%2Ff639b71257cceeb283a30cba77ee17c9%2Fraw%2Fintegration-status.json\u0026query=xml.text\u0026label=xml) |\n| ![Dynamic JSON Badge](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fgist.githubusercontent.com%2Fjeeftor%2Ff639b71257cceeb283a30cba77ee17c9%2Fraw%2Fintegration-status.json\u0026query=yaml.text\u0026label=yaml) |         |         |         |         |\n\n\n## Installation\n\nThe following details CLI based installation. License manager can also be used as a [docs/pre-commit.md](docs/pre-commit.md) hook.\n\n# License Manager\n\nA CLI tool for managing license headers in source code files. This tool helps you add, remove, update, and check license headers across your codebase with ease and precision. It utilizes non-printing Unicode character to mark the start \u0026 end of the License comment such that you can easier update or remove the license information.\n\n\n## Installation\n\nYou can install the License Manager through several methods:\n\n### Using Homebrew (macOS and Linux)\n\nThe easiest way to install on macOS and Linux is through Homebrew:\n\n```bash\n# Add the tap repository\nbrew tap jeeftor/tap\n\n# Install the package\nbrew install license-manager\n```\n\nTo upgrade to the latest version:\n```bash\nbrew upgrade license-manager\n```\n\n### Using Debian Package (Ubuntu/Debian)\n\nFor Debian-based Linux distributions, you can download and install the .deb package:\n\n```bash\n# Download the latest release\ncurl -LO \"https://github.com/jeeftor/license-manager/releases/latest/download/license-manager_$(curl -s https://api.github.com/repos/jeeftor/license-manager/releases/latest | grep tag_name | cut -d '\"' -f 4 | cut -c 2-)_linux_amd64.deb\"\n\n# Install the package\nsudo dpkg -i license-manager_*_linux_amd64.deb\n\n# Install dependencies if needed\nsudo apt-get install -f\n```\n\nYou can also download the .deb package directly from the [releases page](https://github.com/jeeftor/license-manager/releases).\n\n### Using Go\n\nIf you prefer to install using Go:\n\n```bash\ngo install github.com/jeeftor/license-manager/cmd/license-manager@latest\n```\n\n### From Source\n\nFor the latest development version:\n\n```bash\ngit clone https://github.com/jeeftor/license-manager.git\ncd license-manager\ngo build\n```\n## Usage\n\n### Basic Commands\n\nThe basic arguments required are to include 1 or more `--input`s to give a pattern of files to add licenses to and a `--license` file. Additionally you may want to include one or more `--skip` patterns to ensure you aren't adding licenses say to your `./vendor` directory.\n\nHere are some basic examples\n\n```bash\n# Add license headers to go and python files - ignoring a .venv directory\nlicense-manager add --license LICENSE.txt --input \"**/*.go\" --input \"**/*.py\" --skip \"./venv/**\"\n\n# Remove license headers\nlicense-manager remove --input \"**/*.go\" --input \"**/*.py\" --skip \"./vendor/**\" --skip \"./venv/**\"\n\n# Update existing license headers to use a new license and the swords style\nlicense-manager update --license NEW_LICENSE.txt --input \"**/*.go\" --style swords\n\n# Check license headers\nlicense-manager check --license LICENSE.txt --input \"**/*.go\"\n```\n\n### Commands\n\n| Command | Description |\n|---------|-------------|\n| add | Add license headers to files |\n| build-test-data | Generate test files for all supported languages |\n| check | Check license headers in files (this can also be used as a [pre-commit](./docs/pre-commit.md) hook)|\n| completion | Generate the autocompletion script for the specified shell |\n| debug | Debug license markers in files |\n| help | Help about any command |\n| pre-commit | Run license checks on specified files |\n| remove | Remove license headers from files |\n| styles | List available license header styles |\n| update | Update license headers in files |\n| version | Print version information |\n\n\n### Command Options\n\n- `--license` _string_      Path to license text file (required for add/update/check)\n- `--input` _strings_      Input file patterns (can be comma-separated or multiple flags)\n- `--skip` _strings_       Patterns to skip (can be comma-separated or multiple flags)\n- `--style` _string_       Preset style for header/footer (default \"hash\")\n- `--comments` _string_    Force comment style (no|single|multi)\n- `--log-level` _string_   Log level (debug|info|notice|warn|error) (default \"notice\")\n\n### Examples\n\n```bash\n# Add license headers to all Go files, excluding tests\nlicense-manager add --license LICENSE.txt --input \"**/*.go\" --skip \"**/*_test.go\"\n\n# Update license headers in Python files with confirmation\nlicense-manager update --license NEW_LICENSE.txt --input \"**/*.py\" --prompt\n\n# Check license headers in JavaScript files with detailed output\nlicense-manager check --license LICENSE.txt --input \"**/*.js\" --verbose\n\n# Remove license headers from C++ files in dry-run mode\nlicense-manager remove --input \"**/*.cpp\" --dry-run\n```\n\n## Configuration\n\n### Comment Styles\n\nThe tool automatically detects appropriate comment styles based on file extensions:\n- Go: `// comment`\n- Python: `# comment`\n- JavaScript/TypeScript: `// comment`\n- C/C++: `/* comment */`\n- And many more...\n\n### Header Styles\n\nChoose from various preset header/footer styles using the `--preset-style` flag:\n- `standard`: Simple comment block\n- `box`: Boxed comment style\n- `line`: Line-separated comments\n- And more...\n\n## Building from Source\n\nRequirements:\n- Go 1.19 or higher\n\n```bash\n# Clone the repository\ngit clone https://github.com/yourusername/license-manager.git\n\n# Change to project directory\ncd license-manager\n\n# Build the project\ngo build\n\n# Run tests\ngo test ./...\n\n# Install locally\ngo install\n```\n\n## Contributing\n\nContributions are welcome! Please feel free to submit a Pull Request. For major changes, please open an issue first to discuss what you would like to change.\n\n1. Fork the repository\n2. Create your feature branch (`git checkout -b feature/amazing-feature`)\n3. Commit your changes (`git commit -m 'Add some amazing feature'`)\n4. Push to the branch (`git push origin feature/amazing-feature`)\n5. Open a Pull Request\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n\n## Acknowledgments\n\n- Built with [Cobra](https://github.com/spf13/cobra) for CLI interface\n- Inspired by various license management tools in the open-source community\n\n## Support\n\nIf you encounter any issues or have questions, please file an issue on the GitHub repository.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjeeftor%2Flicense-manager","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjeeftor%2Flicense-manager","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjeeftor%2Flicense-manager/lists"}