mirror of
https://github.com/notwa/rc
synced 2024-06-29 02:17:12 -07:00
14 lines
254 B
Bash
Executable File
14 lines
254 B
Bash
Executable File
#!/usr/bin/env zsh
|
|
# YES_ZSH
|
|
# YES_BASH
|
|
# YES_DASH
|
|
|
|
# though technically compatible with other shells,
|
|
# extra functionality is through zsh's extended arithmetic functions.
|
|
|
|
hex() {
|
|
printf "%08X\n" "$(($@))"
|
|
}
|
|
|
|
[ "${SOURCING:-0}" -gt 0 ] || hex "$@"
|