aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/gleam/os.gleam6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/gleam/os.gleam b/src/gleam/os.gleam
index 0c3f38a..0623dd5 100644
--- a/src/gleam/os.gleam
+++ b/src/gleam/os.gleam
@@ -58,3 +58,9 @@ pub type TimeUnit {
/// https://erlang.org/doc/apps/erts/time_correction.html#OS_System_Time
pub external fn system_time(TimeUnit) -> Int =
"os" "system_time"
+
+/// Return the current OS system time as a tuple of Ints
+///
+/// http://erlang.org/doc/man/os.html#timestamp-0
+pub external fn erlang_timestamp() -> tuple(Int, Int, Int) =
+ "os" "timestamp"