Skip to content

Commit

Permalink
Version 2.4.0 (2020-05-16)
Browse files Browse the repository at this point in the history
  • Loading branch information
sunaku committed May 16, 2020
1 parent 72e5525 commit 9cd872c
Show file tree
Hide file tree
Showing 24 changed files with 83 additions and 64 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
# Search API docs offline, in your terminal or browser

dasht is a collection of shell scripts for searching, browsing, and managing
API documentation (in the form of [150+ offline documentation sets][docsets],
courtesy of [Dash for OS X][Dash]) all from the comfort of your own terminal!
API documentation (in the form of [200+ offline documentation sets][docsets],
courtesy of [Dash for macOS][Dash]) all from the comfort of your own terminal!

The name "dasht" is a portmanteau of [Dash] and the letter "t", for terminal.
Etymologically, "dasht" is Persian for _plain_, as in an flat expanse of land,
Expand Down
59 changes: 59 additions & 0 deletions VERSION.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,62 @@
## Version 2.4.0 (2020-05-16)

This release drops special Web browser requirements to access dasht-server(1),
improves error messages in dasht-docset-install(1), ensures clean up of stale
files that contain whitespace in their names, and resolves a few other issues.

### Minor:

* dasht-server-http(1): serve local `file://` URLs through `http://` URLs.

Users no longer have to use special browsers or special configurations
that allow the loading of `file://` links from `http://127.0.0.1` URLs.
All browsers can now natively access the dasht-server(1) search engine.

See https://github.com/sunaku/dasht/issues/45

### Patch:

* dasht-docsets-update(1): remove stale files with whitespace in names.

Thanks to @frodeaa for reporting this issue and contributing a patch:

> Replace `xargs` with `while read` and avoid globbing. The same could be
> achived by using `xargs -0` (GNU/BSD) if newline is replaced with `\0`.
>
> tr '\n' '\0' | xargs -0 sh -e -u -c '
See https://github.com/sunaku/dasht/issues/35

* dasht-server-http(1): escape "C++" docset name as `^C\+\+$` regex.

When the "C++" docset was selected from the "in docsets" dropdown menu in
dasht-server(1), the plus signs weren't properly escaped per regex syntax.

See https://github.com/sunaku/dasht/issues/49

* dasht-docsets-install(1): validate gzip(1) integrity before extraction.

This avoids cryptic errors from tarball extraction:

gzip: stdin: unexpected end of file
tar: Child returned status 1
tar: Error is not recoverable: exiting now

By pointing out the cause of the error to the user:

gzip: Apple_Guides_and_Sample_Code.tgz: unexpected end of file

* dasht-docsets-install(1): restore support for older wget(1) versions.

Older wget versions don't support the `--show-progress` option:

wget: unrecognized option '--show-progress'
Usage: wget [OPTION]... [URL]...

Try ‘wget --help’ for more options.

* dasht-query-line(1): update URI fragments for HTML and CSS docsets.

## Version 2.3.0 (2018-10-09)

This release provides better error messaging for first-time users who try to
Expand Down
2 changes: 1 addition & 1 deletion bin/dasht
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh -e
#
# # DASHT 1 2018-10-09 2.3.0
# # DASHT 1 2020-05-16 2.4.0
#
# ## NAME
#
Expand Down
2 changes: 1 addition & 1 deletion bin/dasht-docsets
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh -e
#
# # DASHT-DOCSETS 1 2018-10-09 2.3.0
# # DASHT-DOCSETS 1 2020-05-16 2.4.0
#
# ## NAME
#
Expand Down
2 changes: 1 addition & 1 deletion bin/dasht-docsets-extract
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh -e
#
# # DASHT-DOCSETS-EXTRACT 1 2018-10-09 2.3.0
# # DASHT-DOCSETS-EXTRACT 1 2020-05-16 2.4.0
#
# ## NAME
#
Expand Down
2 changes: 1 addition & 1 deletion bin/dasht-docsets-install
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh -e
#
# # DASHT-DOCSETS-INSTALL 1 2018-10-09 2.3.0
# # DASHT-DOCSETS-INSTALL 1 2020-05-16 2.4.0
#
# ## NAME
#
Expand Down
2 changes: 1 addition & 1 deletion bin/dasht-docsets-remove
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh -e
#
# # DASHT-DOCSETS-REMOVE 1 2018-10-09 2.3.0
# # DASHT-DOCSETS-REMOVE 1 2020-05-16 2.4.0
#
# ## NAME
#
Expand Down
2 changes: 1 addition & 1 deletion bin/dasht-docsets-update
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh -e
#
# # DASHT-DOCSETS-UPDATE 1 2018-10-09 2.3.0
# # DASHT-DOCSETS-UPDATE 1 2020-05-16 2.4.0
#
# ## NAME
#
Expand Down
2 changes: 1 addition & 1 deletion bin/dasht-query-exec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh -e
#
# # DASHT-QUERY-EXEC 1 2018-10-09 2.3.0
# # DASHT-QUERY-EXEC 1 2020-05-16 2.4.0
#
# ## NAME
#
Expand Down
2 changes: 1 addition & 1 deletion bin/dasht-query-html
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh -e
#
# # DASHT-QUERY-HTML 1 2018-10-09 2.3.0
# # DASHT-QUERY-HTML 1 2020-05-16 2.4.0
#
# ## NAME
#
Expand Down
2 changes: 1 addition & 1 deletion bin/dasht-query-line
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh -e
#
# # DASHT-QUERY-LINE 1 2018-10-09 2.3.0
# # DASHT-QUERY-LINE 1 2020-05-16 2.4.0
#
# ## NAME
#
Expand Down
2 changes: 1 addition & 1 deletion bin/dasht-server
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh -e
#
# # DASHT-SERVER 1 2018-10-09 2.3.0
# # DASHT-SERVER 1 2020-05-16 2.4.0
#
# ## NAME
#
Expand Down
2 changes: 1 addition & 1 deletion bin/dasht-server-http
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh -e
#
# # DASHT-SERVER-HTTP 1 2018-10-09 2.3.0
# # DASHT-SERVER-HTTP 1 2020-05-16 2.4.0
#
# ## NAME
#
Expand Down
2 changes: 1 addition & 1 deletion man/man1/dasht-docsets-extract.1
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH DASHT\-DOCSETS\-EXTRACT 1 2018\-10\-09 2.3.0
.TH DASHT\-DOCSETS\-EXTRACT 1 2020\-05\-16 2.4.0
.SH NAME
.PP
dasht\-docsets\-extract \- extracts Dash \[la]https://kapeli.com/dash\[ra] docset archives (\fB\fC*.tgz\fR files)
Expand Down
2 changes: 1 addition & 1 deletion man/man1/dasht-docsets-install.1
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH DASHT\-DOCSETS\-INSTALL 1 2018\-10\-09 2.3.0
.TH DASHT\-DOCSETS\-INSTALL 1 2020\-05\-16 2.4.0
.SH NAME
.PP
dasht\-docsets\-install \- installs new Dash \[la]https://kapeli.com/dash\[ra] docsets
Expand Down
2 changes: 1 addition & 1 deletion man/man1/dasht-docsets-remove.1
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH DASHT\-DOCSETS\-REMOVE 1 2018\-10\-09 2.3.0
.TH DASHT\-DOCSETS\-REMOVE 1 2020\-05\-16 2.4.0
.SH NAME
.PP
dasht\-docsets\-remove \- removes installed Dash \[la]https://kapeli.com/dash\[ra] docsets
Expand Down
2 changes: 1 addition & 1 deletion man/man1/dasht-docsets-update.1
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH DASHT\-DOCSETS\-UPDATE 1 2018\-10\-09 2.3.0
.TH DASHT\-DOCSETS\-UPDATE 1 2020\-05\-16 2.4.0
.SH NAME
.PP
dasht\-docsets\-update \- updates installed Dash \[la]https://kapeli.com/dash\[ra] docsets
Expand Down
2 changes: 1 addition & 1 deletion man/man1/dasht-docsets.1
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH DASHT\-DOCSETS 1 2018\-10\-09 2.3.0
.TH DASHT\-DOCSETS 1 2020\-05\-16 2.4.0
.SH NAME
.PP
dasht\-docsets \- lists installed Dash \[la]https://kapeli.com/dash\[ra] docsets
Expand Down
2 changes: 1 addition & 1 deletion man/man1/dasht-query-exec.1
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH DASHT\-QUERY\-EXEC 1 2018\-10\-09 2.3.0
.TH DASHT\-QUERY\-EXEC 1 2020\-05\-16 2.4.0
.SH NAME
.PP
dasht\-query\-exec \- searches a Dash \[la]https://kapeli.com/dash\[ra] docset's SQLite3 database file
Expand Down
2 changes: 1 addition & 1 deletion man/man1/dasht-query-html.1
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH DASHT\-QUERY\-HTML 1 2018\-10\-09 2.3.0
.TH DASHT\-QUERY\-HTML 1 2020\-05\-16 2.4.0
.SH NAME
.PP
dasht\-query\-html \- searches Dash \[la]https://kapeli.com/dash\[ra] docsets and emits HTML table rows
Expand Down
2 changes: 1 addition & 1 deletion man/man1/dasht-query-line.1
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH DASHT\-QUERY\-LINE 1 2018\-10\-09 2.3.0
.TH DASHT\-QUERY\-LINE 1 2020\-05\-16 2.4.0
.SH NAME
.PP
dasht\-query\-line \- searches Dash \[la]https://kapeli.com/dash\[ra] docsets and emits groups of lines
Expand Down
2 changes: 1 addition & 1 deletion man/man1/dasht-server-http.1
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH DASHT\-SERVER\-HTTP 1 2018\-10\-09 2.3.0
.TH DASHT\-SERVER\-HTTP 1 2020\-05\-16 2.4.0
.SH NAME
.PP
dasht\-server\-http \- simple search engine that powers
Expand Down
42 changes: 1 addition & 41 deletions man/man1/dasht-server.1
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH DASHT\-SERVER 1 2018\-10\-09 2.3.0
.TH DASHT\-SERVER 1 2020\-05\-16 2.4.0
.SH NAME
.PP
dasht\-server \- runs a local search engine for your web browser
Expand Down Expand Up @@ -26,46 +26,6 @@ which can be used to launch a web browser along with the search engine:
dasht\-server | xargs \-n1 w3m
.fi
.RE
.SS Browser refuses to load \fB\fCfile://\fR links
.PP
Some browsers refuse to load \fB\fCfile://\fR links from \fB\fChttp://127.0.0.1\fR URLs.
However, the following browsers do not suffer from this limitation and are
thereby recommended for use with the search engine provided by this script.
.PP
Recommended terminal web browsers:
.RS
.IP \(bu 2
w3m \[la]http://w3m.sourceforge.net\[ra]
.IP \(bu 2
elinks \[la]http://elinks.or.cz\[ra]
.IP \(bu 2
lynx \[la]http://lynx.invisible-island.net\[ra]
.RE
.PP
Recommended graphical web browsers:
.RS
.IP \(bu 2
Dillo \[la]http://www.dillo.org\[ra]
.IP \(bu 2
NetSurf \[la]http://www.netsurf-browser.org\[ra]
.IP \(bu 2
Chrome \[la]https://www.google.com/chrome/\[ra] using the LocalLinks extension \[la]https://chrome.google.com/webstore/detail/locallinks/jllpkdkcdjndhggodimiphkghogcpida\[ra]
.IP \(bu 2
Firefox \[la]http://www.mozilla.org/firefox\[ra] using the following workaround
.RE
.SS Firefox
.PP
The workaround for Firefox is to add this snippet to your \fB\fCprefs.js\fR file:
.PP
.RS
.nf
user_pref("capability.policy.policynames", "localfilelinks");
user_pref("capability.policy.localfilelinks.sites", "http://127.0.0.1:54321");
user_pref("capability.policy.localfilelinks.checkloaduri.enabled", "allAccess");
.fi
.RE
.PP
See \[la]http://kb.mozillazine.org/Links_to_local_pages_do_not_work\[ra] for details.
.SH ENVIRONMENT
.TP
\fB\fCDASHT_DOCSETS_DIR\fR
Expand Down
2 changes: 1 addition & 1 deletion man/man1/dasht.1
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH DASHT 1 2018\-10\-09 2.3.0
.TH DASHT 1 2020\-05\-16 2.4.0
.SH NAME
.PP
dasht \- API documentation in your terminal
Expand Down

0 comments on commit 9cd872c

Please sign in to comment.