Like on macOS Catalina where you can't have directories outside your
home directory any more, so need to refer to the directory you
manually installed some software to? You can't just include the raw
~/where/ever in that PATH in the GNUmakefile because the
~ prefix won't be translated into the user's home directory.
That substitution is done by the shell when a command is executed, but
the shells expect that tilde to have been expanded in the command that
sets the path. It doesn't do “Tilde Expansion” on each part of the
PATH when it goes looking things up in the path. So, you have to get
that expansion done manually if you set it in a GNUmakefile.
This short (23 pages counting covers) introduction to the Auran Empire
and the areas around it includes:
1 page cover.
1 page title page.
1 page credits page.
An 1 page overview with short sections on purpose, culture,
religion, cosmology, monsters, magic, and ancient artifacts.
A 1⅓ page description of the various lands of the area under discussion
(which includes the lands surrounding the Auran Empire).
A ⅔ page timeline covering over 4000 years.
A 2 page map of the area.
A ⅔ page legend of map symbols.
A 3⅔ page section on Customs, covering Laws and Governance, Coins and
Money, Fashion and Dress, Slavery and Indenture [1],
Travel and Vehicles, Engineering and Construction, Knowledge and
Learning, Weapons and Warfare, Religion and Myth, Clergy and
Churches, and a table of Gods and Goddesses listing their names,
titles, spheres of influence, holy symbols, sacred animals.
An 8 page section on People, giving basic descriptions of the
various nationalities and/or ethnicities: Celdorean, Dwarven, Elven
(Argollëan), Jutlandic, Kemeshi, Krysean, Kushtu, Nicean, Opelenean,
Rornish, Shebatean, Somirean, Skysos, Thrassian, Tirenean, and
Zaharan.
A 1½ page table of languages, with their real-world
inspiration.
Finally, a 1 page back cover.
I thought this was a very good overview of a campaign setting.
I wish that the map had shown less of the north of the map where the
barbarians lived and more of the south, where there are several
countries described that are not on the map.
I liked that the nationality/ethnicity entries included descriptions
of the typical appearance, including skin color, hair color, body
shape, average height, face shape, and so forth, and that there is a
fair variety of each.
I liked that the culture section gives the real-world cultures that
inspired the game world cultures. For example, “The dominant Imperial
culture [of the Auran Empire] is closely akin to the Late Roman Empire
and Early Byzantine Empire.”
I just noticed that when wget tells you the filename of file it just
saved, if your LANG=C then it surrounds it with apostrophes ('), but
if your LANG=en_US.UTF-8 then it surrounds it with Unicode LEFT SINGLE
QUOTATION MARK (‘)and RIGHT SINGLE QUOTATION MARK (’). I appreciate
little subtleties like that.
I use Unicode characters in most of the writing I do. For LaTeX,
which I rarely use these days, I use XeTeX, which understands UTF-8
natively. ConTeXt, which I do use regularly, also understands UTF-8
natively. For groff I use the -k switch, which preprocesses the
text with preconv (which is part of groff), converting the
UTF-8 characters into groff character escapes, since groffdoesn't
understand UTF-8 natively. Of course, if it is ReStructuredText that
I'm working with then pandoc can be configured to use any one of
LaTeX, ConTeXt, and groff for creating PDF output, and since
rst2html.py just produces LaTeX that includes any
character you put in your source you can just use xelatex
as part of your commands to turn it into PDF. And sometimes, when I'm
feeling whimsical, I use Heirloom Troff, from the Heirloom
Documentation Tools, which understands UTF-8 natively.
One of the things that I like about Savage Worlds Adventure
Edition (SWADE) is that it fixed spears so that you can use them
one-handed, but only get bonus to parry if you use both hands. In
Savage Worlds Deluxe Edition (SWD) and earlier editions spears could
only be used two-handed.
Edition
Type
Damage
Notes
SWD
Spear
Str+d6
Parry +1, Reach 1, 2 hands
SWADE
Spear
Str+d6
Reach 1. Parry +1 if used two-handed
This allows the historical “Spear and Shield” combat style.
See Lindybeige for why this matters.
Maybe something similar should have been done with Staff as well,
changing it so it can be used one-handed but losing the “Parry +1” in
that case. Maybe not, since a staff depends on strength for more of
its damage than the mostly piercing spear.
I’ve found that if I write something in ReStructuredText, create HTML
from it and embed a stylesheet with the proper css in the
.html file using pandoc’s --include-in-header option that
I can cut and paste from the web page displayed in my browser from
that HTML directly into gmail, and things like code blocks and literal
text will have the nice surrounded by a box, light gray background
formatting that carries over to Gmail. That's nice because Gmail's
native formatting is a … minimalist user experience.
However, I've found that if I use the .. include:: directive with
the :code: option (which basically makes it a code block) and
specify a language for highlighting with an argument to the :code:
option that the text/html part in the resulting multipart/alternative
e-mail displays fine in Gmail (and probably other mail user agents
that display the HTML part; Mew in Emacs works too), but the
text/plain part is messed up, with weird HTML-like tags in the
plain text. [1]
For instance, suppose I have the following RST source for the message
I want to write (missing-ampersand.rst):
:title: Missing Ampersand in Code Blocks in ``-ms`` Output
Here's some ReStructuredText input that has a code block in it:
..include:: ma.rst
:code: restructuredtext
Here's the ``-ms`` output from it:
..include:: ma-rst.ms
:code: nroff
See the first line that starts with ``.. container::``? That line
should start with ``\&`` so it isn't interpreted as an **roff**command. As it is, when you build the PDF output from output that
line disappears entirely with no warning to the user. (The default
for **roff** processors like **groff** is to ignore unknown commands.)
See the second line that starts with ``.. container::``? That line
**does** start with ``\&``. It makes it through fine. The other
lines whose first non-whitespace character is ``.`` make it through
fine because to make it a **roff** command the first character on the
line has to be a period.
Missing Ampersand in Code Block -ms output
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
Here's a code block containing ReStructuredText:
..code:: ..container:: for-format ms
..figure:: davesmapper-2017-04-10-caves-4-numbered.eps
:alt: Map of Bandit's Cave
Map of Bandit's Cave
..container:: for-format html latex context epub
..figure:: davesmapper-2017-04-10-caves-4-numbered.png
:alt: Map of Bandit's Cave
Map of Bandit's Cave
How's that look?
and the included roff source file (ms-rst.ms) is
.SH1Missing Ampersand in Code Block -ms output
.pdfhrefO1"Missing Ampersand in Code Block -ms output".pdfhrefM"missing-ampersand-in-code-block--ms-output".LPHere\[aq]s a code block containing ReStructuredText:
.IP.nf\f[C]..container::for-formatms .. figure:: davesmapper-2017-04-10-caves-4-numbered.eps
:alt: Map of Bandit\[aq]s Cave
Map of Bandit\[aq]s Cave
\&.. container:: for-format html latex context epub
.. figure:: davesmapper-2017-04-10-caves-4-numbered.png
:alt: Map of Bandit\[aq]s Cave
Map of Bandit\[aq]s Cave
\f[].fi.LPHow\[aq]s that look?
Then the resulting HTML output for the first code block [2] is:
<divclass="sourceCode"id="cb1"><preclass="sourceCode restructuredtext"><codeclass="sourceCode rest"><spanid="cb1-1"><ahref="#cb1-1"></a>Missing Ampersand in Code Block -ms output</span><spanid="cb1-2"><ahref="#cb1-2"></a>@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@</span><spanid="cb1-3"><ahref="#cb1-3"></a></span><spanid="cb1-4"><ahref="#cb1-4"></a>Here's a code block containing ReStructuredText:</span><spanid="cb1-5"><ahref="#cb1-5"></a></span><spanid="cb1-6"><ahref="#cb1-6"></a><spanclass="dt">.. code::</span></span><spanid="cb1-7"><ahref="#cb1-7"></a></span><spanid="cb1-8"><ahref="#cb1-8"></a><spanclass="dt"> .. container:: for-format ms</span></span><spanid="cb1-9"><ahref="#cb1-9"></a></span><spanid="cb1-10"><ahref="#cb1-10"></a><spanclass="dt"> .. figure:: davesmapper-2017-04-10-caves-4-numbered.eps</span></span><spanid="cb1-11"><ahref="#cb1-11"></a><spanclass="dt"> :alt: Map of Bandit's Cave</span></span><spanid="cb1-12"><ahref="#cb1-12"></a></span><spanid="cb1-13"><ahref="#cb1-13"></a><spanclass="dt"> Map of Bandit's Cave</span></span><spanid="cb1-14"><ahref="#cb1-14"></a></span><spanid="cb1-15"><ahref="#cb1-15"></a><spanclass="dt"> .. container:: for-format html latex context epub</span></span><spanid="cb1-16"><ahref="#cb1-16"></a></span><spanid="cb1-17"><ahref="#cb1-17"></a><spanclass="dt"> .. figure:: davesmapper-2017-04-10-caves-4-numbered.png</span></span><spanid="cb1-18"><ahref="#cb1-18"></a><spanclass="dt"> :alt: Map of Bandit's Cave</span></span><spanid="cb1-19"><ahref="#cb1-19"></a></span><spanid="cb1-20"><ahref="#cb1-20"></a><spanclass="dt"> Map of Bandit's Cave</span></span><spanid="cb1-21"><ahref="#cb1-21"></a></span><spanid="cb1-22"><ahref="#cb1-22"></a>How's that look?</span><spanid="cb1-23"><ahref="#cb1-23"></a></span></code></pre></div>
And the HTML output for the second code block is:
<preclass="nroff"><code>.SH 1
Missing Ampersand in Code Block -ms output
.pdfhref O 1 "Missing Ampersand in Code Block -ms output".pdfhref M "missing-ampersand-in-code-block--ms-output".LP
Here\[aq]s a code block containing ReStructuredText:
.IP
.nf
\f[C]
.. container:: for-format ms
.. figure:: davesmapper-2017-04-10-caves-4-numbered.eps
:alt: Map of Bandit\[aq]s Cave
Map of Bandit\[aq]s Cave
\&.. container:: for-format html latex context epub
.. figure:: davesmapper-2017-04-10-caves-4-numbered.png
:alt: Map of Bandit\[aq]s Cave
Map of Bandit\[aq]s Cave
\f[]
.fi
.LP
How\[aq]s that look?
</code></pre>
In the first code block you see a lot of HTML spans that look like this:
<spanid="cb1-3"><ahref="#cb1-3"></a>…</span>
They appear to be anchors so you can link to a particular line in the
code block. When I displayed the HTML file in my browser (Google
Chrome), selected the text, and pasted it into the Gmail message
composition window in the message body area (except for the header
text, which I put in the Subject line text entry box instead) and it
looked fine, so I sent it.
But when I got a reply from someone who uses a mail user agent
that displays the text/plain alternative that Gmail automatically
creates the supposedly plain text was this:
--000000000000360d1105a9a4da6e
Content-Type: text/plain; charset="UTF-8"
Here's some ReStructuredText input that has a code block in it:
<#cb1-1>Missing Ampersand in Code Block -ms output
<#cb1-2>@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ <#cb1-3>
<#cb1-4>Here's a code block containing ReStructuredText: <#cb1-5>
<#cb1-6>.. code:: <#cb1-7> <#cb1-8> .. container:: for-format ms
<#cb1-9> <#cb1-10> .. figure::
davesmapper-2017-04-10-caves-4-numbered.eps <#cb1-11> :alt:
Map of Bandit's Cave <#cb1-12> <#cb1-13> Map of Bandit's Cave
<#cb1-14> <#cb1-15> .. container:: for-format html latex context
epub <#cb1-16> <#cb1-17> .. figure::
davesmapper-2017-04-10-caves-4-numbered.png <#cb1-18> :alt:
Map of Bandit's Cave <#cb1-19> <#cb1-20> Map of Bandit's Cave
<#cb1-21> <#cb1-22>How's that look? <#cb1-23>
Here's the -ms output from it:
.SH 1
Missing Ampersand in Code Block -ms output
.pdfhref O 1 "Missing Ampersand in Code Block -ms output"
.pdfhref M "missing-ampersand-in-code-block--ms-output"
.LP
Here\[aq]s a code block containing ReStructuredText:
.IP
.nf
\f[C]
.. container:: for-format ms
.. figure:: davesmapper-2017-04-10-caves-4-numbered.eps
:alt: Map of Bandit\[aq]s Cave
Map of Bandit\[aq]s Cave
\&.. container:: for-format html latex context epub
.. figure:: davesmapper-2017-04-10-caves-4-numbered.png
:alt: Map of Bandit\[aq]s Cave
Map of Bandit\[aq]s Cave
\f[]
.fi
.LP
How\[aq]s that look?
See the first line that starts with .. container::? That line should start
with \& so it isn't interpreted as an *roff* command. As it is, when you
build the PDF output from output that line disappears entirely with no
warning to the user. (The default for *roff* processors like *groff* is to
ignore unknown commands.)
See the second line that starts with .. container::? That line *does* start
with \&. It makes it through fine. The other lines whose first
non-whitespace character is . make it through fine because to make it a
*roff* command the first character on the line has to be a period.
--
T. Kurt Bond, tkurtbond@gmail.com
--000000000000360d1105a9a4da6e
See the weird psuedo-HTML tags like <#cb1-3> in the “plain” text
that seems to have resulted from <span id="cb1-3"><ahref="#cb1-3"></a>…</span>? The person who replied to my message
used the text/plain, and that included all those weird
<#cbX-Y> tags in the plain text reply, which, although they didn't
remark on the oddity, is how I came to know about the problem.
So, one thing to notice is that it was the first code block that was
messed up, and not the second. It turns out that I specified a
(correct) language for syntax highlighting in the first code block,
restructuredtext, and supplied an incorrect language for syntax
highlighting in the second block, nroff[3], which
should have been simply roff. And it turns out that if I don't
specify a language for the highlighting I don't get the <span
id="cb1-3"><ahref="#cb1-3"></a></span> type output, just a plain
<code> block in a plain <pre> block.
Weird.
(I suppose I could have made this entry shorter and easier to
understand by writing new shorter examples directly using
.. code:: directly, but I'm writing about an e-mail that I
actually sent, not a hypothetical e-mail.)
From an article originally from Space Gamer #76, republished on
Medium for the 35th Anniversary of Man to Man, the GURPS combat
system:
What am I trying to accomplish with MTM and GURPS? In a nutshell,
I’m trying to establish a game system simple enough for beginners,
detailed enough for experts, flexible enough for everybody — and
infinitely variable to fit the infinite worlds of fact and
fiction. I’m hoping to establish a new tournament standard.
And so far, I’m happy with it. Pick it up, and let me know what
you think.
Are you familiar with arrow macros? (They have nothing to do with
arrows in Haskell.) They started out in Clojure, I think, and have
been ported to Common Lisp and probably other Lisps, though I didn't
find one for Emacs Lisp. I think the arrows package is the most up
to date in Quicklisp for Common Lisp, but I found the cl-arrows
package first so that's the one I converted to Emacs Lisp today.
There were two slightly tricky parts to the port
I needed to use lexical binding for the source file
Anyway, I think they're very useful. If you have a value and
you want it to be processed by several functions in a chain you
can use an arrow macro instead of using lots of nested function
calls. For instance,
that's also pretty horrible. To read it you have to skip to the end,
figure out that function call, then skip back to the next function
call, and so forth, until you get back to the last function call,
reading it from inside out. It looks much better if you use the
->> arrow macro, which substitutes the value you are passing along
as the last argument to the functions you are calling:
I also think it is more understandable than the highly nested calls,
since you can follow along in from start to finish, rather than from
inside out: you've got the value, you pass it to the first function,
then to the second, and so forth.
There are also macros to insert the value at the front of the argument
list (->) and to insert the value where a <> symbol is found
(-<>).
I wrote some Emacs Lisp code with the last expression above today, and
I think it makes a good example of why they are useful.
Here's the use case that inspired me to port them to Emacs
Lisp. When I save things from the internet I often want to
create a directory to save them in based on the filename or
some text on a web page or something, but usually there are
spaces or special characters in that text, so I have to
sanitize the text to make it a safe and simple filename. So I
need to replace all special characters with dashes. But I
don't want dashes repeated multiple times, just a single dash,
and I don't want dashes followed or preceded by periods, only
the period.
Here' s some code to do that:
(defuntkb-sanitize-for-filename(string)"Clean up characters in STRING that aren't good forfilenames."(->>string(replace-regexp-in-string"[^-.a-z0-9]+""-")(replace-regexp-in-string"-+""-")(replace-regexp-in-string"-\\."".")(replace-regexp-in-string"\\.-"".")(replace-regexp-in-string"\\.+"".")(replace-regexp-in-string"^-+""")(replace-regexp-in-string"-+$""")))(defuntkb-sanitize-kill-for-filename(string)"Clean up characters that aren't good for filenames in thetop of the killring and put the result on the top of the kill ring.";; gets the kill or the system clipboard if it is new.(interactive(list(current-kill0t)))(let((new-string(tkb-sanitize-for-filenamestring)))(message"Old string: %s\nNew String: %s"stringnew-string)(kill-newnew-string)))(global-set-key(kbd"C-c k S")'tkb-sanitize-kill-for-filename)
Note that the function tkb-sanitize-kill-for-filename that I use
interactively gets uses (current-kill 0 t) because it either
returns the top of the kill ring, or if the system clipboard is newer
it puts that on top of the kill ring and returns it. (The docstring
of current-kill makes that a little difficult to figure out.)
So if I have the name of a product as
"***Flashy####Product%%%%Name!!!!" I copy that to the clipboard
with ⌘-C, switch to emacs, do C-c k S, switch back to
whatever program is saving the file, and use the generated,
sanitized name Flashy-Product-Name with ⌘-V. Nifty!
(And if you've ever wondered what the Unicode character for the Mac
keyboard Command key (⌘) is, it is the PLACE OF INTEREST SIGN, and
you can enter it in Emacs by C-x 8 RETURN PLACE OF
INTEREST SIGN⏎. The symbol they use for for the key labeled alt and
option (⌥) is the Unicode OPTION KEY, and the symbol they use for
the Shift Key (⇧) is UPWARDS WHITE ARROW. I'm surprised they
don't have a special symbol for Control, but it looks like they just
use the plain ASCII ^, known in Unicode as CIRCUMFLEX ACCENT.)
Anyway, here's a ZIP file with the Emacs Lisp source for the arrow
macros so you can use them if you've been convinced of their
usefulness by this post. It also has some minimal documentation in
the README.md that came from the README.md from
cl-arrows, which seems to repeat the information from the
docstrings for the macros.
I created a .epub file using pandoc. Then I converted the
.epub to .mobi via the Calibre epub
software. [1] Then I tried copying the .mobi to
the Documents folder on the Kindle via USB (which several
places online say is the way to do it) but that didn’t show up when I
looked (and searched) my library.
So I had to mail it to my Kindle.
Go on Amazon,
select “Account & Lists > Your Content and Devices > Preferences tab (at the top of the
page, under the normal black Amazon menu/search area) > Personal
Document Settings”.
Then copy the email from your “Send-To-Kindle
E-Mail Settings” and create an e-mail to it.
Check that the “Approved
Personal Document E-mail List” contains your e-mail address, or add a
new one.
Then attach the .mobi file to the e-mail and send it.
After a little while you’ll get a “Verify your Kindle document” from Amazon
with a link to click to verify it. Click it.
After a little while you can go
back to the “Content” tab and search your content for the title, and
it should be there. You can also change the “Show” combo box at the
top of the page to “Docs” instead of “Books” and it should be listed
there, too.
GURPS (G1, G2) from Steve Jackson Games is a Generic Universal
RolePlaying System. The meaning of the separate words, paraphrased
from the introductions of the GURPS, 3rd Edition, and GURPS 4th
Edition, breaks down the meaning as follows:
Generic — Scaling from quick, fast-moving games with simple
rules to games with lots of detail.
Universal — a set of rules that's comprehensive enough to let
you use with any background/setting and potentially to combine characters
from different backgrounds/settings and have them be compatible.
RolePlaying — designed to encourage true roleplaying
System — designed as a unified whole rather than starting out as
a set of simple rules and modified in an ad-hoc manner.
The Wikipedia article Generic role-playing game system's idea of
a generic RPG seems to combine the GURPS notions of “Generic” and
“Universal”. Or maybe it means by “Generic” what GURPS means by
“Universal”.
Ideally, we would like allow the AIO mechanism to include
additional ASDF systems in the single jar artifact.
Currently one can hack this together by:
Manually extracting the abcl-aio.jar artifact to a file-system.
Placing the necessary ASDF systems in the resulting “contrib”
directory.
Recreating the single archive from the file-system
contents.
About
Lacking Natural Simplicity is one, not particularly flattering,
definition of sophisticated.
This blog chronicles my journey through our at times too complicated
and sophisticated world.
This site uses no cookies directly, but I expect the Disqus comments use cookies at disqus.com.