@@ -23,40 +23,41 @@ writing web applications. This documentation will take you through
23
23
Duct's setup and operation, using a web application as an example
24
24
project.
25
25
26
- == Project Setup
26
+ == Setup
27
27
28
- You'll need to
29
- https://clojure.org/guides/install_clojure[install Clojure] before you
30
- can use Duct. This will add a `clojure` executable to your path.
28
+ This section will cover setting up a new Duct project. You'll first need
29
+ to ensure that the
30
+ https://clojure.org/guides/install_clojure[Clojure CLI is installed].
31
+ You can check this by running the `clojure` command.
31
32
32
33
[,shell]
33
34
----
34
35
$ clojure --version
35
36
Clojure CLI version 1.12.0.1479
36
37
----
37
38
38
- Next, you'll need to create a project directory. For the purposes of
39
- this example, we'll call the project `tutorial`.
39
+ Next, create a project directory. For the purposes of this example,
40
+ we'll call the project `tutorial`.
40
41
41
42
[,shell]
42
43
----
43
44
$ mkdir tutorial && cd tutorial
44
45
----
45
46
46
- The Clojure command-line tool looks for a file called `deps.edn`. To use
47
- Duct, we need to add https://github.com/duct-framework/main[Duct Main]
48
- as a dependency, and setup an alias to execute it.
47
+ The Clojure CLI looks for a file called `deps.edn`. To use Duct, we need
48
+ to add the https://github.com/duct-framework/main[Duct Main] tool as a
49
+ dependency, and setup an alias to execute it.
49
50
50
51
To achieve this, create a new `deps.edn` file with the following
51
- contents :
52
+ content :
52
53
53
54
[,clojure]
54
55
----
55
56
{:deps {org.duct-framework/main {:mvn/version "0.1.0"}}
56
57
:aliases {:duct {:main-opts ["-m" "duct.main"]}}}
57
58
----
58
59
59
- Duct can now be run by invoking the `duct` alias.
60
+ Duct can now be run by invoking the `: duct` alias.
60
61
61
62
[,shell]
62
63
----
@@ -76,16 +77,16 @@ Options:
76
77
----
77
78
78
79
We'll be using this command a lot, so it's highly recommended that you
79
- create an alias for it in your shell. In a POSIX shell such as Bash,
80
- this can be done using the `alias` command.
80
+ also create an shell alias . In a POSIX shell such as Bash, this can be
81
+ done using the `alias` command.
81
82
82
83
[,shell]
83
84
----
84
85
$ alias duct="clojure -M:duct"
85
86
----
86
87
87
- For the rest of this documentation, we'll assume that this alias has
88
- been defined.
88
+ For the rest of this documentation, we'll assume that this shell alias
89
+ has been defined.
89
90
90
91
The final step of the setup process is to create a `duct.edn` file. This
91
92
contains the data structure that defines your Duct application. The
0 commit comments