@@ -74,7 +74,7 @@ For the Linux binary on WSL2, you can use the same command as for Linux.
74
74
### Install xk6
75
75
76
76
``` bash
77
- $ go install go.k6.io/xk6/cmd/xk6@latest
77
+ go install go.k6.io/xk6/cmd/xk6@latest
78
78
```
79
79
80
80
This will install the ` xk6 ` binary in your ` $GOPATH/bin ` directory.
@@ -100,7 +100,7 @@ As usual with `go` command, the `xk6` command will pass the `GOOS`, `GOARCH`, an
100
100
Syntax:
101
101
102
102
```
103
- $ xk6 build [<k6_version>]
103
+ xk6 build [<k6_version>]
104
104
[--output <file>]
105
105
[--with <module[@version][=replacement]>...]
106
106
[--replace <module=replacement>...]
@@ -115,29 +115,29 @@ $ xk6 build [<k6_version>]
115
115
Examples:
116
116
117
117
``` bash
118
- $ xk6 build \
118
+ xk6 build \
119
119
--with github.com/grafana/xk6-browser
120
120
121
- $ xk6 build v0.35.0 \
121
+ xk6 build v0.35.0 \
122
122
--with github.com/grafana/
[email protected]
123
123
124
- $ xk6 build \
124
+ xk6 build \
125
125
--with github.com/grafana/xk6-browser=../../my-fork
126
126
127
- $ xk6 build \
127
+ xk6 build \
128
128
--with github.com/grafana/xk6-browser=.
129
129
130
- $ xk6 build \
130
+ xk6 build \
131
131
--with github.com/grafana/
[email protected] =../../my-fork
132
132
133
133
# Build using a k6 fork repository. Note that a version is required if
134
134
# XK6_K6_REPO is a URI.
135
- $ XK6_K6_REPO=github.com/example/k6 xk6 build master \
135
+ XK6_K6_REPO=github.com/example/k6 xk6 build master \
136
136
--with github.com/grafana/xk6-browser
137
137
138
138
# Build using a k6 fork repository from a local path. The version must be omitted
139
139
# and the path must be absolute.
140
- $ XK6_K6_REPO=" $PWD /../../k6" xk6 build \
140
+ XK6_K6_REPO=" $PWD /../../k6" xk6 build \
141
141
--with github.com/grafana/xk6-browser
142
142
```
143
143
@@ -154,15 +154,15 @@ Also note that because of the way xk6 works, vendored dependencies (the vendor d
154
154
Syntax:
155
155
156
156
```
157
- $ xk6 <args...>
157
+ xk6 <args...>
158
158
```
159
159
- ` <args...> ` are passed through to the ` k6 ` command.
160
160
161
161
For example:
162
162
163
163
``` bash
164
- $ xk6 version
165
- $ xk6 run -u 10 -d 10s test.js
164
+ xk6 version
165
+ xk6 run -u 10 -d 10s test.js
166
166
```
167
167
168
168
The race detector can be enabled by setting the env variable ` XK6_RACE_DETECTOR=1 ` or through the ` XK6_BUILD_FLAGS ` env variable.
0 commit comments