{"id":13547363,"url":"https://github.com/nojvek/matrix-rain","last_synced_at":"2025-04-04T10:03:55.401Z","repository":{"id":46188139,"uuid":"48559322","full_name":"nojvek/matrix-rain","owner":"nojvek","description":" The famous Matrix rain effect of falling green characters in a terminal","archived":false,"fork":false,"pushed_at":"2023-07-21T01:33:53.000Z","size":194,"stargazers_count":444,"open_issues_count":2,"forks_count":38,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-03-28T09:07:00.434Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/nojvek.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}},"created_at":"2015-12-24T23:26:23.000Z","updated_at":"2025-03-17T17:45:43.000Z","dependencies_parsed_at":"2022-09-26T18:31:41.852Z","dependency_job_id":"9ea6582d-8fa9-4d92-b9a9-a84fa1956059","html_url":"https://github.com/nojvek/matrix-rain","commit_stats":{"total_commits":39,"total_committers":6,"mean_commits":6.5,"dds":0.4358974358974359,"last_synced_commit":"ac723ddf4ea22adafb11be2619c4ca789f3afec1"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nojvek%2Fmatrix-rain","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nojvek%2Fmatrix-rain/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nojvek%2Fmatrix-rain/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nojvek%2Fmatrix-rain/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nojvek","download_url":"https://codeload.github.com/nojvek/matrix-rain/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247157275,"owners_count":20893219,"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":"2024-08-01T12:00:54.601Z","updated_at":"2025-04-04T10:03:55.367Z","avatar_url":"https://github.com/nojvek.png","language":"JavaScript","funding_links":[],"categories":["🚀 A series of exquisite and compact web page cool effects"],"sub_categories":["Rain \u0026 Snow"],"readme":"# Matrix Rain\n\nThe famous Matrix rain effect of falling green characters in a terminal with node.\n\n## Installation\n\n```\nnpm install -g matrix-rain\n```\n\n## Usage\n\n```\nusage: matrix-rain [-h] [-v] [-d {h,v}]\n                [-c {green,red,blue,yellow,magenta,cyan,white}]\n                [-k {ascii,binary,braille,emoji,katakana}] [-f FILEPATH]\n\n\nThe famous Matrix rain effect of falling green characters as a cli command\n\nOptional arguments:\n  -h, --help            Show this help message and exit.\n  -d, --direction {h,v}\n                        Change direction of rain. h=horizontal, v=vertical\n  -c , --color {green,red,blue,yellow,magenta,cyan,white}\n                        Rain color. NOTE: droplet start is always white\n  -k, --char-range {ascii,binary,braille,emoji,katakana,picto}\n                        Use rain characters from char-range\n  -f, --file-path FILEPATH\n                        Read characters from a file instead of random\n                        characters from char-range\n```\n## Screenshots\n\n![Vertical Matrix](https://media.giphy.com/media/NA5S7F2dikADu/giphy.gif)\n\n![Horizontal Matrix](https://media.giphy.com/media/uSV1MnXz3RM3u/giphy.gif)\n\n## Story Time\nOn 2016 christmas eve, I watched the The Matrix (1999) and was inspired by the matrix rain effect. I was curious to see if I could replicate this effect in nodejs.\n\nThere's [blessed](https://github.com/chjj/blessed) and [node-ncurses](https://github.com/mscdex/node-ncurses) which would have helped but rather than using the library I wanted to learn how console cursor manipulation works behind the scenes. I browsed through the source code of [colors.js](https://github.com/marak/colors.js/) and got a few pointers. On that day I discovered terminal escape codes [VT100 ANSI codes table](http://ascii-table.com/ansi-escape-sequences-vt-100.php). There is also the comprehensive xterm control sequences documentation [ctlseqs](https://invisible-island.net/xterm/ctlseqs/ctlseqs.html).\n\nNode's process.stdout has a columns and rows property. It also fires resize events like the browser. With escape codes I can treat the terminal as a canvas and paint on it. I discovered a new medium to show my art.\n\nIn general its very possible to build interactive terminal apps with great UX that are lightweight and blazing fast. I'm on that journey.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnojvek%2Fmatrix-rain","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnojvek%2Fmatrix-rain","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnojvek%2Fmatrix-rain/lists"}