{"id":25610792,"url":"https://github.com/jschuur/localtime-cli","last_synced_at":"2026-06-20T19:32:00.066Z","repository":{"id":65770517,"uuid":"598729135","full_name":"jschuur/localtime-cli","owner":"jschuur","description":"Command-line tool to look up the local time (and weather) for time zones, countries and cities with auto-completion.","archived":false,"fork":false,"pushed_at":"2023-02-13T06:40:18.000Z","size":480,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-03-12T04:50:18.326Z","etag":null,"topics":["cli","command-line","localtime","openweather","time","timezones","weather"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/localtime-cli","language":"TypeScript","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/jschuur.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-02-07T17:38:53.000Z","updated_at":"2023-02-18T07:34:49.000Z","dependencies_parsed_at":"2023-04-27T12:01:27.325Z","dependency_job_id":null,"html_url":"https://github.com/jschuur/localtime-cli","commit_stats":{"total_commits":16,"total_committers":1,"mean_commits":16.0,"dds":0.0,"last_synced_commit":"e110f8ce15d031bf62f833655c9e05e9c6684a46"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/jschuur/localtime-cli","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jschuur%2Flocaltime-cli","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jschuur%2Flocaltime-cli/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jschuur%2Flocaltime-cli/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jschuur%2Flocaltime-cli/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jschuur","download_url":"https://codeload.github.com/jschuur/localtime-cli/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jschuur%2Flocaltime-cli/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34583589,"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-20T02:00:06.407Z","response_time":98,"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":["cli","command-line","localtime","openweather","time","timezones","weather"],"created_at":"2025-02-21T22:36:25.273Z","updated_at":"2026-06-20T19:32:00.049Z","avatar_url":"https://github.com/jschuur.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Local time and weather command line tool\n\nCommand-line tool to look up the local time (and weather) for time zones, countries and cities with auto-completion.\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://github.com/jschuur/localtime-cli/blob/main/localtime.gif?raw=true\" alt=\"Animated GIF of localtime shell CLI, showing the city of London being typed in and picked from a list, then local time and weather results appear.\"\u003e\n\u003c/p\u003e\n\nMy partner (:heart: :frog:) was out of town, and I wanted a quick way to see her local time and weather. Fun little project to start using TypeScript too.\n\n## Usage\n\nInstall as a global `localtime` command:\n\n```\nnpm install -g localtime-cli\n```\n\nOr run ad hoc:\n\n```\nnpx localtime-cli\n```\n\n### Options\n\nShow full options with `localtime --help`\n\n- `-t` `--timezone` use timezone names for search (default: true)\n- `--no-timezone` don't use timezone names\n- `-c` `--country` use [country names](https://github.com/manuelmhtr/countries-and-timezones)\n- `-y` `--city` use [city names](https://github.com/kevinroberts/city-timezones) with a population \u003e= 250,000\n- `-Y` `--city-all` use all city names\n- `-a` `--all-min`, use all location types (with minimum city population)\n- `-A` `--all` use all location types (no city population minimum)\n- `-w` `--weather` include local weather\n- `-o` `--openweather-api-key \u003ckey\u003e` specify OpenWeather API key\n- `-O` `--save-openweather-api-key \u003ckey\u003e` specify and save OpenWeather API key for future use\n- `-l` `--last` bypass location search and reuse last location used\n- `-C` `--metric`, use metric units (celsius)\n- `-F` `--imperial`, use imperial units (fahrenheit)\n\nThus `localtime -c -y` would search time zone, country and larger city names and `localtime --no-timezone -Y` would search just through all city names, since time zones are always used unless explicitly excluded.\n\nMultiple single letter options [can be combined](https://www.npmjs.com/package/commander#common-option-types-boolean-and-value) too: `localtime -cy`.\n\nThe last previously used location will be sorted to the top of the list unless `--skip-last-used-sort` is used.\n\n#### Weather\n\nWeather info works for city selections and requires a [free OpenWeather API key](https://openweathermap.org/api) provided via the `-o` option to use it once or `-O` to save it for future use without needing to provide it as an option again.\n\nExample:\n\n```\nlocaltime -y -w -O abc123\n```\n\nIn subsequent uses, you can then just run `localtime -y -w`.\n\nYou can also set it via the `OPENWEATHER_API_KEY` environment variable.\n\nInitially, the metric system will be used and weather temperatures will be in celsius. Subsequent invocations will reuse the previously specified unit of measurement, unless a new one is selected via command line options.\n\n\\- [Joost Schuur](https://joostschuur.com) ([@joostschuur](https://twitter.com/joostschuur))\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjschuur%2Flocaltime-cli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjschuur%2Flocaltime-cli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjschuur%2Flocaltime-cli/lists"}