{"id":20291155,"url":"https://github.com/nikitakozlovjr/file-manager","last_synced_at":"2026-06-29T05:31:37.482Z","repository":{"id":207733944,"uuid":"719955531","full_name":"nikitakozlovjr/File-Manager","owner":"nikitakozlovjr","description":"This file manager module provides functions for quickly working with files thanks to asynchronous work with them.","archived":false,"fork":false,"pushed_at":"2023-12-05T12:31:23.000Z","size":259,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-04T04:44:18.141Z","etag":null,"topics":["async-await","asynchronous-programming","fs","promise","readfile"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/nikitakozlovjr.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}},"created_at":"2023-11-17T09:06:38.000Z","updated_at":"2024-04-19T18:23:37.000Z","dependencies_parsed_at":"2025-01-14T09:11:35.207Z","dependency_job_id":"3ee18287-ac19-4978-aa5d-b4048a925d83","html_url":"https://github.com/nikitakozlovjr/File-Manager","commit_stats":null,"previous_names":["nikitakozlovjr/file-manager"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/nikitakozlovjr/File-Manager","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nikitakozlovjr%2FFile-Manager","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nikitakozlovjr%2FFile-Manager/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nikitakozlovjr%2FFile-Manager/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nikitakozlovjr%2FFile-Manager/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nikitakozlovjr","download_url":"https://codeload.github.com/nikitakozlovjr/File-Manager/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nikitakozlovjr%2FFile-Manager/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34915001,"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-29T02:00:05.398Z","response_time":58,"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":["async-await","asynchronous-programming","fs","promise","readfile"],"created_at":"2024-11-14T15:10:40.787Z","updated_at":"2026-06-29T05:31:37.459Z","avatar_url":"https://github.com/nikitakozlovjr.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![Maintainability](https://api.codeclimate.com/v1/badges/efad13b7a35cf21ab143/maintainability)](https://codeclimate.com/github/nikitakozlovjr/File-Manager/maintainability)\n\n# File-Manager\n### Description\n____\n\nThis file manager module provides functions for quickly working with files thanks to asynchronous work with them. The file manager includes the following features:\n- print \n- write \n- move\n- getDirectorySize\n- watch\n\nTo start working with this module, clone the repository `git clone` and run the command\n\n```\nmake install\nnpm link\n```\n\nPerhaps the npm link command may require the permission of the sudo administrator\n\n## Module getDirectorySize\n\n### Description\n\n___\n\nThis function calculates the size of the passed directory. The function only counts the size of files nested in it, without taking into account other directories nested in it.\n\n\n### Startup instructions\n___\n\nThe function **getDirectorySize** is an executable file, so to use it you just need to issue the following command and pass as an argument the relative path to the directory whose size you want to know\n\n```\ngetDirectorySize __fixtures__\n```\n\n### Example of work\n\n[![asciicast](https://asciinema.org/a/eX08BXJ3EjCY5YLGseUPG8dZV.svg)](https://asciinema.org/a/eX08BXJ3EjCY5YLGseUPG8dZV)\n\n## Module watch\n\n### Description\n\n___\n\nThis function monitors a file and tracks changes in it at a specified time interval. If changes occur, informs the user and calculates changes in file size\n\n\n### Startup instructions\n___\n\nThe function **watch** provides an executable file that takes three arguments in the specific sequence shown below. Accepted Arguments\n- path to the file\n- time interval of checks\n- observation operating time\n\n```\nwatch __fixtures__/file1.txt 500 10000\n```\n\n### Example of work\n\n[![asciicast](https://asciinema.org/a/fU0IKKB3Jk9oElv0cvqyuWirP.svg)](https://asciinema.org/a/fU0IKKB3Jk9oElv0cvqyuWirP)\n\n## Module print\n\n### Description\n\n___\n\nThis function asynchronously reads the transferred file and displays the contents of the file to the console.\n\n\n### Startup instructions\n___\n\nThe function **print** provides an executable file, which will take a single argument: path to file\n\n```\nprint __fixtures__/file2.txt \n```\n\n### Example of work\n\n[![asciicast](https://asciinema.org/a/PcoP4IEaPqzDGCyxnPVDwT4S1.svg)](https://asciinema.org/a/PcoP4IEaPqzDGCyxnPVDwT4S1)\n\n## Module move\n\n### Description\n\n___\n\n:warning: **Be careful when using this module**: This module can mutate the file system (delete a file)!\n\nThis function transfers data from the first transferred file to another file, and then deletes the first transferred file (from where the data is transferred)\n\n\n### Startup instructions\n___\n\nThe function **move** takes two input arguments in the form of relative paths to files\n- output file\n- input file\n\n```\nmove __fixtures__/file1.txt __fixtures__/file2.txt \n```\n\n### Example of work\n[![asciicast](https://asciinema.org/a/5zU8tC9DTRmKEvu2KTFIDquaz.svg)](https://asciinema.org/a/5zU8tC9DTRmKEvu2KTFIDquaz)\n\n## Module write\n\n### Description\n\n___\n\n:warning: **Be careful when using this module**: This module can mutate the file system (changing data or creating new files)!\n\nThis function writes the transferred data to a file. If the file does not exist, it is created with the files already transferred.\n\n\n### Startup instructions\n___\n\nThe function **write** takes two arguments as input in strict sequence\n- relative path to the file\n- data\n\n```\nwrite __fixtures__/file1.txt Hello, world!\n```\n\n### Example of work\n[![asciicast](https://asciinema.org/a/uoqa3uWCZeFdAcyumog30SHZ6.svg)](https://asciinema.org/a/uoqa3uWCZeFdAcyumog30SHZ6)\n\n## Module write\n\n### Description\n\n___\n\n:warning: **Be careful when using this module**: This module can mutate the file system (changing file data)!\n\nThis module reverses (rewrites in reverse order) the data of the transferred file\n\n\n### Startup instructions\n___\n\nThe function **reverse** takes one single argument\n- relative path to the file\n\n```\nreverse __fixtures__/file2.txt\n```\n\n### Example of work\n[![asciicast](https://asciinema.org/a/HtI1UKqeQkk33L027rTN8Lwgz.svg)](https://asciinema.org/a/HtI1UKqeQkk33L027rTN8Lwgz)\n\n## Module build\n\n### Description\n\n___\n\n:warning: **Be careful when using this module**: This module can mutate the file system (add new files)!\n\nThis module checks if a file has been created and if it has not been created, creates it. The module returns \"Succes!\" anyway, even if the file is created\n\n\n### Startup instructions\n___\n\nThe function **build** takes one single argument\n- relative path to the file\n\n```\nbuild __fixtures__/file1.txt\n```\n\n### Example of work\n[![asciicast](https://asciinema.org/a/ThQ5lIhDDMh1IXB50ZmBZE0bg.svg)](https://asciinema.org/a/ThQ5lIhDDMh1IXB50ZmBZE0bg)\n\n## Module getTypes\n\n### Description\n\n___\n\nThis software module returns an array of types of passed paths. If the path is incorrect or non-existent, the function returns null.\n\n\n### Startup instructions\n___\n\nThis module **getTypes** accepts an unlimited number of paths separated by a space as input\n- ... relative path to the file\n\n```\ngetTypes __fixtures__/file1.txt _fixtures__/file2.txt __fixtures__/file3.txt\n```\n\n### Example of work\n[![asciicast](https://asciinema.org/a/gtvAUfNBzgxGenrjbrnIsxsob.svg)](https://asciinema.org/a/gtvAUfNBzgxGenrjbrnIsxsob)\n\n## Module compareFilesSizes\n\n### Description\n\n___\n\nThis module compares the sizes of the transferred files and outputs the path to the file with the largest size to the console.\n\n\n### Startup instructions\n___\n\nThis module **compareFilesSizes** accepts an unlimited number of file paths. If a directory has been passed, it is ignored.  \n- ... relative path to the file\n\n```\ncompareFilesSizes __fixtures__/file1.txt _fixtures__/file2.txt __fixtures__/file3.txt\n```\n\n### Example of work\n[![asciicast](https://asciinema.org/a/0Ai1lefFTpQW3DeMrIss3uIBX.svg)](https://asciinema.org/a/0Ai1lefFTpQW3DeMrIss3uIBX)\n\n## Module exchange\n\n### Description\n\n___\n\nThis module compares the sizes of the transferred files and outputs the path to the file with the largest size to the console.\n\n\n### Startup instructions\n___\n\nThis module **compareFilesSizes** accepts an unlimited number of file paths. If a directory has been passed, it is ignored.  \n- ... relative path to the file\n\n```\ncompareFilesSizes __fixtures__/file1.txt _fixtures__/file2.txt __fixtures__/file3.txt\n```\n\n### Example of work\n[![asciicast](https://asciinema.org/a/HUp3HFfb3XZWbE2E9ZK5sYFaz.svg)](https://asciinema.org/a/HUp3HFfb3XZWbE2E9ZK5sYFaz)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnikitakozlovjr%2Ffile-manager","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnikitakozlovjr%2Ffile-manager","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnikitakozlovjr%2Ffile-manager/lists"}