remove possible trailing slash from titles in rss feed

This commit is contained in:
James Tomasino 2018-09-01 18:55:03 -04:00
parent 6dce0f1924
commit f0f21df913
2 changed files with 3 additions and 3 deletions

4
burrow
View File

@ -1,6 +1,6 @@
#!/bin/sh
version="v1.6.0"
version="v1.6.1"
configfiles="$HOME/.config/burrow/config $HOME/.config/burrow $HOME/.burrow"
@ -509,7 +509,7 @@ make_rss () {
item_type=0
fi
date="$(printf "%s" "$filename" | sed 's|^\./||' | awk 'BEGIN { FS="-" } { print $1; }')"
title="$(printf "%s" "$filename" | awk 'BEGIN { FS="-" } { $1=""; print $0; }' | sed "s|/gophermap||" | sed 's/^\ //' | awk '{for(i=1;i<=NF;i++){ $i=toupper(substr($i,1,1)) substr($i,2) }}1')"
title="$(printf "%s" "$filename" | awk 'BEGIN { FS="-" } { $1=""; print $0; }' | sed "s|/gophermap||" | sed 's/^\ //' | sed 's|/$||' | awk '{for(i=1;i<=NF;i++){ $i=toupper(substr($i,1,1)) substr($i,2) }}1')"
{
printf "<item>\\n"
printf " <title>%s</title>\\n" "$title"

View File

@ -1,4 +1,4 @@
.TH BURROW 1 "15 Jul 2018" "version 1.6.0"
.TH BURROW 1 "01 Sep 2018" "version 1.6.1"
.SH NAME
burrow \- a helper for building and managing a gopher hole
.SH SYNOPSIS