summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAki <please@ignore.pl>2020-08-07 23:36:57 +0200
committerAki <please@ignore.pl>2020-08-07 23:36:57 +0200
commite2e3244eee4429aef9a2fd158beeccdd5bac0b9b (patch)
treec2a0db9d0444a56bf6b0f4fb0f799a49fad44261
parent6173beea4d496803aa40030ba6024db5fa997c4c (diff)
downloadbrowse-e2e3244eee4429aef9a2fd158beeccdd5bac0b9b.zip
browse-e2e3244eee4429aef9a2fd158beeccdd5bac0b9b.tar.gz
browse-e2e3244eee4429aef9a2fd158beeccdd5bac0b9b.tar.bz2
Fixed extended mime types
-rwxr-xr-xopener2
-rwxr-xr-xphttp2
2 files changed, 2 insertions, 2 deletions
diff --git a/opener b/opener
index d9160fb..6ece94e 100755
--- a/opener
+++ b/opener
@@ -2,7 +2,7 @@
case "$1" in
application/pdf) exec zathura "$3";;
image/*) exec sxiv "$3";;
- text/html) exec ./viewhtml "$3" "$2";;
+ text/html*) exec ./viewhtml "$3" "$2";;
text/*) exec less "$3";;
*) echo "\e[31m$1\e[0m $2 $3";;
esac
diff --git a/phttp b/phttp
index d74ac9b..cb6d504 100755
--- a/phttp
+++ b/phttp
@@ -15,7 +15,7 @@ get_with_arguments() {
return
}
local META
- META=$(curl -sL -w "%{content_type} %{url_effective}\n" $@ -o "$PHTTP_CACHE/files/$BASENAME") && {
+ META=$(curl -sL -w "\"%{content_type}\" %{url_effective}\n" $@ -o "$PHTTP_CACHE/files/$BASENAME") && {
META="$(echo $META | rev | cut -d/ -f2- | rev)/"
echo "$META $PHTTP_CACHE/files/$BASENAME"
echo "$META" > $PHTTP_CACHE/meta/$BASENAME