summaryrefslogtreecommitdiff
path: root/etc/functions/reload
diff options
context:
space:
mode:
Diffstat (limited to 'etc/functions/reload')
-rw-r--r--etc/functions/reload11
1 files changed, 11 insertions, 0 deletions
diff --git a/etc/functions/reload b/etc/functions/reload
new file mode 100644
index 0000000..f4fc399
--- /dev/null
+++ b/etc/functions/reload
@@ -0,0 +1,11 @@
+## vim:ft=zsh
+if [[ ${#*} == 0 ]] {
+ autoload xsource
+ xsource ~/.zshrc
+} else {
+ local function
+ for function in $@; {
+ unfunction $function
+ autoload $function
+ }
+}