| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
This fixes a number of issues with addurimethod.
- Use cat in the absence of PAGER
- Avoid unwanted : in scheme and dropped ? from from cgi
- Allow replacing previously defined schemes
- Rework num_spaces computation based on bptato's suggestion
|
| |
|
|
|
|
| |
yeah
|
|
|
|
|
| |
I think it works well enough at this point.
If it doesn't, somebody will complain :)
|
|
|
|
| |
Actually, it may be fine to leave it out for now.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
| |
The issue with brotli was that we were calling toOpenArray with a
uint, and that doesn't really work in Nim (even though it looks like
it does).
So I've removed the circular buffer from brotli and made oqoff an int
for tinfl (which unlike brotli actually needs a circular buffer).
|
| |
|
|
|
|
|
| |
Others don't support them either. (Firefox claims to, but only really
decodes Server-Timing for debugging.)
|
|
|
|
| |
Now it only does HTTP/1.1, with Connection: close.
|
|
|
|
| |
not much else is done yet, but it's a start
|
|
|
|
|
|
|
| |
It isn't really limited to config. It just happens to be in
XDG_CONFIG_HOME because XDG basedirs suck.
(W3M_DIR works similarly.)
|
| |
|
| |
|
|
|
|
|
|
|
|
|
| |
* make it so 'echo "$var\n" | urlenc' works as expected
* add special query encode set
* set default encode set to form data
* document encode sets in help message
also, remove a redundant percentEncode implementation from gopher2html
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I'm starting to favor dotfiles over XDG basedirs, but there's no reason
why we couldn't have both. So now the search path is:
0. if config was set through -C, use that
1. $CHA_CONFIG_DIR is set -> $CHA_CONFIG_DIR/config.toml
2. $XDG_CONFIG_HOME is set -> $XDG_CONFIG_HOME/chawan/config.toml
3. ~/.config/chawan/config.toml exists -> use that
4. ~/.chawan/config.toml exists -> use that
Notably, this makes it so the default directory is ~/.chawan *if* you
don't have an existing config.toml file. So in that case known_hosts
will be placed in ~/.chawan/known_hosts. However, configurations with a
config in ~/.config/chawan/config.toml continue to work as expected, as
for those the known_hosts file remains inside ~/.config/chawan/.
Finally, I've added a default user CGI directory to reduce friction in
setting CGI up. (Like known_hosts, it's also relative to whatever config
dir you have.)
|
|
|
|
|
|
|
|
|
| |
Simple netcat clone, useful for portable scripts. Especially because
some netcats will close the connection as soon as I close stdin... this
one only quits when either stdout or the socket refuses new data.
Also, it uses our standard TCP connection routine, meaning it respects
ALL_PROXY. (i.e. now spartan works with socks5 too)
|
|
|
|
|
|
|
|
| |
since that's our input color space
(Actually, mainstream browsers seem to use linear scaling nevertheless.
But apparently that produces surprising results in some cases, and stbir
can do srgb, so might as well use it.)
|
| |
|
|
|
|
|
|
| |
* encode path URLs
* accept directories without trailing slash
* sort file names
|
|
|
|
| |
see header for usage
|
| |
|
|
|
|
|
|
|
| |
* highlight shortened commit hashes (up to 7 chars)
* send status
* refactor cgi commands
* support git branch -a
|
| |
|
|
|
|
| |
it's safer this way
|
|
|
|
|
|
|
|
|
| |
* gitcha stash list special processing
* gitcha switch no longer opens the branch view; it is now opened by
gitcha branch
* make gitcha branch UI consistent with the rest of the script. (the
idea is that clicking on refs does not modify the repo, only action
links like (switch) or (apply).)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The previous solution had the issue that it switched between "delete
buffer, then move back" and "delete buffer, then move forward" depending
on whether the buffer was the root of the buffer tree, which made its
behavior quite unpredictable.
Now the pager (sort of) remembers the direction you are coming from,
and D moves in that direction. So e.g.:
* Enter, D just moves back to where you were coming from (as before)
* Comma, D deletes the previous buffer, then returns to the current
buffer
If no buffer exists in the target direction, then we alert.
Also, new commands are: `d,' `d.'. They do the same thing the
non-d-prefixed variations do, but also delete the current buffer. Useful
if you're no longer sure where you are coming from, but know where you
want to go. (`d,' in particular is equivalent to w3m's `B'.)
|
|
|
|
|
|
|
| |
Use content type attributes so e.g. git.cgi can set the title even with
a text/x-ansi content type.
(This commit also fixes some bugs in content type attribute handling.)
|
|
|
|
| |
Array.prototype.at is not present in previous QJS releases.
|
|
|
|
| |
as described in <https://todo.sr.ht/~bptato/chawan/6>
|
| |
|
|
|
|
| |
just a clickable UI for switching branches
|
|
|
|
|
| |
this way its output can be embedded into documents without a pointless
DT declaration
|
| |
|
|
|
|
| |
just for clickable git log hashes
|
| |
|
|
|
|
|
|
| |
only for source for now, rendered document is a bit more complicated
(also, get rid of useless extern/editor module)
|
|
|
|
| |
this is more or less how it works in w3m
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Add functions for moving to the beginning/end of words (vi `b', `e').
* As it turns out, there are many possible interpretations of what a
word is. Now we have a function for each reasonable interpretation,
and the default settings match those of vi (and w3m in w3m.toml).
(Exception: it's still broken on line boundaries... TODO)
* Remove `bounds` from lineedit, it was horrible API design and mostly
useless. In the future, an API similar to what pager now has could
be added.
* Update docs, and fix some spacing issues with symbols in the tables.
|
|
|
|
|
|
|
| |
strncat does not work like that :P
Luckily, BSD has strlcat which does.
(While we're at it, remove the unused PDIE macro.)
|
|
|
|
|
|
|
|
|
|
| |
* Fix incorrect internal definition of the fragment percent-encode set
* urlenc, urldec: these are simple utility programs mainly for use
with shell local CGI scripts. (Sadly the printf + xargs solution is
not portable.)
* Pass libexec directory as an env var to local CGI scripts
* Update trans.cgi to use urldec and add an example for combining
it with selections
|
|
|
|
|
|
|
| |
It has roughly zero utility, but maybe it's a good demonstration
of local CGI?
(TODO: add libfetch FTP too, that might actually be useful.)
|
| |
|
|
|
|
|
| |
No need to leave gemini support in the bonus folder.
Still TODO: proxy support.
|
|
|
|
|
|
| |
* Add a default urimethodmap that points finger: to cha-finger
* Install cha-finger to /usr/local/libexec/cha/cgi-bin by default
* cha-finger: use ALL_PROXY if given, die if curl is not installed
|