summaryrefslogtreecommitdiff
path: root/.config/zsh/oh-my-zsh/plugins/coffee/coffee.plugin.zsh
diff options
context:
space:
mode:
authorPedro Pereira <pedro.hr.pereira@proton.me>2026-10-16 15:19:13 -0300
committerPedro Pereira <pedro.hr.pereira@proton.me>2026-10-16 15:19:13 -0300
commit1eb69e9a795cc19450178c07d8d382622bc7ad70 (patch)
treeb6bc60605044fe929986f31b3b6bf4fee9b56e14 /.config/zsh/oh-my-zsh/plugins/coffee/coffee.plugin.zsh
first commit
Diffstat (limited to '.config/zsh/oh-my-zsh/plugins/coffee/coffee.plugin.zsh')
-rw-r--r--.config/zsh/oh-my-zsh/plugins/coffee/coffee.plugin.zsh16
1 files changed, 16 insertions, 0 deletions
diff --git a/.config/zsh/oh-my-zsh/plugins/coffee/coffee.plugin.zsh b/.config/zsh/oh-my-zsh/plugins/coffee/coffee.plugin.zsh
new file mode 100644
index 0000000..6d1ce5c
--- /dev/null
+++ b/.config/zsh/oh-my-zsh/plugins/coffee/coffee.plugin.zsh
@@ -0,0 +1,16 @@
+#!/bin/zsh
+
+# compile a string of coffeescript and print to output
+cf () {
+ coffee -peb "$1"
+}
+# compile & copy to clipboard
+cfc () {
+ cf "$1" | clipcopy
+}
+
+# compile from clipboard & print
+alias cfp='cf "$(clippaste)"'
+
+# compile from clipboard and copy to clipboard
+alias cfpc='cfp | clipcopy'