Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
adam.huang
Ohmyzsh
Commits
244a6f23
Commit
244a6f23
authored
Aug 31, 2014
by
Robby Russell
Browse files
Merge pull request #3011 from cherrry/master
rounding to emoji clock
parents
58491bda
99e74b04
Changes
1
Hide whitespace changes
Inline
Side-by-side
plugins/emoji-clock/emoji-clock.plugin.zsh
View file @
244a6f23
...
@@ -8,8 +8,8 @@
...
@@ -8,8 +8,8 @@
# -----------------------------------------------------------------------------
# -----------------------------------------------------------------------------
function
emoji-clock
()
{
function
emoji-clock
()
{
hour
=
$(
date
'+%I'
)
hour
=
$(
date
-v
'+15M'
'+%I'
)
minutes
=
$(
date
'+%M'
)
minutes
=
$(
date
-v
'+15M'
'+%M'
)
case
$hour
in
case
$hour
in
01
)
clock
=
"🕐"
;
[
$minutes
-ge
30
]
&&
clock
=
"🕜"
;;
01
)
clock
=
"🕐"
;
[
$minutes
-ge
30
]
&&
clock
=
"🕜"
;;
02
)
clock
=
"🕑"
;
[
$minutes
-ge
30
]
&&
clock
=
"🕝"
;;
02
)
clock
=
"🕑"
;
[
$minutes
-ge
30
]
&&
clock
=
"🕝"
;;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment