Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/zuraguerra/beat_time
Utilities to work with Swatch Internet Time (.beat time).
https://github.com/zuraguerra/beat_time
beat-time elixir erlang swatch-internet-time time
Last synced: 2 months ago
JSON representation
Utilities to work with Swatch Internet Time (.beat time).
- Host: GitHub
- URL: https://github.com/zuraguerra/beat_time
- Owner: ZuraGuerra
- Created: 2019-06-13T18:34:51.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2022-09-14T15:18:13.000Z (over 2 years ago)
- Last Synced: 2024-09-14T05:57:55.254Z (4 months ago)
- Topics: beat-time, elixir, erlang, swatch-internet-time, time
- Language: Elixir
- Homepage:
- Size: 8.79 KB
- Stars: 10
- Watchers: 2
- Forks: 4
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# .beat Time
[![Hex version](https://img.shields.io/hexpm/v/beat_time.svg)](https://hex.pm/packages/beat_time)
[![Hex license](https://img.shields.io/hexpm/l/beat_time.svg)](https://hex.pm/packages/beat_time)Utilities to work with [Swatch Internet Time](https://en.wikipedia.org/wiki/Swatch_Internet_Time) (.beat time).
* Every day has 1000.beats.
* Every .beat has 86_400 milliseconds.
* There's no notion of time zones: it's an universal time system based on UTC+01.## Installation
```elixir
def deps do
[
{:beat_time, "~> 1.0.0"}
]
end
```## Usage
```elixir
iex> BeatTime.now()
%BeatTime{value: 300}iex> BeatTime.now() |> BeatTime.format()
"@300"
```