File tree Expand file tree Collapse file tree 1 file changed +34
-0
lines changed Expand file tree Collapse file tree 1 file changed +34
-0
lines changed Original file line number Diff line number Diff line change
1
+ # date
2
+
3
+ Use ` date ` to get the current date and time. Defaults to local timezone but you can get it in UTC too.
4
+
5
+ ## Flags
6
+
7
+ --utc
8
+ Returns the current date and time in UTC
9
+
10
+ --local
11
+ Returns the current date and time in your local timezone
12
+
13
+ ## Examples
14
+
15
+ ``` shell
16
+ > date
17
+ ━━━━━━┯━━━━━━━┯━━━━━┯━━━━━━┯━━━━━━━━┯━━━━━━━━┯━━━━━━━━━━
18
+ year │ month │ day │ hour │ minute │ second │ timezone
19
+ ──────┼───────┼─────┼──────┼────────┼────────┼──────────
20
+ 2019 │ 9 │ 30 │ 21 │ 52 │ 30 │ -03:00
21
+ ━━━━━━┷━━━━━━━┷━━━━━┷━━━━━━┷━━━━━━━━┷━━━━━━━━┷━━━━━━━━━━
22
+ > date --utc
23
+ ━━━━━━┯━━━━━━━┯━━━━━┯━━━━━━┯━━━━━━━━┯━━━━━━━━┯━━━━━━━━━━
24
+ year │ month │ day │ hour │ minute │ second │ timezone
25
+ ──────┼───────┼─────┼──────┼────────┼────────┼──────────
26
+ 2019 │ 10 │ 1 │ 0 │ 52 │ 32 │ UTC
27
+ ━━━━━━┷━━━━━━━┷━━━━━┷━━━━━━┷━━━━━━━━┷━━━━━━━━┷━━━━━━━━━━
28
+ > date --local
29
+ ━━━━━━┯━━━━━━━┯━━━━━┯━━━━━━┯━━━━━━━━┯━━━━━━━━┯━━━━━━━━━━
30
+ year │ month │ day │ hour │ minute │ second │ timezone
31
+ ──────┼───────┼─────┼──────┼────────┼────────┼──────────
32
+ 2019 │ 9 │ 30 │ 21 │ 52 │ 34 │ -03:00
33
+ ━━━━━━┷━━━━━━━┷━━━━━┷━━━━━━┷━━━━━━━━┷━━━━━━━━┷━━━━━━━━━━
34
+ ```
You can’t perform that action at this time.
0 commit comments