Commit Graph

6594 Commits

Author SHA1 Message Date
Qi Xiao
746ac02842 pkg/elvdoc: Support file-level block. 2024-03-22 17:21:56 +00:00
Qi Xiao
bf2eb50ba8 pkg/elvdoc: Move support of "doc:id" into website/cmd/md2html.
Also change the spelling to "doc:html-id" as this is only relevant for HTML outputs.
2024-03-22 15:06:19 +00:00
Qi Xiao
204bf524a7 pkg/elvdoc: Move directives to the top of comment blocks.
Also support unknown directives.
2024-03-22 14:55:02 +00:00
Qi Xiao
64efe7305e Implement completer for "del".
This fixes #1774.
2024-03-22 13:59:58 +00:00
Qi Xiao
b0a1305db1 Trivial cleanups. 2024-03-22 11:20:35 +00:00
Qi Xiao
dfe675a0b4 Fixup for #1769.
- Convert the test to a transcript test.

- Rename the variable to $before-exit and add elvdoc.

- Add TODO about how EvalCfg should always be passed in future.
2024-03-20 15:20:34 +00:00
anb
5138df0b98 trivial wording fix 2024-03-19 15:35:18 +00:00
anb
7c0daa1359 allow user to customize pre-exit hook
It is useful when user wants to clean up things that associated with
shell session.

Provide a CallHook internal API for the common usage.
2024-03-19 15:35:18 +00:00
Qi Xiao
490c8da992 Add math:atan2.
This fixes #1773.
2024-03-19 14:49:30 +00:00
Qi Xiao
8337798663 website: Fix broken relative link. 2024-03-14 23:54:19 +00:00
Qi Xiao
485617c347 website: Minor edits to the quick tour. 2024-03-14 21:52:02 +00:00
Qi Xiao
48250aaf10 website: New series of articles: Beginner's Guide to Elvish.
This series replaces the unfinished "fundamentals" article.
2024-03-14 21:52:02 +00:00
Qi Xiao
1bca28f24e website: Document the Alt-* keys in readline-binding. 2024-03-14 18:36:30 +00:00
Qi Xiao
eadae7fc65 Add GitHub issue templates. 2024-03-10 13:33:56 +00:00
Qi Xiao
62d69b4fa2 Add a summary of Go's CoC. 2024-03-09 12:34:19 +00:00
Qi Xiao
f24c33cbe0 Add code of conduct. 2024-03-09 12:18:36 +00:00
Qi Xiao
f5f23706b4 website: Style tweaks.
- Fix the article list bullet in dark mode.

- Don't underline anchor links.
2024-03-06 18:58:24 +00:00
Qi Xiao
f2e756bf0e website: Fix canonical link for article pages. 2024-03-05 11:12:22 +00:00
Qi Xiao
aede17602e website: More style tweaks.
- Give even rows on article lists a gray background too, a bit ligher than the odd rows.

- Put icon codepoints in CSS variables.

- Draw article list bullets with pure CSS, and use square bullets for every other article list.
2024-03-04 20:29:49 +00:00
Qi Xiao
6dcf93ccaf website: Use sentence case for most article titles. 2024-03-04 19:41:49 +00:00
Qi Xiao
f30bdb5260 website: Recreate the bullets of article lists with pseudo elements. 2024-03-04 18:23:55 +00:00
Qi Xiao
5e5ba7b52d pkg/eval: Use atomic.Bool for Port.readerGone. 2024-03-04 15:58:44 +00:00
Qi Xiao
b96d044a43 pkg/md: Update for CommonMark 0.31.2.
- Add <search> as supported HTML block tag

- Update definition of Unicode punctuation
2024-03-04 14:49:24 +00:00
Qi Xiao
b6703e491c README: Use white logos for chat room badges. 2024-03-04 12:34:32 +00:00
Qi Xiao
ac7086f6a5 README: Update intro paragraphs. 2024-03-04 12:31:49 +00:00
Qi Xiao
67de7dcb61 Add Discord badge to README, and rearrange the orders. 2024-03-04 12:28:52 +00:00
Qi Xiao
2e308aba77 website: Add link to Discord guild. 2024-03-04 12:13:46 +00:00
Qi Xiao
1d81066513 website: Link to other pages from scripting case study. 2024-02-29 14:49:19 +00:00
Qi Xiao
6f15decd3b website: Expand the scripting case study doc slightly. 2024-02-29 14:35:25 +00:00
Qi Xiao
b3d9ef57aa Spell the Docker GitHub Actions workflow with a capital D. 2024-02-29 10:28:54 +00:00
Qi Xiao
2563b2316f Build Docker images and push to ghcr.io.
Also slim down the Dockerfile to only include Elvish.
2024-02-29 10:24:11 +00:00
Qi Xiao
b39e9212cc website/get: Support selecting TUNA's mirror.
Also document TUNA's mirror in all-binaries.md.
2024-02-29 09:40:55 +00:00
Qi Xiao
c806b38b19 website: Show underline when hovering over links. 2024-02-28 20:02:37 +00:00
Qi Xiao
5b5bd9a0db website: Use "list-style: none" for article lists.
For some reason "list-style: inside" doesn't play well with flexboxes on Chrome
or Firefox.
2024-02-28 19:03:31 +00:00
Qi Xiao
3fe6d66168 website: Add fallback content when JavaScript is disabled. 2024-02-28 18:40:22 +00:00
Qi Xiao
18f3e72981 website: Style tweaks.
- Give <h[123]> a margin-bottom equal to <p> and a larger margin-top.

  This sets them apart from the previous section but not the section they are
  leading.

- Give the article list on category index pages alternating backgrounds, and
  remove the on-hover background color.

- Various minor tweaks.
2024-02-28 18:32:40 +00:00
Qi Xiao
00ff7c4a62 website: Fix the style of /get in dark mode. 2024-02-28 16:26:41 +00:00
Qi Xiao
01649f8fb1 website: Update .gitignore and add ttyshot files back. 2024-02-28 16:15:03 +00:00
Qi Xiao
fec87dde0a website: Run "go mod tidy". 2024-02-28 16:13:04 +00:00
Qi Xiao
6890e7177b website: Revamp /get.
- Make the homepage an interactive page to generate an installation script.

- Move the other content into their individual pages.

  - Add Repology badges for all individual package managers.
2024-02-28 16:11:19 +00:00
Qi Xiao
1412473b4a website: Revamp homepage, site-wide styles and ttyshots.
- Homepage revamp:

  - Rewrite the homepage in a linear format of sections, with every other
    section styled with full-width gray background.

  - The first section is a short intro, with big buttons for "download" and
    "learn".

  - Create a new "case studies" page to house the explainers for the examples.

- Site-wide styles:

  - Restyle code blocks and ttyshots, using a more subtle gray border box
    instead of gray background.

  - Support headers for code blocks and ttyshots, in a style that vaguely
    resembles title bars of desktop windows. In Markdown sources, additional
    content after the language tag becomes the header.

  - Reorganize the global stylesheet and template, including using 2 spaces for
    indentation and putting dark mode color rules next to the light mode rules.

  - Change debug hotkey to toggle dark mode to Shift-D.

- Ttyshots:

  - Handle trailing spaces in more places in the ttyshot tool - there seems to
    be more of them in the latest tmux version.

  - Base the ttyshot tool's parser on pkg/transcript.

  - Support per-ttyshot cols and rows.

  - Rename x.elvts and x.ttyshot.html to x-ttyshot.elvts and x-ttyshot.html.

  - Change the syntax from "@ttyshot filename" to code block with a special
   "ttyshot" language tag to work better with the header syntax.
2024-02-26 18:23:16 +00:00
Qi Xiao
d5553b1176 Bump dependency versions. 2024-02-26 17:38:04 +00:00
Qi Xiao
9d2c6d9217 Deprecate implicit cd.
This addresses #1099.

Also link to location mode from the elvdoc of cd (originally part of #1764).
2024-02-26 17:33:18 +00:00
Qi Xiao
deec3c06b2 tools/buildall.elv: Fix bin name in archive to "elvish" or "elvish.exe".
Fixing the filename makes it slightly simpler to install Elvish from the
official binary archives.
2024-02-26 15:46:54 +00:00
Qi Xiao
4f822ab654 New md: module. 2024-02-26 10:40:24 +00:00
Qi Xiao
175b835bbd edit:kill-{left right}-alnum-word -> edit:kill-alnum-word-{left right}.
This fixes #1768.
2024-02-24 10:23:03 +00:00
Qi Xiao
78bca90019 tools: Remove buildall.sh now that buildall.elv seems to be working. 2024-02-22 17:53:31 +00:00
Qi Xiao
7b7462f02c tools/buildall.elv: Remove code for passing -buildmode=pie.
The code for passing -buildmode=pie in buildall.sh didn't actually work -
"go env GOOS GOARCH" outputs two lines, while the grep pattern expects one line.

The buildall.elv script implements this correctly, and as a result this exposes
the fact that passing -buildmode=pie requires some extra work for
reproducibility - among other things, it causes the binaries to be dynamically
linked.

Just disable it for now to get reproducibility. We're not losing anything as
that was the (unintended) old behavior of buildall.sh anyway.
2024-02-22 17:34:19 +00:00
Qi Xiao
4a2880c69d Only check binary checksums in GitHub Actions and Cirrus CI scripts.
The archives depend on the tools used to create them and are not exactly
reproducible.
2024-02-22 16:32:19 +00:00
Qi Xiao
9509111fa9 Fix invocation of buildall.elv in GitHub Actions and Cirrus CI scripts.
The first argument should point to a Go package.

Also change the pattern for sha256sum files to include all files ending in
.sha256sum, now that the archives have also been made reproducible.
2024-02-22 16:25:46 +00:00