{"id":23119025,"url":"https://github.com/tusharad/grep-haskell","last_synced_at":"2025-07-23T22:37:31.783Z","repository":{"id":229683287,"uuid":"777366008","full_name":"tusharad/grep-haskell","owner":"tusharad","description":"Haskell implementation of grep.","archived":false,"fork":false,"pushed_at":"2024-05-02T07:39:45.000Z","size":2320,"stargazers_count":5,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-05-07T01:42:49.173Z","etag":null,"topics":["grep","haskell"],"latest_commit_sha":null,"homepage":"","language":"Haskell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-2-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tusharad.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","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-03-25T18:04:29.000Z","updated_at":"2025-04-10T06:35:26.000Z","dependencies_parsed_at":"2024-12-17T05:31:21.446Z","dependency_job_id":null,"html_url":"https://github.com/tusharad/grep-haskell","commit_stats":null,"previous_names":["tusharad/grep-haskell"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/tusharad/grep-haskell","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tusharad%2Fgrep-haskell","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tusharad%2Fgrep-haskell/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tusharad%2Fgrep-haskell/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tusharad%2Fgrep-haskell/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tusharad","download_url":"https://codeload.github.com/tusharad/grep-haskell/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tusharad%2Fgrep-haskell/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":266761417,"owners_count":23980296,"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","status":"online","status_checked_at":"2025-07-23T02:00:09.312Z","response_time":66,"last_error":null,"robots_txt_status":null,"robots_txt_updated_at":null,"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":["grep","haskell"],"created_at":"2024-12-17T05:31:11.578Z","updated_at":"2025-07-23T22:37:31.754Z","avatar_url":"https://github.com/tusharad.png","language":"Haskell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# grep-haskell\n\n`grep-haskell` is an implementation of the classic `grep` utility, entirely in Haskell. This project aims to replicate the functionality and performance of traditional `grep`, leveraging Haskell's powerful pattern matching and concurrency features to provide a fast and efficient text search utility.\n\n## Features\n\n- **File and Directory Recursion**: Search through files and directories recursively, with options to include or exclude specific file types.\n- **Context Control**: Display surrounding lines of content around matches for better context, with customizable lines before and after matches.\n- **Performance**: Optimized for speed, aiming to match or come close to the performance of GNU grep by leveraging Haskell's concurrency and efficient text processing capabilities.\n- **Color Highlighting**: See your matches highlighted in the terminal for easier scanning.\n- **Multiple File Handling**: Search through multiple files or standard input, with clear indications of where matches are found.\n- **Customizable Output**: Options to show only filenames, count of matches, line numbers, and more, for flexible output tailored to your needs.\n\n## Installation\n\nTo install `grep-haskell`, ensure you have the Haskell Stack tool installed on your system. Follow these steps:\n\n1. Clone the repository:\n   ```bash\n   git clone https://github.com/yourusername/grep-haskell.git\n   cd grep-haskell\n   ```\n\n2. Build the project using Stack:\n   ```bash\n   cabal build\n   ```\n\n3. Run your local binary path:\n   ```bash\n   cabal exec my-grep\n   ```\n\n## Usage\n\nBasic usage of `grep-haskell` follows the familiar `grep` syntax, with additional options for its unique features:\n\n```bash\ngrep-haskell [OPTIONS] PATTERN [FILE...]\n```\n\n### Options\n\n- `-i`, `--ignore-case`: Ignore case distinctions in both the pattern and the input files.\n- `-n`, `--line-number`: Prefix each line of output with the line number within its input file.\n\n### Examples\n\nSearch for the word \"Hello Haskell\" in all files in the directory \"./haskell\" and subdirectories:\n\n```bash\n./my-grep \"Hello Haskell\" ./haskell/ -n\n```\n\n\n## Contributing\n\nContributions to `grep-haskell` are welcome! Whether it's bug reports, feature requests, or pull requests, all forms of contributions help make `grep-haskell` better. Please follow the standard GitHub fork \u0026 pull request workflow.\n\n---\n\nThis README is just a starting point. As `grep-haskell` grows and evolves, be sure to update documentation to reflect new features and changes.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftusharad%2Fgrep-haskell","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftusharad%2Fgrep-haskell","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftusharad%2Fgrep-haskell/lists"}