Changed the stash format
This commit is contained in:
+6
-3
@@ -7,7 +7,7 @@
|
||||
# - mouse support
|
||||
# - smoother rendering and scrolling
|
||||
# - better edge-case stability
|
||||
# - better Gophermap processing according to the RFC
|
||||
# - better Gophermap processing according to the RFC1436
|
||||
# - multi-level navigation history (although you can only go back)
|
||||
# - status bar with currently opened resource name
|
||||
# - ability to accept gopher:// URLs from the command line
|
||||
@@ -269,8 +269,11 @@ goback() { # remove the last AM line from history and go there
|
||||
|
||||
stashlink() { # stash the link to the currently viewed resource
|
||||
local gopherlink="$(amtogopher "$CURRENTAM")"
|
||||
printf '[%s] %s\n' "$(date -u '+%F %T')" "$gopherlink" >> $BOPHER_LINKSTASH
|
||||
printf 'Stashed %s%s' "$gopherlink" "$ERESET${ESC}[$TERMROWS;0H" # just reset the cursor to the last line
|
||||
readarray -d $'\t' -t fields < <(printf '%s' "$CURRENTAM") # extract individual fields
|
||||
local desc="${fields[1]}"
|
||||
[[ -z "$desc" ]] && desc='Unnamed'
|
||||
printf '%s [%s] %s - %s\t%s\t%s\t%s\r\n' "${fields[5]}" "$(date -u '+%F %T')" "$desc" "$gopherlink" "${fields[4]}" "${fields[2]}" "${fields[3]}" >> $BOPHER_LINKSTASH
|
||||
printf 'Stashed %s - %s%s' "$desc" "$gopherlink" "$ERESET${ESC}[$TERMROWS;0H" # just reset the cursor to the last line
|
||||
}
|
||||
|
||||
# Focus and click a link on a Gophermap
|
||||
|
||||
Reference in New Issue
Block a user