Skip to content

Commit 0092464

Browse files
committed
Add installation section
1 parent da6a2be commit 0092464

File tree

2 files changed

+23
-8
lines changed

2 files changed

+23
-8
lines changed

Makefile

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,14 @@ check:
88
cargo check
99

1010
build: target/debug/repost
11+
release: target/release/repost
1112

1213
target/debug/repost: Cargo.toml $(RS_FILES)
1314
cargo build
1415

16+
target/release/repost: Cargo.toml $(RS_FILES)
17+
cargo build --release
18+
1519
fmt: $(RS_FILES)
1620
cargo fmt
1721

README.md

Lines changed: 19 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,18 @@ will have access to request specific commands.
3838
Another important thing to know is input options are denoted by
3939
`{name}` and can be anywhere in the url, headers, or body.
4040

41-
### Quick start
41+
## Installation
42+
Currently the only way to install this is to build from source and
43+
run the executable. You will need the Rust build tools (specifically
44+
`cargo`).
45+
46+
```
47+
» git clone https://github.com/mcastorina/repost && cd repost
48+
» make release
49+
» ls -l ./target/release/repost
50+
```
51+
52+
## Quick start
4253
This section shows how to create a request, define variables, and
4354
add extractors.
4455

@@ -57,7 +68,7 @@ or `$HOME/.repost/$WORKSPACE_NAME.db`.
5768
**Note:** If you forget what command does what, use `help` or `--help`
5869
for more information about the available commands and flags.
5970

60-
#### Setting a workspace
71+
### Setting a workspace
6172
Your current workspace is where all of your data will be saved.
6273
Repost starts with the default workspace: `repost`, but we can
6374
change that using `set workspace <workspace_name>`.
@@ -79,7 +90,7 @@ To show the available workspaces, use `show workspaces`.
7990
+-----------+
8091
```
8192

82-
#### Create a request
93+
### Create a request
8394
The minimum request has a name and a URL. Headers can be added with
8495
`-H` and a body with `-d`. If the argument to `-d` starts with `@`,
8596
repost will try to find the file to use as its body. Use `{option-name}`
@@ -119,7 +130,7 @@ our current request and view the `info`.
119130
120131
```
121132

122-
#### Set options
133+
### Set options
123134
From the request state, we can use `set option` to set the value for the request.
124135

125136
```
@@ -152,7 +163,7 @@ Here we see the current value, and the planned requests if we were
152163
to run it. You may set multiple values for the same input option by
153164
providing more values on the command line.
154165

155-
#### Run a request
166+
### Run a request
156167
There are two ways to run a request. If you are in a request state, simply using
157168
`run` will execute the current request. The other way is to specify the request
158169
name to run.
@@ -184,7 +195,7 @@ name to run.
184195
}
185196
```
186197

187-
#### Define a variable
198+
### Define a variable
188199
Variables are environment specific, and should generally match your
189200
request's input options. When you are in an environment, the value
190201
of the variable will automatically be populated in the input option.
@@ -215,7 +226,7 @@ Now we can set an environment using `set environment`. Additionally,
215226
Note that when we set the environment, our input option gets updated
216227
to the value of the variable.
217228

218-
#### Add extractors
229+
### Add extractors
219230
Extractors may be added in the request state. The command `extract`
220231
is used to add it as an output option to the request. Extractors will
221232
try to capture a certain part of a request and save it to a variable.
@@ -227,7 +238,7 @@ or `header` to denote which part of the response to extract from.
227238

228239
Currently, only JSON extraction is supported.
229240

230-
##### JSON query expression
241+
#### JSON query expression
231242
The simplified language is `.` separated sub-fields and `[]` for
232243
accessing arrays. The value inside `[]` must be an integer OR `*`
233244
meaning all array objects.

0 commit comments

Comments
 (0)