commit cc9bf8f2ade16cc562056941de3e547886c6a928 from: Omar Polo date: Fri Nov 05 19:22:15 2021 UTC import the telescope site commit - 15c3a9b724163bfc951b7e85e94a55fcbf0eff9b commit + cc9bf8f2ade16cc562056941de3e547886c6a928 blob - /dev/null blob + dd159a6a0a714106ec801bd43df5dd2152bd8c78 (mode 644) --- /dev/null +++ site/Makefile @@ -0,0 +1,19 @@ +.PHONY: all serve-www serve-gemini upload + +all: telescope.1.html telescope.1.txt + +telescope.1.html: ../telescope.1 + ./mdoc2html.sh $? $@ + +telescope.1.txt: ../telescope.1 + MANWIDTH=72 man -Tutf8 -l $? | col -b > $@ + +serve-www: + python3 -m http.server 8888 + +serve-gemini: + gmid -p 1966 . + +upload: + rsync --delete -a . op:sites/telescope.omarpolo.com + rsync --delete -a . op:gemini/telescope.omarpolo.com blob - /dev/null blob + 89fb8ab14c872a5df65936844e1edcaea7b7fa12 (mode 644) Binary files /dev/null and site/gallery/contrib-brutalist.png differ blob - /dev/null blob + 41ccc459cd6ee5580d49717898287c038862af1e (mode 644) --- /dev/null +++ site/gallery/index.gmi @@ -0,0 +1,18 @@ +=> / Home +=> /telescope.1.txt Docs + +# Gallery + +=> xterm-default-look.png default look on bright terminal +=> kitty-default-look.png default look on dark terminal + +=> xterm-contrib-light.png the contrib/light theme +=> kitty-contrib-dark.png the contrib/dark theme + +=> xterm-contrib-light-swiper.png swiper with the contrib/light theme +=> kitty-contrib-dark-swiper.png swiper with the contrib/dark theme + +=> xterm-contrib-light-about-help.png about:help with the contrib/light theme +=> kitty-contrib-dark-about-help.png about:help with the contrib/dark theme + +=> contrib-brutalist.png Brutalist theme blob - /dev/null blob + 71690c81c7272991672606de578b89c5136bf673 (mode 644) --- /dev/null +++ site/gallery/index.html @@ -0,0 +1,208 @@ + + + + Gallery | Telescope + + + + + +
+ +
+
+ +
+ + xterm-default-look.png + +
default look on bright terminal
+
+ +
+ + kitty-default-look.png + +
default look on dark terminal
+
+ +
+ + xterm-contrib-light.png + +
the contrib/light theme
+
+ +
+ + kitty-contrib-dark.png + +
the contrib/dark theme
+
+ +
+ + xterm-contrib-light-swiper.png + +
swiper with the contrib/light theme
+
+ +
+ + kitty-contrib-dark-swiper.png + +
swiper with the contrib/dark theme
+
+ +
+ + xterm-contrib-light-about-help.png + +
about:help with the contrib/light theme
+
+ +
+ + kitty-contrib-dark-about-help.png + +
about:help with the contrib/dark theme
+
+ +
+ + contrib-brutalist.png + +
Brutalist theme
+
+ +
+ + blob - /dev/null blob + 1549b03c690f36ecb7c77c0938fb980fe678d65d (mode 644) Binary files /dev/null and site/gallery/kitty-contrib-dark-about-help.png differ blob - /dev/null blob + a44d14bd763eebb52c0d47638b4a998d956df306 (mode 644) Binary files /dev/null and site/gallery/kitty-contrib-dark-swiper.png differ blob - /dev/null blob + 4e1cb100372535dcd95b9f717e6d8b8328422eb2 (mode 644) Binary files /dev/null and site/gallery/kitty-contrib-dark.png differ blob - /dev/null blob + e5958044ad89e1d7d9eb8b0e55b644a18fe3502b (mode 644) Binary files /dev/null and site/gallery/kitty-default-look.png differ blob - /dev/null blob + c63bf46995a5c8e4dc471e31dd44c5df108a84fd (mode 644) Binary files /dev/null and site/gallery/thumb-contrib-brutalist.png differ blob - /dev/null blob + 74f8053fcf0236f06cf7956afe92b6caec0e4ffe (mode 644) Binary files /dev/null and site/gallery/thumb-kitty-contrib-dark-about-help.png differ blob - /dev/null blob + f556f8b86978133bf9579057aa06a2531a7f0656 (mode 644) Binary files /dev/null and site/gallery/thumb-kitty-contrib-dark-swiper.png differ blob - /dev/null blob + 89bac118f433f36ff675794cdc87e20a1b95c42b (mode 644) Binary files /dev/null and site/gallery/thumb-kitty-contrib-dark.png differ blob - /dev/null blob + 0028874e763764ad86d4827d60f9f3bb6bc5afd0 (mode 644) Binary files /dev/null and site/gallery/thumb-kitty-default-look.png differ blob - /dev/null blob + ccbaa33ff0abed8d25690f2d9fe258f242719c37 (mode 644) Binary files /dev/null and site/gallery/thumb-xterm-contrib-light-about-help.png differ blob - /dev/null blob + 19fe6e1650f0493f3ac9bf7e518f8cf82bfc8001 (mode 644) Binary files /dev/null and site/gallery/thumb-xterm-contrib-light-swiper.png differ blob - /dev/null blob + 128c2cf1614d880aa24be63a02858842d139cf21 (mode 644) Binary files /dev/null and site/gallery/thumb-xterm-contrib-light.png differ blob - /dev/null blob + bb07a0326da32b32da013602907a115a0105e75b (mode 644) Binary files /dev/null and site/gallery/thumb-xterm-default-look.png differ blob - /dev/null blob + e20c6a4430e07e61f70520b7b10d52a238da02c4 (mode 644) Binary files /dev/null and site/gallery/xterm-contrib-light-about-help.png differ blob - /dev/null blob + 0085be332c87b9bd5ae99bef33514dda54e35d44 (mode 644) Binary files /dev/null and site/gallery/xterm-contrib-light-swiper.png differ blob - /dev/null blob + 4e4f074603420ea4e4441d9b33eb42c9524b1884 (mode 644) Binary files /dev/null and site/gallery/xterm-contrib-light.png differ blob - /dev/null blob + 01bb23f91ff1e62d3abe622de5a3ad166932a51d (mode 644) Binary files /dev/null and site/gallery/xterm-default-look.png differ blob - /dev/null blob + 38d2eca47e848857ca70693c1d46bc8c93413c55 (mode 644) --- /dev/null +++ site/index.gmi @@ -0,0 +1,117 @@ +=> /gallery/ Gallery +=> /telescope.1.txt Docs + +# Telescope + +> Telescope is a w3m-like browser for Gemini. + +``` Ascii art of the word “Telescope” and “v0.5.2” + _______ __ +|_ _|.-----.| |.-----.-----.----.-----.-----.-----. + | | | -__|| || -__|__ --| __| _ | _ | -__| + |___| |_____||__||_____|_____|____|_____| __|_____| + |__| v0.5.2 +``` + +Telescope is written entirely for fun, as a hobbystic project in my free time. As such, it lacks a ton of features you’ll find in more mature Gemini browsers, but it also has some unique ones. + +The UI is strongly inspired from Emacs and W3M, so you’ll find some familiar concepts, such as the minibuffer or the tabline, and the default keybindigs also reflect this, but care has been taken to add keys familiar for vi and CUA users too. + +=> https://asciinema.org/a/426862 Asciinema record + +## Install + +=> https://repology.org/project/telescope/versions Some distros provide a package — thanks to the maintainers! + +Source code and precompiled binaries for linux are available: +=> https://github.com/omar-polo/telescope/releases/download/0.5.2/telescope-0.5.2.tar.gz telescope-0.5.2.tar.gz +=> https://github.com/omar-polo/telescope/releases/download/0.5.2/telescope.linux.aarch64 telescope.linux.aarch64 +=> https://github.com/omar-polo/telescope/releases/download/0.5.2/telescope.linux.amd64 telescope.linux.amd64 + +=> https://github.com/omar-polo/telescope/releases/download/0.5.2/telescope-0.5.2-binaries.tar.gz telescope-0.5.2-binaries.tar.gz + +When in doubt, compile from source. It’s easy and takes less than a minute on a raspberry pi 3. The dependencies are: +* libncurses +* libevent +* libtls (from either LibreSSL or libretls) +* yacc (or GNU bison) + +Once all the dependencies are installed, building is as easy as: + +```Example of how to compile from source +$ curl -LO https://github.com/omar-polo/telescope/releases/download/0.5.2/telescope-0.5.2.tar.gz +$ tar xzvf telescope-0.5.2.tar.gz +$ cd telescope-0.5.2 +$ ./configure +$ make +$ sudo make install # eventually +``` + +A SHA256 file containing the checksums is available. However, that only checks for accidental corruption: you can use signify (SHA256.sig and the public key telescope-0.5.pub) or GPG. The hash of the signify public key is also included in the SHA256 file and signed with my GPG too. The signify public key for the next release ‘telescope-0.6.pub’ is also included. + +=> https://github.com/omar-polo/telescope/releases/download/0.5.2/SHA256 SHA256 +=> https://github.com/omar-polo/telescope/releases/download/0.5.2/SHA256.gpg SHA256.gpg +=> https://github.com/omar-polo/telescope/releases/download/0.5.2/SHA256.sig SHA256.sig +=> https://github.com/omar-polo/telescope/releases/download/0.5.2/telescope-0.5.pub telescope-0.5.pub +=> https://github.com/omar-polo/telescope/releases/download/0.5.2/telescope-0.6.pub telescope-0.6.pub + +```Example of how to verify the signature with signify +$ signify -C -p telescope-0.5.2.pub -x SHA256.sig +Signature Verified +telescope-0.5.2-binaries.tar.gz: OK +telescope-0.5.pub: OK +telescope-0.5.2.tar.gz: OK +telescope-0.6.pub: OK +telescope.linux.aarch64: OK +telescope.linux.amd64: OK +``` + +Finally, it’s possible to fetch the sources using git: + +=> //git.omarpolo.com/telescope/ git repository +=> https://github.com/omar-polo/telescope GitHub mirror + + +## Changelog for the last versions + +0.5.2 “Le nuvole” bugfix release — Released September 13, 2021 + +Bugfixes: +* some very long pages can cause (rarely) telescope to render a blank page +* allow creating files in ~/Downloads on OpenBSD +* reset download byte counter + +---- + +0.5.1 “Le nuvole” bugfix release — Released August 28, 2021 + +Telescope used to trim the initial “/” in gopher requests: this is not correct and while some servers are forgiving, other (rightfully) aren't. + +---- + +0.5 “Le nuvole” — Released August 27, 2021 + +## New features + +* support for the finger protocol +* support for the gopher protocol (only item types 0, 1 and 7 for the moment) +* highlight diff/patches +* typing the protocol of a URI is not needed anymore: added some heuristics to assume file:// URLs and fall back to gemini:// as default +* open local files and directories +* add an autosave timer to persist the session once in a while +* scroll completions with M-v/C-v (mini-scroll-up/mini-scroll-down) +* variable `tab-bar-show' controls the visibility of the tab bar + +## Improvements + +* new heuristics to extract a title for pages without headings: use the domain name or the "tilde username" +* about:new updated with some gopher links too +* reload doesn't push the current url to the history anymore +* push-button-new-tab opens a new tab *right after* the current one, not as the last +* improved the crash detection +* M-[ and M-] are bind to tab-move-to/tab-move + +## Bug fixes + +* fixed some crashes caused by cursor movements on empty pages +* correctly parse multiple attributes blob - /dev/null blob + ed4e009e600f65a7f9118cb69cacf129d965d751 (mode 644) --- /dev/null +++ site/index.html @@ -0,0 +1,308 @@ + + + + Telescope + + + + + +
+ +
+ +
+

Telescope is a w3m-like browser for Gemini

+
+

+ Telescope is written entirely for fun, as a hobbystic project in + my free time. As such, it lacks a ton of features you’ll find + in more mature Gemini browsers, but it also has some unique + ones. +

+

+ The UI is strongly inspired from Emacs and W3M, so you’ll find + some familiar concepts, such as the minibuffer or the tabline, + and the default keybindigs also reflect this, but keys familiar + for vi and CUA users are also present by default. +

+

+ + + +

+

Install

+

Some distros provide a package — thanks to the maintainers!

+ + Packaging status + +

Source code and precompiled binaries for linux are available:

+ +

+ When in doubt, compile from source. It’s easy and takes less + than a minute on a raspberry pi 3. The dependencies are: +

+ +

Once all the dependencies are installed, building is as easy as:

+
$ curl -LO https://github.com/omar-polo/telescope/releases/download/0.5.2/telescope-0.5.2.tar.gz
+$ tar xzvf telescope-0.5.2.tar.gz
+$ cd telescope-0.5.2
+$ ./configure
+$ make
+$ sudo make install # eventually
+    
+

+ A SHA256 file containing the checksums is available. However, + that only checks for accidental corruption: you can use signify + (SHA256.sig and the public key + telescope-0.5.pub) or GPG. The hash of the signify + public key is also included in the SHA256 file and signed with + my GPG too. The signify public key for the next release + telescope-0.6.pub is also included. +

+ +

How to verify the signature with signify:

+
$ signify -C -p telescope-0.5.pub -x SHA256.sig
+Signature Verified
+telescope-0.5.2-binaries.tar.gz: OK
+telescope-0.5.pub: OK
+telescope-0.5.2.tar.gz: OK
+telescope-0.6.pub: OK
+telescope.linux.aarch64: OK
+telescope.linux.amd64: OK
+    
+

Finally, it’s possible to fetch the sources using git:

+ +

Changelog for the last versions

+

0.5.2 “Le Nuvole” bugfix release — Released September 13, 2021

+

Bugfixes:

+ +
+

0.5.1 “Le Nuvole” bugfix release — Released August 28, 2021

+

+ Telescope used to trim the initial “/” in gopher requests: this + is not correct and while some servers are forgiving, other + (rightfully) aren't. +

+
+

0.5 “Le Nuvole” — Released August 27, 2021

+

New features

+ +

Improvements

+ +

Bug fixes

+ + + blob - /dev/null blob + 4cb718f9d31ec09d1bd023b5bd5aa3322e21f601 (mode 755) --- /dev/null +++ site/mdoc2html.sh @@ -0,0 +1,30 @@ +#!/bin/sh +# +# usage: mdoc2html.sh src out +# +# converts the manpage `src' to the HTML file `out', tweaking the +# style + +set -e + +: ${1:?missing input file} +: ${2:?missing output file} + +man -Thtml -l "$1" > "$2" + +exec ed "$2" < +a + body { + max-width: 960px; + margin: 0 auto; + padding: 0 10px; + font-size: 1rem; + } + + pre { + overflow: auto; + } +. +wq +EOF blob - /dev/null blob + cae9a4902742c1ab99e6774238fee59a77e451ac (mode 644) --- /dev/null +++ site/telescope.1.html @@ -0,0 +1,928 @@ + + + + + + + + TELESCOPE(1) + + + + + + + + +
TELESCOPE(1)General Commands ManualTELESCOPE(1)
+
+
+

+

telescope — + multi-protocol browser

+
+
+

+ + + + + +
telescope[-Chnv] + [-c config] + [URL]
+
+
+

+

telescope is an interactive browser that + supports the Finger, Gemini and Gopher protocols. + telescope features tabs, a minibuffer, interactive + completions, bookmarks and out-of-band TOFU verification.

+

The arguments are as follows:

+
+
, + --colors
+
Show all available colors and exit.
+
+ config
+
Specify an alternative configuration file. By default + $HOME/.telescope/config is loaded.
+
, + --help
+
Display version and usage.
+
+
Configtest mode. Only check the configuration file for validity.
+
, + --version
+
Display version.
+
+
+
+

+

telescope interface is divided into four + areas: the tabline, the body, the modeline and the echoarea/minibuffer.

+

The tabline is always at the top of the screen and displays the + tabs separated by a vertical line. When there are more tabs than the size of + the window allow to display, the characters ‘<’ or + ‘>’ are shown at the start/end of the tabline to indicate + that there are more tabs in that direction.

+

The body occupies the majority of the visible area. It contains + the current page and optionally a side window.

+

The modeline is the second to last row of the screen. It shows + some information about the page: a spinner when the page is loading, the + trust level, the document type, the scroll offset and the URL.

+

The echoarea is usually the last line of the screen. Messages are + often showed there, and link addresses too. The echoarea is also used to + obtain input from the user. When commands like + swiper or link-select are + invoked, the minibuffer area grows to show possible completions.

+
+
+

+

telescope aims to use the “Trust, + but Verify (where appropriate)” approach for TOFU (“Trust On + First Use”). The idea is to define three level of verification for a + certificate:

+
+
untrusted
+
(‘!’) the server fingerprint does NOT match the stored + value.
+
trusted
+
(‘v’) the server fingerprint matches the store one.
+
verified
+
(‘V’) the fingerprint matches and has been verified + out-of-band.
+
+

The trust level of the page is indicated in the modeline with the + indicated character.

+

Most of the time the “trusted” level is enough, but + where is appropriate users should be able to verify out-of-band the + certificate.

+

At the moment, there is no built-in support for an out-of-band + verification though.

+
+
+

+

The following protocols are supported:

+
+
about:
+
About pages are telescope internal page. See + about:about for a list of all these pages.
+
file://
+
File types know to telescope, such as .gmi, + .gemini, .txt, .md, .markdown, .diff or .patch, can be viewed inside the + application. Types of local files are detected solely based on the file + extension. On some systems, such as OpenBSD, only + files inside special directories (like /tmp + or ~/Downloads) are + available.
+
finger://
+
Finger URLs are interpreted as follows: +
    +
  • the host is determined by the host name portion of the URL
  • +
  • if the user portion of the URL is provided, it's interpreted as the + user to finger, otherwise the path component will be used
  • +
+ thus finger://user@hostname + and finger://hostname/user + are treated as the same URL.
+
gemini://
+
Gemini is fully supported, with the exception of client-certificates.
+
gopher://
+
Gopher support is limited to items type 0, 1 and 7. All text is assumed to + be encoded in UTF-8 (or ASCII).
+
+

User-entered URLs, given as argument on the command line or + entered with load-url, are intepreted with a simple + heuristic:

+
    +
  • if it's a proper absolute URL then use it as-is,
  • +
  • if it starts with “./” or “/” assume it's a + file:// URL,
  • +
  • otherwise assume it's a Gemini URL.
  • +
+
+
+

+

The default key bindings are very similar to GNU Emacs, but care + has been taken to include also bindings familiar for vi(1) + and “CUA” users. In the following examples, C-x means + Control-x, M-x means Meta-x, where the Meta key may be either a special key + on the keyboard or the ALT key; otherwise ESC followed by the key X works as + well, and C-M-x means to press the key X together with both Control and + Meta.

+

Keys are usually a single character, like ‘p’ or + ‘n’, but some special keys are accepted as well.

+

+
+
+
<up>
+
Up arrow
+
<down>
+
Down arrow
+
<left>
+
Left arrow
+
<right>
+
Right arrow
+
<prior>
+
Previous page/Page up
+
<next>
+
Next page/Page down
+
<home>
+
Home
+
<end>
+
End
+
<f0> thru <f63>
+
Function keys
+
del or backspace
+
Backspace
+
esc
+
Escape
+
space or spc
+
Space
+
enter or ret
+
Enter
+
tab
+
Tab
+
backtab
+
Depends on the configuration of the terminal emulator; usually shift + tab.
+
+
+
+

+
+
+
C-p
+
previous-line
+
C-n
+
next-line
+
C-f
+
forward-char
+
C-b
+
backward-char
+
M-{
+
backward-paragraph
+
M-}
+
forward-paragraph
+
C-a
+
move-beginning-of-line
+
C-e
+
move-end-of-line
+
M-v, M-space
+
scroll-up
+
C-v, space
+
scroll-down
+
M-<
+
beginning-of-buffer
+
M->
+
end-of-buffer
+
C-x C-c
+
kill-telescope
+
C-g
+
clear-minibuf
+
M-x
+
execute-extended-command
+
C-c {
+
dec-fill-column
+
C-c }
+
inc-fill-column
+
C-c p
+
previous-heading
+
C-c n
+
next-heading
+
>
+
load-url
+
<
+
load-current-url
+
C-x C-f
+
load-url
+
C-x M-f
+
load-current-url
+
C-x o
+
other-window
+
C-x t 0
+
tab-close
+
C-x t 1
+
tab-close-other
+
C-x t 2
+
tab-new
+
C-x t o
+
tab-next
+
C-x t O
+
tab-previous
+
C-x t m
+
tab-move
+
C-x t M
+
tab-move-to
+
B, C-M-b
+
previous-page
+
F, C-M-f
+
next-page
+
<f7> a
+
bookmark-page
+
<f7> <f7>
+
list-bookmarks
+
C-z
+
suspend-telescope
+
+
+
+
+

vi(1)-like + keys

+
+
+
k
+
previous-line
+
j
+
next-line
+
l
+
forward-char
+
h
+
backward-char
+
{
+
backward-paragraph
+
}
+
forward-paragraph
+
^
+
move-beginning-of-line
+
$
+
move-end-of-line
+
K
+
scroll-line-up
+
J
+
scroll-line-down
+
g g
+
beginning-of-buffer
+
G
+
end-of-buffer
+
g D
+
tab-close
+
g N
+
tab-new
+
g t
+
tab-next
+
g T
+
tab-previous
+
g M-t
+
tab-move
+
g M-T
+
tab-move-to
+
H
+
previous-page
+
L
+
next-page
+
q
+
kill-telescope
+
ESC
+
clear-minibuf
+
:
+
execute-extended-command
+
+
+
+
+

+
+
+
<up>
+
previous-line
+
<down>
+
next-line
+
<right>
+
forward-char
+
<left>
+
backward-char
+
<home>
+
move-beginning-of-line
+
<end>
+
move-end-of-line
+
<prior>
+
scroll-up
+
<next>
+
scroll-down
+
C-w
+
tab-close
+
C-t
+
tab-new
+
M-<prior>
+
tab-previous
+
M-<next>
+
tab-next
+
M-<left>
+
previous-page
+
M-<right>
+
next-page
+
<f5>
+
reload-page
+
r
+
reload-page
+
+
+
+
+

+
+
+
<f1>
+
toggle-help
+
enter
+
push-button
+
M-enter
+
push-button-new-tab
+
M-tab
+
previous-button
+
backtab
+
previous-button
+
tab
+
next-button
+
M-t
+
tab-select
+
[
+
tab-previous
+
]
+
tab-next
+
M-[
+
tab-move-to
+
M-]
+
tab-move
+
M-l
+
link-select
+
M-/
+
swiper
+
+
+
+
+

+
+
+
enter
+
mini-complete-and-exit
+
C-g
+
mini-abort
+
ESC
+
mini-abort
+
C-d
+
mini-delete-char
+
del
+
mini-delete-backward-char
+
backspace
+
mini-delete-backward-char
+
C-h
+
mini-delete-backward-char
+
C-b
+
backward-char
+
C-f
+
forward-char
+
<left>
+
backward-char
+
<right>
+
forward-char
+
C-e
+
move-end-of-line
+
C-a
+
move-beginning-of-line
+
<end>
+
move-end-of-line
+
<home>
+
move-beginning-of-line
+
C-k
+
mini-kill-line
+
M-p
+
mini-previous-history-element
+
M-n
+
mini-next-history-element
+
C-p
+
previous-completion
+
C-n
+
next-completion
+
<up>
+
previous-completion
+
<down>
+
next-completion
+
tab
+
insert-current-candidate
+
M-<
+
mini-goto-beginning
+
M->
+
mini-goto-end
+
+
+
+
+
+

+

Follows the documentation for the interactive commands. These + commands can be bound to a key or executed with + execute-extended-command.

+
+

+
+
+
Move point one character backward.
+
+
Move point one paragraph backward.
+
+
Move point to the beginning of the buffer.
+
+
Move point to the end of the buffer.
+
+
Move point one character forward.
+
+
Move point one paragraph forward.
+
+
Copy the current selection text as minibuffer input.
+
+
Move point at the beginning of the current (visual) line.
+
+
Move point at the end of the current (visual) line.
+
+
Move point to the next link.
+
+
Select the next completion.
+
+
Move point to the next heading.
+
+
Move point to the next (visual) line, in the same column if possible.
+
+
Move point to the previous link.
+
+
Select the previous completion.
+
+
Move point to the previous heading.
+
+
Move point to the previous (visual) line.
+
+
+
+ +
+
+
Save a page in the bookmark file. It preloads the minibuffer with the + current URL.
+
+
Load the bookmarks page.
+
+
+
+ +
+
+
Close the current tab.
+
+
Close all tabs but the current one.
+
+
Move the current tab after the next one, wrapping around if needed.
+
+
Move the current tab before the previous one, wrapping around if + needed.
+
+
Open a new tab.
+
+
Focus next tab, wrapping around eventually.
+
+
Focus the previous tab, wrapping around eventually.
+
+
Switch to a tab using the minibuffer.
+
+
+
+

+
+
+
Clear the echo area.
+
+
Decrement fill-column by two.
+
+
Execute an internal command.
+
+
Quit telescope.
+
+
Increment fill-column by two.
+ +
Select and visit a link using the minibuffer.
+
+
Edit the current URL.
+
+
Prompt for an URL.
+
+
Go forward in the page history.
+
+
Toggle olivetti mode (i.e. horizontal centering of the lines of the + window.)
+
+
Select the other window.
+
+
Go backward in the page history.
+
+
Follow link at point, or toggle the visibility of the following + preformatted block if called when the cursor is on the heading of the + block.
+
+
Follow link at point in a new tab.
+
+
Redraw the screen, useful if some background program messed up the + display.
+
+
Reload the current page.
+
+
Scroll down by one visual page.
+
+
Scroll down by one line.
+
+
Scroll up by one line.
+
+
Scroll up by one visual page.
+
+
Suspend the current telescope session.
+
+
Jump to a line using the minibuffer.
+
+
Jump to a heading using the minibuffer.
+
+
Toggle side window with help about available keys and their associated + interactive command.
+
+
Toggle the wrapping of preformatted blocks.
+
+
+
+

+
+
+
Abort the current minibuffer action.
+
+
Complete the current minibuffer action.
+
+
Delete the character before the point.
+
+
Delete the character after the point.
+
+
Select the first completion, if any.
+
+
Select the last completion, if any.
+
+
Delete from point until the end of the line.
+
+
Load the previous history element.
+
+
Load the next history element.
+
+
+
+

+

The following aliases are available during + execute-extended-command:

+
+
+
+
+
+
+
+
+ and wq
+
+
+
+
+
+

+

During the startup, telescope reads the + configuration file at ~/.telescope/config or the one + given with the -c flag.

+

telescope will also load a file called + config-TERM, where “TERM” is the name + of the terminal type (i.e. the TERM environment variable), if it exists.

+

The format of the configuration file is fairly flexible. The + current line can be extended over multiple ones using a backslash + (‘\’). Comments can be put anywhere in the file using a hash + mark (‘#’), and extend to the end of the current line, but + backslashes can't be used to extend comments over multiple lines.

+

The following constructs are available:

+
+
+ map key + cmd
+
Bind key to the function cmd + in the keymap map. Valid values for map are + “global-map” (i.e. when the user is viewing a page) and + “minibuffer-map” (i.e. when the minibuffer has the focus.) + key follows the same syntax described in + DEFAULT KEY BINDINGS and + all the possible functions are listed in + INTERACTIVE COMMANDS.
+
+ proto via + url
+
Use url as proxy for all URLs with protocol + proto. url must be a Gemini + URI without path, query and fragment component.
+
+ opt = + val
+
Set the option opt to the value + val. Valid options are: +

+
+
autosave
+
(integer) If greater than zero, save the session after the specified + amount of seconds after some events happens (new or closed tabs, + visited a link ...) Defaults to 20.
+
dont-wrap-pre
+
(integer) If nonzero, don't wrap preformatted blocks. Defaults to + 0.
+
emojify-link
+
(integer) If nonzero, when the text of a link starts with an emoji + followed by a space, use that emoji as line prefix. Defaults to + 1.
+
enable-colors
+
(integer) If nonzero, enable colours. Defaults to 0 if + NO_COLORS is set, 1 otherwise.
+
fill-column
+
(integer) If greater than zero, lines of text will be formatted in a + way that don't exceed the given number of columns. Defaults to + 80.
+
hide-pre-blocks
+
(integer) If nonzero, hide by default the body of the preformatted + blocks. Defaults to zero. push-button can be + used to toggle the visibility per-block.
+
hide-pre-closing-line
+
(integer) If nonzero, hide the closing line of preformatted blocks. + Defaults to 0.
+
hide-pre-context
+
(integer) If nonzero, hide the start and end line of the preformatted + blocks. If both hide-pre-context and hide-pre-blocks are nonzero, + preformatted blocks are irremediably hidden. Defaults to zero.
+
new-tab-url
+
(string) URL for the new tab page. Defaults to + “about:new”.
+
olivetti-mode
+
(integer) If nonzero, enable olivetti-mode + Defaults to 1.
+
set-title
+
(integer) If nonzero, set the terminal title to the page title. + Defaults to 1.
+
tab-bar-show
+
(integer) If tab-bar-show is -1 hide the tab bar permanently, if 0 + show it unconditionally. If it's 1, show the bar only when there is + more than one tab. Defaults to 1.
+
+
+
+ name option
+
Change the styling of the element identified by + name. Multiple options may be specified within curly + braces. Valid style identifiers are: +
+
+
line
+
the area outside the lines in the body of the page.
+
line.compl
+
the completions.
+
line.compl.current
+
the current completion.
+
line.help
+
text in the *Help* buffer.
+
line.text
+
text lines.
+
line.link
+
link lines.
+
line.title1..3
+
headings
+
line.item
+
item lines.
+
line.quote
+
quotes.
+
line.pre.start
+
the heading of a preformatted block.
+
line.pre
+
the content of a preformatted block.
+
line.pre.end
+
the closing line of a preformatted block.
+
minibuffer
+
the minibuffer.
+
modeline
+
the modeline.
+
tabline
+
the tabline.
+
tabline.tab
+
the non-focused tabs.
+
tabline.current
+
the focused tab.
+
+
+

Valid options are:

+
+
+ prefix [line + [trail]]
+
Sets the text attributes. If only one value is given, + line and trail default to + that; if two values are given then trail + defaults to prefix. Each attribute is a + comma-separated list of keywords: +
+
+
+
no attributes.
+
+
best highlighting mode for the terminal.
+
+
underlines the text.
+
+
reverses background/foreground colors.
+ +
makes the text blinking.
+
+
half bright.
+
+
extra bright or bold.
+
+
+

Only the style identifiers with the “line.” + prefix accept up to three attributes. The other will only use the + first one given.

+
+
+ prefix [line + [trail]]
+
Sets the background color. Follows the same behaviour as + attr regarding the optional parameters. The + colour is one of black, red, green, yellow, blue, magenta, cyan and + white; colour0 to colour255 (or color0 to color255) from the + 256-colour set; default for the default colour.
+
+ prefix [line + [trail]]
+
Sets the foreground color. It behaves just like + bg.
+
+ prfx [cont]
+
Sets the prefix for the current line type to + prfx and cont as the + prefix for the continuation lines (i.e. when a long line gets + wrapped.) If cont is not given its value will be + the same of prfx.
+
+
+
+
+
+

+

When telescope is started, it inspects the + following environment variables:

+
+
+
The user's login directory.
+
+
To decide whether to use colors or not. The content of the variable + doesn't matter.
+
+
The user's terminal name.
+
+
+
+

+
+
~/.telescope/bookmarks.gmi
+
Bookmarks file.
+
~/.telescope/config
+
Default configuration file.
+
~/.telescope/known_hosts
+
Hash of the certificates for all the known hosts. Each line contains three + fields: hostname with optional port number, hash of the certificate and a + numeric flag.
+
~/.telescope/lock
+
Lock file used to prevent multiple instance of + telescope from running at the same time.
+
~/.telescope/pages/about_*.gmi
+
Overrides for built-in about: pages.
+
~/.telescope/session
+
The list of tabs from the last session. Every line identifies a tab and + contains three space-separated fields: the full URL, a comma-separated + list of attributes and the cached title. Is written by + kill-telescope and loaded during startup.
+
+
+
+

+

It's possible to browse “the small web” (i.e. simple + websites) by using programs like the duckling-proxy by defining a proxy in + ~/.telescope/config:

+
+
proxy http via "gemini://127.0.0.1:1965"
+proxy https via "gemini://127.0.0.1:1965"
+
+

To load telescope without any + configuration

+
+
telescope -c /dev/null
+
+
+
+

+

The telescope program was written by + Omar Polo + <op@omarpolo.com>.

+
+
+

+

There's no UI for out-of-band certificates validation.

+
+
+ + + + + +
August 27, 2021OpenBSD 7.0
+ + blob - /dev/null blob + 1457102e0e3ae6800cd2e8eae69da256ad757397 (mode 644) --- /dev/null +++ site/telescope.1.txt @@ -0,0 +1,531 @@ +TELESCOPE(1) General Commands Manual TELESCOPE(1) + +NAME + telescope multi-protocol browser + +SYNOPSIS + telescope [-Chnv] [-c config] [URL] + +DESCRIPTION + telescope is an interactive browser that supports the Finger, Gemini and + Gopher protocols. telescope features tabs, a minibuffer, interactive + completions, bookmarks and out-of-band TOFU verification. + + The arguments are as follows: + + -C, --colors Show all available colors and exit. + + -c config Specify an alternative configuration file. By default + $HOME/.telescope/config is loaded. + + -h, --help Display version and usage. + + -n Configtest mode. Only check the configuration file for + validity. + + -v, --version Display version. + +UI CONCEPTS + telescope interface is divided into four areas: the tabline, the body, + the modeline and the echoarea/minibuffer. + + The tabline is always at the top of the screen and displays the tabs + separated by a vertical line. When there are more tabs than the size of + the window allow to display, the characters < or > are shown at the + start/end of the tabline to indicate that there are more tabs in that + direction. + + The body occupies the majority of the visible area. It contains the + current page and optionally a side window. + + The modeline is the second to last row of the screen. It shows some + information about the page: a spinner when the page is loading, the trust + level, the document type, the scroll offset and the URL. + + The echoarea is usually the last line of the screen. Messages are often + showed there, and link addresses too. The echoarea is also used to + obtain input from the user. When commands like swiper or link-select are + invoked, the minibuffer area grows to show possible completions. + +TOFU + telescope aims to use the Trust, but Verify (where appropriate) + approach for TOFU (Trust On First Use). The idea is to define three + level of verification for a certificate: + + untrusted (!) the server fingerprint does NOT match the stored + value. + + trusted (v) the server fingerprint matches the store one. + + verified (V) the fingerprint matches and has been verified out-of- + band. + + The trust level of the page is indicated in the modeline with the + indicated character. + + Most of the time the trusted level is enough, but where is appropriate + users should be able to verify out-of-band the certificate. + + At the moment, there is no built-in support for an out-of-band + verification though. + +SUPPORTED PROTOCOLS + The following protocols are supported: + + about: About pages are telescope internal page. See about:about for + a list of all these pages. + + file:// File types know to telescope, such as .gmi, .gemini, .txt, + .md, .markdown, .diff or .patch, can be viewed inside the + application. Types of local files are detected solely based + on the file extension. On some systems, such as OpenBSD, only + files inside special directories (like /tmp or ~/Downloads) + are available. + + finger:// Finger URLs are interpreted as follows: + the host is determined by the host name portion of the URL + if the user portion of the URL is provided, it's + interpreted as the user to finger, otherwise the path + component will be used + thus finger://user@hostname and finger://hostname/user are + treated as the same URL. + + gemini:// Gemini is fully supported, with the exception of client- + certificates. + + gopher:// Gopher support is limited to items type 0, 1 and 7. All text + is assumed to be encoded in UTF-8 (or ASCII). + + User-entered URLs, given as argument on the command line or entered with + load-url, are intepreted with a simple heuristic: + if it's a proper absolute URL then use it as-is, + if it starts with ./ or / assume it's a file:// URL, + otherwise assume it's a Gemini URL. + +DEFAULT KEY BINDINGS + The default key bindings are very similar to GNU Emacs, but care has been + taken to include also bindings familiar for vi(1) and CUA users. In + the following examples, C-x means Control-x, M-x means Meta-x, where the + Meta key may be either a special key on the keyboard or the ALT key; + otherwise ESC followed by the key X works as well, and C-M-x means to + press the key X together with both Control and Meta. + + Keys are usually a single character, like p or n, but some special + keys are accepted as well. + + Up arrow + Down arrow + Left arrow + Right arrow + Previous page/Page up + Next page/Page down + Home + End + thru Function keys + del or backspace Backspace + esc Escape + space or spc Space + enter or ret Enter + tab Tab + backtab Depends on the configuration of the terminal + emulator; usually shift tab. + + GNU Emacs-like keys + C-p previous-line + C-n next-line + C-f forward-char + C-b backward-char + M-{ backward-paragraph + M-} forward-paragraph + C-a move-beginning-of-line + C-e move-end-of-line + M-v, M-space scroll-up + C-v, space scroll-down + M-< beginning-of-buffer + M-> end-of-buffer + C-x C-c kill-telescope + C-g clear-minibuf + M-x execute-extended-command + C-c { dec-fill-column + C-c } inc-fill-column + C-c p previous-heading + C-c n next-heading + > load-url + < load-current-url + C-x C-f load-url + C-x M-f load-current-url + C-x o other-window + C-x t 0 tab-close + C-x t 1 tab-close-other + C-x t 2 tab-new + C-x t o tab-next + C-x t O tab-previous + C-x t m tab-move + C-x t M tab-move-to + B, C-M-b previous-page + F, C-M-f next-page + a bookmark-page + list-bookmarks + C-z suspend-telescope + + vi(1)-like keys + k previous-line + j next-line + l forward-char + h backward-char + { backward-paragraph + } forward-paragraph + ^ move-beginning-of-line + $ move-end-of-line + K scroll-line-up + J scroll-line-down + g g beginning-of-buffer + G end-of-buffer + g D tab-close + g N tab-new + g t tab-next + g T tab-previous + g M-t tab-move + g M-T tab-move-to + H previous-page + L next-page + q kill-telescope + ESC clear-minibuf + : execute-extended-command + + CUA-like keys + previous-line + next-line + forward-char + backward-char + move-beginning-of-line + move-end-of-line + scroll-up + scroll-down + C-w tab-close + C-t tab-new + M- tab-previous + M- tab-next + M- previous-page + M- next-page + reload-page + r reload-page + + Neither Emacs nor vi specific + toggle-help + enter push-button + M-enter push-button-new-tab + M-tab previous-button + backtab previous-button + tab next-button + M-t tab-select + [ tab-previous + ] tab-next + M-[ tab-move-to + M-] tab-move + M-l link-select + M-/ swiper + + Minibuffer-specific keys + enter mini-complete-and-exit + C-g mini-abort + ESC mini-abort + C-d mini-delete-char + del mini-delete-backward-char + backspace mini-delete-backward-char + C-h mini-delete-backward-char + C-b backward-char + C-f forward-char + backward-char + forward-char + C-e move-end-of-line + C-a move-beginning-of-line + move-end-of-line + move-beginning-of-line + C-k mini-kill-line + M-p mini-previous-history-element + M-n mini-next-history-element + C-p previous-completion + C-n next-completion + previous-completion + next-completion + tab insert-current-candidate + M-< mini-goto-beginning + M-> mini-goto-end + +INTERACTIVE COMMANDS + Follows the documentation for the interactive commands. These commands + can be bound to a key or executed with execute-extended-command. + + Movement commands + backward-char Move point one character backward. + backward-paragraph Move point one paragraph backward. + beginning-of-buffer Move point to the beginning of the buffer. + end-of-buffer Move point to the end of the buffer. + forward-char Move point one character forward. + forward-paragraph Move point one paragraph forward. + insert-current-candidate Copy the current selection text as minibuffer + input. + move-beginning-of-line Move point at the beginning of the current + (visual) line. + move-end-of-line Move point at the end of the current (visual) + line. + next-button Move point to the next link. + next-completion Select the next completion. + next-heading Move point to the next heading. + next-line Move point to the next (visual) line, in the + same column if possible. + previous-button Move point to the previous link. + previous-completion Select the previous completion. + previous-heading Move point to the previous heading. + previous-line Move point to the previous (visual) line. + + Bookmark-related commands + bookmark-page Save a page in the bookmark file. It preloads + the minibuffer with the current URL. + list-bookmarks Load the bookmarks page. + + Tab-related commands + tab-close Close the current tab. + tab-close-other Close all tabs but the current one. + tab-move Move the current tab after the next one, + wrapping around if needed. + tab-move-to Move the current tab before the previous one, + wrapping around if needed. + tab-new Open a new tab. + tab-next Focus next tab, wrapping around eventually. + tab-previous Focus the previous tab, wrapping around + eventually. + tab-select Switch to a tab using the minibuffer. + + Misc commands + clear-minibuf Clear the echo area. + dec-fill-column Decrement fill-column by two. + execute-extended-command Execute an internal command. + kill-telescope Quit telescope. + inc-fill-column Increment fill-column by two. + link-select Select and visit a link using the minibuffer. + load-current-url Edit the current URL. + load-url Prompt for an URL. + next-page Go forward in the page history. + olivetti-mode Toggle olivetti mode (i.e. horizontal centering + of the lines of the window.) + other-window Select the other window. + previous-page Go backward in the page history. + push-button Follow link at point, or toggle the visibility + of the following preformatted block if called + when the cursor is on the heading of the block. + push-button-new-tab Follow link at point in a new tab. + redraw Redraw the screen, useful if some background + program messed up the display. + reload-page Reload the current page. + scroll-down Scroll down by one visual page. + scroll-line-down Scroll down by one line. + scroll-line-up Scroll up by one line. + scroll-up Scroll up by one visual page. + suspend-telescope Suspend the current telescope session. + swiper Jump to a line using the minibuffer. + toc Jump to a heading using the minibuffer. + toggle-help Toggle side window with help about available + keys and their associated interactive command. + toggle-pre-wrap Toggle the wrapping of preformatted blocks. + + Minibuffer commands + mini-abort Abort the current minibuffer action. + mini-complete-and-exit Complete the current minibuffer action. + mini-delete-backward-char + Delete the character before the point. + mini-delete-char Delete the character after the point. + mini-goto-beginning Select the first completion, if any. + mini-goto-end Select the last completion, if any. + mini-kill-line Delete from point until the end of the line. + mini-next-history-element + Load the previous history element. + mini-previous-history-element + Load the next history element. + + Aliases + The following aliases are available during execute-extended-command: + tabn tab-next + tabnew tab-new + tabp tab-previous + q and wq kill-telescope + +CONFIGURATION FILE + During the startup, telescope reads the configuration file at + ~/.telescope/config or the one given with the -c flag. + + telescope will also load a file called config-TERM, where TERM is the + name of the terminal type (i.e. the TERM environment variable), if it + exists. + + The format of the configuration file is fairly flexible. The current + line can be extended over multiple ones using a backslash (\). + Comments can be put anywhere in the file using a hash mark (#), and + extend to the end of the current line, but backslashes can't be used to + extend comments over multiple lines. + + The following constructs are available: + + bind map key cmd + Bind key to the function cmd in the keymap map. Valid values for + map are global-map (i.e. when the user is viewing a page) and + minibuffer-map (i.e. when the minibuffer has the focus.) key + follows the same syntax described in DEFAULT KEY BINDINGS and all + the possible functions are listed in INTERACTIVE COMMANDS. + + proxy proto via url + Use url as proxy for all URLs with protocol proto. url must be a + Gemini URI without path, query and fragment component. + + set opt = val + Set the option opt to the value val. Valid options are: + + autosave (integer) If greater than zero, save the session + after the specified amount of seconds after some + events happens (new or closed tabs, visited a link + ...) Defaults to 20. + dont-wrap-pre (integer) If nonzero, don't wrap preformatted + blocks. Defaults to 0. + emojify-link (integer) If nonzero, when the text of a link + starts with an emoji followed by a space, use that + emoji as line prefix. Defaults to 1. + enable-colors (integer) If nonzero, enable colours. Defaults to + 0 if NO_COLORS is set, 1 otherwise. + fill-column (integer) If greater than zero, lines of text will + be formatted in a way that don't exceed the given + number of columns. Defaults to 80. + hide-pre-blocks + (integer) If nonzero, hide by default the body of + the preformatted blocks. Defaults to zero. + push-button can be used to toggle the visibility + per-block. + hide-pre-closing-line + (integer) If nonzero, hide the closing line of + preformatted blocks. Defaults to 0. + hide-pre-context + (integer) If nonzero, hide the start and end line + of the preformatted blocks. If both hide-pre- + context and hide-pre-blocks are nonzero, + preformatted blocks are irremediably hidden. + Defaults to zero. + new-tab-url (string) URL for the new tab page. Defaults to + about:new. + olivetti-mode (integer) If nonzero, enable olivetti-mode + Defaults to 1. + set-title (integer) If nonzero, set the terminal title to + the page title. Defaults to 1. + tab-bar-show (integer) If tab-bar-show is -1 hide the tab bar + permanently, if 0 show it unconditionally. If + it's 1, show the bar only when there is more than + one tab. Defaults to 1. + + style name option + Change the styling of the element identified by name. Multiple + options may be specified within curly braces. Valid style + identifiers are: + line the area outside the lines in the body + of the page. + line.compl the completions. + line.compl.current the current completion. + line.help text in the *Help* buffer. + line.text text lines. + line.link link lines. + line.title1..3 headings + line.item item lines. + line.quote quotes. + line.pre.start the heading of a preformatted block. + line.pre the content of a preformatted block. + line.pre.end the closing line of a preformatted + block. + minibuffer the minibuffer. + modeline the modeline. + tabline the tabline. + tabline.tab the non-focused tabs. + tabline.current the focused tab. + + Valid options are: + + attr prefix [line [trail]] + Sets the text attributes. If only one value is given, + line and trail default to that; if two values are given + then trail defaults to prefix. Each attribute is a + comma-separated list of keywords: + normal no attributes. + standout best highlighting mode for the terminal. + underline underlines the text. + reverse reverses background/foreground colors. + blink makes the text blinking. + dim half bright. + bold extra bright or bold. + + Only the style identifiers with the line. prefix accept + up to three attributes. The other will only use the + first one given. + + bg prefix [line [trail]] + Sets the background color. Follows the same behaviour as + attr regarding the optional parameters. The colour is + one of black, red, green, yellow, blue, magenta, cyan and + white; colour0 to colour255 (or color0 to color255) from + the 256-colour set; default for the default colour. + + fg prefix [line [trail]] + Sets the foreground color. It behaves just like bg. + + prefix prfx [cont] + Sets the prefix for the current line type to prfx and + cont as the prefix for the continuation lines (i.e. when + a long line gets wrapped.) If cont is not given its value + will be the same of prfx. + +ENVIRONMENT + When telescope is started, it inspects the following environment + variables: + + HOME The user's login directory. + + NO_COLORS To decide whether to use colors or not. The content of the + variable doesn't matter. + + TERM The user's terminal name. + +FILES + ~/.telescope/bookmarks.gmi + Bookmarks file. + ~/.telescope/config + Default configuration file. + ~/.telescope/known_hosts + Hash of the certificates for all the known hosts. Each line + contains three fields: hostname with optional port number, hash + of the certificate and a numeric flag. + ~/.telescope/lock + Lock file used to prevent multiple instance of telescope from + running at the same time. + ~/.telescope/pages/about_*.gmi + Overrides for built-in about: pages. + ~/.telescope/session + The list of tabs from the last session. Every line identifies a + tab and contains three space-separated fields: the full URL, a + comma-separated list of attributes and the cached title. Is + written by kill-telescope and loaded during startup. + +EXAMPLES + It's possible to browse the small web (i.e. simple websites) by using + programs like the duckling-proxy by defining a proxy in + ~/.telescope/config: + + proxy http via "gemini://127.0.0.1:1965" + proxy https via "gemini://127.0.0.1:1965" + + To load telescope without any configuration + + telescope -c /dev/null + +AUTHORS + The telescope program was written by Omar Polo . + +BUGS + There's no UI for out-of-band certificates validation. + +OpenBSD 7.0 August 27, 2021 OpenBSD 7.0