{"id":22960264,"url":"https://github.com/stringmanolo/js","last_synced_at":"2025-04-02T02:43:19.997Z","repository":{"id":57204019,"uuid":"437420746","full_name":"StringManolo/js","owner":"StringManolo","description":"Run javascript in Linux/Termux terminal using node as engine","archived":false,"fork":false,"pushed_at":"2021-12-12T01:27:14.000Z","size":3,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-11T16:42:09.412Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/StringManolo.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}},"created_at":"2021-12-12T00:41:31.000Z","updated_at":"2021-12-12T01:27:17.000Z","dependencies_parsed_at":"2022-09-17T18:53:26.410Z","dependency_job_id":null,"html_url":"https://github.com/StringManolo/js","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/StringManolo%2Fjs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/StringManolo%2Fjs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/StringManolo%2Fjs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/StringManolo%2Fjs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/StringManolo","download_url":"https://codeload.github.com/StringManolo/js/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246746879,"owners_count":20827061,"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-12-14T18:31:56.049Z","updated_at":"2025-04-02T02:43:19.970Z","avatar_url":"https://github.com/StringManolo.png","language":"JavaScript","readme":"# js\n\nJs is a command utility to run javascript as a command in a simple way.\n\n### Use cases\n\n- Run javascript in the fastest way posible preserving your code in the history.\n- Empower your shell scripting and trasladate your javascript knowledge to the shell.\n- Parse strings, use regexp, split, replace... using the same code everywhere.\n\n### Features\n\n- A pipedStdin global that holds piped input if provided from command line.\n- A run global function that allows you to run commands also inside your javascript code.\n- A loadFile function to load files in memory.\n- Small and portable. 80 lines of code and should work anywhere.\n- Only native node modules used, so you don't depend on versions and installs.\n\n### Examples\n\nRun javascript: ```js 'console.log(\"Hello world\")'```\n\nWork with piped streams: ```date | js 'console.log(pipedStdin.split(\" \")[3])'```\n\nFetch a remote resource and return the number of words ```js 'console.log(run(\"curl --silent http://example.com\"))' | wc -w```\n\n### Install\n\nnpm install --global command-javascript\n\n### Alternative Install\n\ncurl https://github.com/StringManolo/js/blob/c01e68feaaef521304fc7b5d073aec209243a311/bin/js -L \u003e /usr/bin/js \n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstringmanolo%2Fjs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstringmanolo%2Fjs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstringmanolo%2Fjs/lists"}