{"id":21459888,"url":"https://github.com/hunam6/get_next_line","last_synced_at":"2025-03-17T04:34:41.511Z","repository":{"id":136131010,"uuid":"577690378","full_name":"Hunam6/get_next_line","owner":"Hunam6","description":"Indispensable utility to read a file - Hive Helsinki (42 school)","archived":false,"fork":false,"pushed_at":"2023-03-23T15:19:28.000Z","size":6,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-01-23T14:17:04.177Z","etag":null,"topics":["42","42projects","get-next-line","getnextline","hive","hivehelsinki"],"latest_commit_sha":null,"homepage":"","language":"C","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/Hunam6.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":"2022-12-13T10:00:23.000Z","updated_at":"2023-03-23T14:56:47.000Z","dependencies_parsed_at":null,"dependency_job_id":"0a9f05c0-33c6-492d-a3d5-cd9ed8a04bca","html_url":"https://github.com/Hunam6/get_next_line","commit_stats":null,"previous_names":["hunam6/get_next_line"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hunam6%2Fget_next_line","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hunam6%2Fget_next_line/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hunam6%2Fget_next_line/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hunam6%2Fget_next_line/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Hunam6","download_url":"https://codeload.github.com/Hunam6/get_next_line/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":235293314,"owners_count":18966552,"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":["42","42projects","get-next-line","getnextline","hive","hivehelsinki"],"created_at":"2024-11-23T06:36:56.412Z","updated_at":"2025-01-23T14:17:09.083Z","avatar_url":"https://github.com/Hunam6.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n  \u003ch1\u003eget_next_line\u003c/h1\u003e\n  \u003cb\u003eIndispensable utility to read a file\u003c/b\u003e\n\u003c/div\u003e\n\n## 🛠️ Installation\n\nCompile your project with `get_next_line.c` and `get_next_line_utils.c`.\nInclude `get_next_line.h` in your file.\n\n## 📚 Usage\n\n```c\n#include \u003cstdio.h\u003e\n#include \u003cfcntl.h\u003e\n#include \"get_next_line.h\"\n\nint main(int ac, char **av)\n{\n\tint fd;\n\tif (ac != 2)\n\t\treturn(printf(\"Usage: ./gnl \u003cfile\u003e\\n\"));\n\tif ((fd = open(av[1], O_RDONLY)) == -1)\n\t\treturn (printf(\"Failed to open the file.\\n\"));\n\twhile (42)\n\t{\n\t\tchar *line = get_next_line(fd);\n\t\tif (!line)\n\t\t\tbreak;\n\t\tprintf(\"%s\", line);\n\t}\n\tif (close(fd) == -1)\n\t\treturn (printf(\"Failed to close the file.\\n\"));\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhunam6%2Fget_next_line","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhunam6%2Fget_next_line","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhunam6%2Fget_next_line/lists"}