diff options
author | June McEnroe <june@causal.agency> | 2019-07-15 23:13:19 -0400 |
---|---|---|
committer | June McEnroe <june@causal.agency> | 2019-07-15 23:13:19 -0400 |
commit | 55c111d59ce0ee9ddc8297af709a2ff122704895 (patch) | |
tree | b7f818cd4335a2fa09f8f64b42d6f13b9d386ec0 /bin/up.sh | |
parent | Implement scrolling region (diff) | |
download | src-55c111d59ce0ee9ddc8297af709a2ff122704895.tar.gz src-55c111d59ce0ee9ddc8297af709a2ff122704895.zip |
Add up -t
Diffstat (limited to 'bin/up.sh')
-rw-r--r-- | bin/up.sh | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/bin/up.sh b/bin/up.sh index ef3ff6c7..a439c8f7 100644 --- a/bin/up.sh +++ b/bin/up.sh @@ -45,13 +45,27 @@ uploadScreen() { upload "${temp}/capture.png" } -args=$(setopt 'chs' "$@") +uploadTerminal() { + temp + cat > "${temp}/term.html" <<-EOF + <!DOCTYPE html> + <title>${1}</title> + <style> + $(scheme -s) + </style> + EOF + ptee "$@" | shotty -Bcs >> "${temp}/term.html" + upload "${temp}/term.html" +} + +args=$(setopt 'chst' "$@") eval set -- "$args" for opt; do case "$opt" in (-c) shift; fn=uploadCommand;; (-h) shift; fn=uploadHi;; (-s) shift; fn=uploadScreen;; + (-t) shift; fn=uploadTerminal;; (--) shift; break;; esac done |