You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+30-13Lines changed: 30 additions & 13 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,24 +10,19 @@ pb is the command line interface for [Parseable Server](https://github.com/parse
10
10
11
11
pb is available as a single, self contained binary for Mac, Linux, and Windows. You can download the latest version from the [releases page](https://github.com/parseablehq/pb/releases/latest).
12
12
13
-
To install pb, download the binary for your platform and place it in your `$PATH`. For example, on Linux:
To install pb, download the binary for your platform, un-tar the binary and place it in your `$PATH`.
19
14
20
15
## Usage
21
16
22
17
pb is configured with `demo` profile as the default. This means you can directly start using pb against the [demo Parseable Server](https://demo.parseable.io). For example, to query:
23
18
24
19
```bash
25
-
pb query -i
20
+
pb query -i
26
21
```
27
22
28
23
### Profiles
29
24
30
-
To start using pb against your Parseable server, you need to create a profile (a profile is a set of credentials for a Parseable Server instance). You can create a profile using the `pb profile create` command. For example:
25
+
To start using pb against your Parseable server, create a profile (a profile is a set of credentials for a Parseable Server instance). You can create a profile using the `pb profile create` command. For example:
31
26
32
27
```bash
33
28
pb profile add local http://localhost:8000 admin admin
@@ -43,12 +38,14 @@ pb profile default local
43
38
44
39
### Query
45
40
41
+
Query can be run in plaintext or interactive mode. Plaintext emits simple json data to stdout. Interactive mode opens a TUI based interface to view the data.
42
+
46
43
#### Plaintext output
47
44
48
45
By default `pb` sends json data to stdout.
49
46
50
47
```bash
51
-
pb query "select * from backend" --from=10m --to=now
48
+
pb query "select * from backend" --from=1m --to=now
52
49
```
53
50
54
51
or specifying time range in rfc3999
@@ -57,20 +54,40 @@ or specifying time range in rfc3999
57
54
pb query "select * from backend" --from=2023-01-00T01:40:00.000Z --to=2023-01-00T01:55:00.000Z
58
55
```
59
56
60
-
Query command outputs data to stdout. Output json is not beautified. Use tool like `jq` to format and filter json output.
57
+
You can use tools like `jq`and `grep`to further process and filter the output. Some examples:
Once a profile is configured, you can use pb to query and manage _that_ Parseable Server instance. For example, to list all the streams on the server, run:
0 commit comments