my-timezone

command
v0.0.0-...-09cc700 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 25, 2023 License: GPL-3.0, GPL-3.0 Imports: 9 Imported by: 0

README

my-timezone Build Status Dependabot Status

Calculate the exact time based on your location.

Installation

Run go get github.com/ffflorian/go-tools/my-timezone.

Usage

Calculate the exact time based on your location.

For the `location` argument you can either use coordinates (e.g. 52.5502,13.4304)
or a city name (e.g. "Berlin, Germany").

Usage:
  my-timezone [options] [location]

Options:
  --server, -s       set the NTP server (default is "pool.ntp.org")
  --timeout, -t      set a custom timeout for HTTP requests (default is 2000ms)
  --version, -v      output the version number
  --help, -h         output usage information
  --offline, -o      enable offline mode (disables city matching)
  --debug, -d        enable debug mode

Hint: You can also enable the debug mode by setting the environment variable DEBUG to "my-timezone".

Example:

DEBUG="my-timezone" my-timezone

### Example

$ my-timezone 52.550215,13.430428 -o # Berlin, Germany Your personal time in "52.550215,13.430428": 21:24:49

$ my-timezone "Marburg, Germany" Your personal time in "Marburg, Germany": 21:06:57

Test

go test

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL