10 Commits
Author SHA1 Message Date
david parsons 5396375eca it's not an email address if it starts with a '@' 2024-02-06 21:26:16 -08:00
david parsons 376656c77c the behavior of tags-starting-with-alpha-/-! was not like that of the reference implementation; fixed (in a very script-kiddy leaky fashion which I can't resolve with a runtime flag thanks to the 32 bit flags field in the 2.x series :-( 2022-10-04 11:49:20 -07:00
david parsons f00ae83c99 Change the autolink prefix to closer fit to the reference dingus; if a <url> has a known protocol prefix, it does not need a leading // after the prefix. 2010-11-09 15:57:21 -08:00
David Parsons 3aa4343255 Rework all of the test cases so they use tests/functions.sh,
which gives me the ability to do verbose and nonverbose test
suite running (`VERBOSE=1 make test` is the traditional output
now, and `make test` just gives pass/fail on each .t file)
2010-02-11 23:13:29 -08:00
David Parsons ebdd489ed7 1. Fix a bug in generate.c where MKD_NO_EXT was not being handled.
2. Add -fext to the options for the markdown program
3. `try`ify a bunch more of the test cases.
2009-06-17 14:30:43 -07:00
David Parsons 46f934d147 Revise a whole bunch of test cases to use my try function.
Find and fix a bug where a url with an embedded double quote
 is printed out with that doublequote in plaintext.
2009-06-17 11:39:55 -07:00
David Parsons fd212c1c30 1. When testing, use my own tool cols instead of cut (cut doesn't
exist on plan9) and `grep` (with appropriate backslashing) instead
   of `fgrep` (`fgrep` doesn't exist on plan9) or `grep -F` (`-F` option
   doesn't exist on plan9?)
2. move the source for `echo` and `cols` into the new `tools` directory.
2009-06-14 10:23:28 -07:00
David Parsons 61f2d30154 In the mail address validator, FAIL if the first character in the domain
is a `.`, and don't count a trailing `.` as a valid-for-domain `.`
2009-06-13 22:16:11 -07:00
David Parsons db3d3eef44 Rework some of the logic for figuring out if an automatic
link is a mail address, then tuck that logic into a separate
function.   Also make a (failed) stab at the horrible syntax
for `[links](with'comment-like urls)`
2009-06-13 15:32:04 -07:00
David Parsons 3671ed6994 1. Rework maybe_tag_or_link() into three functions; maybe_tag_or_link()
is for `<`automatic links`>`, the new function `maybe_autolink()` is
   for reddit-style inline autolinks, and the new function
   `process_possible_link()` handles the formatting of the token picked
    up by `maybe_tag_or_link()` or `maybe_autolink()`.

2. Fix a bug in `ishdr()` so that it won't pick up a line containing
   a single `#` and emit it as a `<h0>`.

3. Modify the behavior of backslash escaping in `parenthetical()` so
   that all punctuation can be escaped.
2009-06-12 23:26:11 -07:00