{"id":22930875,"url":"https://github.com/zewebdev1337/locc","last_synced_at":"2026-06-20T16:32:18.332Z","repository":{"id":258473845,"uuid":"873992415","full_name":"zewebdev1337/locc","owner":"zewebdev1337","description":"A lines of code counter","archived":false,"fork":false,"pushed_at":"2024-10-17T06:57:50.000Z","size":16,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-10-23T20:51:11.261Z","etag":null,"topics":["developer-tools","gloc","lines-of-code","utility"],"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/zewebdev1337.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":"2024-10-17T04:28:06.000Z","updated_at":"2024-10-17T06:57:53.000Z","dependencies_parsed_at":"2024-10-19T06:56:43.663Z","dependency_job_id":"fe2d89ff-7028-4405-9905-d9dd4ed739d8","html_url":"https://github.com/zewebdev1337/locc","commit_stats":null,"previous_names":["zewebdev1337/locc"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/zewebdev1337/locc","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zewebdev1337%2Flocc","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zewebdev1337%2Flocc/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zewebdev1337%2Flocc/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zewebdev1337%2Flocc/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/zewebdev1337","download_url":"https://codeload.github.com/zewebdev1337/locc/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zewebdev1337%2Flocc/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34578089,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-20T02:00:06.407Z","response_time":98,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["developer-tools","gloc","lines-of-code","utility"],"created_at":"2024-12-14T10:30:30.403Z","updated_at":"2026-06-20T16:32:18.302Z","avatar_url":"https://github.com/zewebdev1337.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# locc\n\n## WARNING\n\nThis is basically a stripped down version of [promptify](https://github.com/zewebdev1337/promptify) and as such, it contains the same buggy behavior in merging configs and excluding directories (I'm looking at you `node_modules`), might fix later, hopefully.\n\n## Description\nlocc (Lines of Code Counter) is a command-line tool designed to traverse subdirectories in the current working directory, identifying code files to calculate and present non-empty line counts.\n\nThe tool incorporates a configuration system that merges global settings located at `~/.locc.yaml` with local project-level configurations, which default to `.locc.yaml` within the current directory. This local configuration file path can be customized using the provided command-line flags during execution.\n\n## Features\n\n- Determination of programming languages based on file extensions.\n- Implementation of file and directory inclusion/exclusion rules.\n- Definition of a maximum file size limit for processing.\n- Generation of verbose output detailing individual file analysis.\n\n## Usage\n\n```\nlocc [flags]\n```\n\n## Flags\n\n```\n  -c, --config string      Path to the local configuration file (Not required if your config file is `./.locc.yaml`).\n      --data               Enable processing of data store files (e.g., JSON, YAML).\n      --docs               Enable processing of document files (e.g., plain text, Markdown).\n  -h, --help               Display help information.\n      --init               Generate a local configuration file template.\n  -o, --output string      Output the results to the specified file name.\n  -v, --verbose            Enable verbose output for detailed file information.\n```\n\n## Configuration\n\nThe configuration file adheres to the YAML format and supports the following parameters:\n\n- **languages**: This section defines a mapping of language-specific settings, encompassing file extensions associated with each language and their corresponding single-line and multi-line comment syntax.\n- **stores**: Similar to the 'languages' section, this defines configurations for data storage files.\n- **documents**: Analogous to the 'languages' and 'stores' sections, this configures settings related to document files.\n- **excludes**: This section enables the specification of files or directories to be excluded from line counting. These exclusions can be defined globally or on a per-language basis.\n- **max_file_size**: This parameter sets a limit, expressed in bytes, on the size of files considered for processing. Files exceeding this threshold are disregarded.\n\n\n## Examples\n\n```\n# Analyze the current directory with default settings\nlocc\n\n# Analyze the current directory using a specific configuration file\nlocc --config myconfig.yaml\n\n# Analyze the current directory and include data store files\nlocc --data\n\n# Analyze the current directory, enable verbose output, and write the results to a file\nlocc --verbose --output results.txt\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzewebdev1337%2Flocc","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzewebdev1337%2Flocc","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzewebdev1337%2Flocc/lists"}