{"id":27942070,"url":"https://github.com/secretdeveloperisme/find_text","last_synced_at":"2025-05-07T11:26:14.308Z","repository":{"id":170478816,"uuid":"646620311","full_name":"secretdeveloperisme/find_text","owner":"secretdeveloperisme","description":"Find path and content of file that matches by specifying the keywords","archived":false,"fork":false,"pushed_at":"2023-06-03T04:31:50.000Z","size":15,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-05-06T16:04:25.983Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/secretdeveloperisme.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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,"zenodo":null}},"created_at":"2023-05-29T00:38:43.000Z","updated_at":"2023-05-29T00:41:43.000Z","dependencies_parsed_at":null,"dependency_job_id":"3efb3de9-fe0f-42f7-bf0e-85795c546800","html_url":"https://github.com/secretdeveloperisme/find_text","commit_stats":null,"previous_names":["secretdeveloperisme/find_text","linhplus/find_text"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/secretdeveloperisme%2Ffind_text","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/secretdeveloperisme%2Ffind_text/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/secretdeveloperisme%2Ffind_text/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/secretdeveloperisme%2Ffind_text/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/secretdeveloperisme","download_url":"https://codeload.github.com/secretdeveloperisme/find_text/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252867460,"owners_count":21816681,"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-05-07T11:26:13.496Z","updated_at":"2025-05-07T11:26:14.286Z","avatar_url":"https://github.com/secretdeveloperisme.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# find_text\nFind path and content of file that matches by specifying the keywords\n```bash\nλ find_string_in_files.exe --help\nUsage: find_string_in_files.exe [OPTIONS] --path \u003cPath to input folder or file\u003e --keywords \u003cList of keywords separated by [, ; |]\u003e\n\nOptions:\n  -p, --path \u003cPath to input folder or file\u003e\n  -k, --keywords \u003cList of keywords separated by [, ; |]\u003e\n  -o, --output \u003coutput file\u003e\n  -d, --previous-days \u003cNumber of Previous days\u003e\n  -l, --number-lines \u003cNumber of Lines\u003e\n  -h, --help Print help (see a summary with '-h')\n  -V, --version Print version\n```\n\n## Example \n\n```bash \nfind_string_in_files.exe --path D:\\target_folder\\ --keywords \"hoanglinh|hl\"  --previous-days 1 --number-lines 2\n```\n\u003e *The command will search on target folder with the key words **hoanglinh** or **hl**, the files must has modified date from **yesterday** to now and the line that match the keywords and next line will be write to the output file.*\\\n\u003e ***Note**: if the output file argument was not provided, the result will write to the file with name output.out and it's location is current working directory*.\n\n## Output file example \n```bash\nFileName: D:\\target\\abc.txt\nModified: 2023-05-05/30/23 00:08:58\n{5}:  use std::{io::{self, BufReader, BufRead}, path::{Path, PathBuf}, error::Error, fs::{File, self}};\n{6}:  use crate::{command_parser::Args, output_result::OutputResult, utils::compare_time};\n{9}:  pub fn find_error_file(args: Args)-\u003eResult\u003c(), Box\u003cdyn Error\u003e\u003e{\n{10}:    if !(args.get_path().is_dir() || args.get_path().is_file()) {\n{11}:      return Err(io::Error::new(io::ErrorKind::NotFound, \"Path is not valid\").into());\n{12}:    }\n{68}:              output_results_hoanglinh.push(out_result);\n{69}:          }\n{76}: hoanglinh #[test]\n{77}:  fn test_call_call(){\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsecretdeveloperisme%2Ffind_text","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsecretdeveloperisme%2Ffind_text","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsecretdeveloperisme%2Ffind_text/lists"}