Skip to content

Commit 0916372

Browse files
authored
[Docs] Improve the basilisp doc structure (#3703)
Co-authored-by: ikappaki <[email protected]>
1 parent 7c31f50 commit 0916372

File tree

2 files changed

+34
-23
lines changed

2 files changed

+34
-23
lines changed

doc/modules/ROOT/nav.adoc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
** xref:platforms/overview.adoc[Overview]
1515
** xref:platforms/babashka.adoc[Babashka]
1616
** xref:platforms/nbb.adoc[Nbb]
17+
** xref:platforms/basilisp.adoc[Basilisp]
1718
** xref:platforms/other_platforms.adoc[Other Platforms]
1819
* Using CIDER
1920
** xref:usage/interactive_programming.adoc[Interactive Programming]

doc/modules/ROOT/pages/platforms/basilisp.adoc

Lines changed: 33 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ since CIDER 1.14
55

66
== Overview
77

8-
Basilisp aims to enable writing Clojure programs on Python with full Python interoperability. It is highly compatible with Clojure.
8+
Basilisp aims to enable writing Clojure programs on Python with full interoperability. It is highly compatible with Clojure.
99

1010
To install Basilisp, run:
1111

@@ -15,16 +15,18 @@ To install Basilisp, run:
1515

1616
There are several ways to connect to Basilisp.
1717

18-
* kbd:[M-x cider-jack-in] and kbd:[M-5 M-x cider-jack-in-universal]
18+
=== jack-in
1919

20-
If you have created a `basilisp.edn` project file at your root of your project tree, you can jack in to the project `M-x cider-jack-in`. The `basilisp.edn` is similar to `deps.edn` for clojure-cli projects. It can be left empty just to mark the root of your project.
20+
kbd:[M-x cider-jack-in] and kbd:[M-5 M-x cider-jack-in-universal]
21+
22+
If you have created a `basilisp.edn` project file at your root of your project tree, you can jack in to the project with `M-x cider-jack-in`. The `basilisp.edn` is similar to `deps.edn` for clojure-cli projects. It can be left empty just to mark the root of your project.
2123

2224
If you don't have or want a basilisp project file, you can use universal jack in with a numerical argument of 5:
2325

2426
- kbd:[M-5 M-x cider-jack-in-universal], or
25-
- kbd:[M-5 C-c C-x j u], from within file in clojure-mode
27+
- kbd:[M-5 C-c C-x j u], from within a file in clojure-mode
2628

27-
(Note: an alternative to kbd:[M-5] is kbd:[C-u 5])
29+
NOTE: an alternative to kbd:[M-5] is kbd:[C-u 5]
2830

2931
You can also bind the universal jack-in to Basilisp to a function to use as a shortcut, for example
3032

@@ -35,7 +37,9 @@ You can also bind the universal jack-in to Basilisp to a function to use as a sh
3537
(cider-jack-in-universal 5)))
3638
----
3739

38-
* kbd:[M-x cider-connect]
40+
=== connect
41+
42+
kbd:[M-x cider-connect]
3943

4044
You can start its bundled nREPL server:
4145

@@ -47,31 +51,37 @@ To see available options, type `basilisp nrepl-server -h` in a shell prompt.
4751

4852
== Configuration
4953

50-
The jack-in command can be configured via several defcustoms:
54+
The jack-in command can be configured with the following defcustoms
55+
56+
=== `cider-basilisp-command`
5157

52-
* `cider-basilisp-command` (default is `basilisp`).
58+
(default is `basilisp`)
5359

5460
If Basilisp is installed in a virtual environment, update this to the full path of the `basilisp` executable within that virtual environment.
5561

56-
* `cider-basilisp-parameters` (default is `nrepl-server`).
62+
=== `cider-basilisp-parameters`
63+
64+
(default is `nrepl-server`)
65+
66+
=== Customization
5767

5868
There at few ways to setup (custom) variables in Emacs
5969

60-
- https://www.gnu.org/software/emacs/manual/html_node/emacs/Easy-Customization.html[Examining and Setting Variables]
70+
==== 1. https://www.gnu.org/software/emacs/manual/html_node/emacs/Easy-Customization.html[Examining and Setting Variables]
6171

62-
kbd:[C-h v cider-basilisp-command], and
63-
kbd:[C-h v cider-basilisp-parameters]
72+
- kbd:[C-h v cider-basilisp-command], and
73+
- kbd:[C-h v cider-basilisp-parameters]
6474

65-
- https://www.gnu.org/software/emacs/manual/html_node/emacs/Directory-Variables.html[Per-Diretory Local Variables]
75+
==== 2. https://www.gnu.org/software/emacs/manual/html_node/emacs/Directory-Variables.html[Per-Diretory Local Variables]
6676

6777
Uses `.dir-locals.el` to setup per mode variables. This file is typically stored at the root of the project.
6878

6979
For example, to set the path to the basilisp executable within a virtual environment
7080

71-
kbd:[M-x add-dir-local-variable]
72-
Mode or subdirectory: `clojure-mode`
73-
Add directory-local variable: `cider-basilisp-command`
74-
Add cider-basilisp-command with value: `"c:/dev/venvs/312/Scripts/basilisp"`
81+
- kbd:[M-x add-dir-local-variable]
82+
- Mode or subdirectory: `clojure-mode`
83+
- Add directory-local variable: `cider-basilisp-command`
84+
- Add cider-basilisp-command with value: `"c:/dev/venvs/312/Scripts/basilisp"`
7585

7686
This should result to updating or creating a `.dir-local.el` file like below
7787

@@ -83,15 +93,15 @@ This should result to updating or creating a `.dir-local.el` file like below
8393
((clojure-mode . ((cider-basilisp-command . "c:/dev/venvs/312/Scripts/basilisp"))))
8494
----
8595

86-
- https://www.gnu.org/software/emacs/manual/html_node/emacs/Specifying-File-Variables.html[Specifying File Variables]
96+
==== 3. https://www.gnu.org/software/emacs/manual/html_node/emacs/Specifying-File-Variables.html[Specifying File Variables]
8797

88-
It is best to put this in the top of your project's `basilisp.edn` file, and always jack-in from there
98+
It is best to put this in the top of your project's `basilisp.edn` file, and always jack-in from there.
8999

90-
For example, setting `cider-basilisp-command` to start basilisp from within a virtual environment
100+
For example, setting `cider-basilisp-command` to start basilisp from within a virtual environment:
91101

92-
kbd:[M-x add-dir-local-variable]
93-
Add file-local variable: `cider-basilisp-command`
94-
Add cider-basilisp-command with value: `"c:/dev/venvs/312/Scripts/basilisp"`
102+
- kbd:[M-x add-dir-local-variable]
103+
- Add file-local variable: `cider-basilisp-command`
104+
- Add cider-basilisp-command with value: `"c:/dev/venvs/312/Scripts/basilisp"`
95105

96106
This will result in the following in `basilisp.edn`
97107

0 commit comments

Comments
 (0)