Skip to content
This repository was archived by the owner on Jun 4, 2019. It is now read-only.

Commit 83f8c50

Browse files
committed
Merge pull request #7 from philips/cleanup-readme
README improvements
2 parents 3b786ef + 1c2c0f4 commit 83f8c50

File tree

1 file changed

+67
-26
lines changed

1 file changed

+67
-26
lines changed

README.md

+67-26
Original file line numberDiff line numberDiff line change
@@ -3,30 +3,54 @@ etcdctl
33

44
[![Build Status](https://travis-ci.org/coreos/etcdctl.png)](https://travis-ci.org/coreos/etcdctl)
55

6-
This is our spec/working area for a simple command line client for etcd. This client will be bundled with CoreOS. This is all brainstorming at the moment. Please contribute!
6+
`etcdctl` is a command line client for [etcd][etcd]. It can be used in scripts or for administrators to explore an etcd cluster.
77

8-
## Example usage
8+
[etcd]: https://github.com/coreos/etcd
99

10-
Setting a key on `/foo/bar`:
10+
## Getting etcdctl
11+
12+
The latest release is available as a binary at [Github][github-release] along with etcd.
13+
14+
[github-release]: https://github.com/coreos/etcd/releases/
15+
16+
You can also build etcdctl from source:
17+
18+
```
19+
./build
20+
```
21+
22+
## Usage
23+
24+
### Key/Value
25+
26+
Setting a key on `/foo/bar`:
27+
28+
```
29+
etcdctl set /foo/bar "Hello world"
30+
Hello world
31+
```
1132

12-
$ etcdctl set /foo/bar "Hello world"
13-
Hello world
14-
1533
Getting a key:
1634

17-
$ etcdctl get /foo/bar
18-
Hello world
35+
```
36+
etcdctl get /foo/bar
37+
Hello world
38+
```
1939

2040
Deleting a key:
2141

22-
$ etcdctl delete /foo/bar
23-
Hello world
42+
```
43+
etcdctl delete /foo/bar
44+
Hello world
45+
```
2446

2547
Tailing a key:
2648

27-
$ etcdctl watch /foo/bar -f
28-
Hello world
29-
.... client hangs forever until ctrl+C printing values as key change
49+
```
50+
etcdctl watch /foo/bar -f
51+
Hello world
52+
.... client hangs forever until ctrl+C printing values as key change
53+
```
3054

3155
### Sets
3256

@@ -37,24 +61,26 @@ an etcd key, so that they can be detected and used by clients.
3761

3862
Adding members to a set:
3963

40-
$ etcdctl sadd /queues amqp://user:password@rabbitmq1
41-
amqp://user:password@rabbitmq1
42-
$ etcdctl sadd /queues amqp://user:password@rabbitmq2 --ttl=60
43-
amqp://user:password@rabbitmq2
64+
```
65+
etcdctl sadd /queues amqp://user:password@rabbitmq1
66+
amqp://user:password@rabbitmq1
67+
etcdctl sadd /queues amqp://user:password@rabbitmq2 --ttl=60
68+
amqp://user:password@rabbitmq2
69+
```
4470

4571
List all members:
4672

47-
$ etcdctl smembers /queues
48-
amqp://user:password@rabbitmq1
49-
amqp://user:password@rabbitmq2
50-
51-
To delete a member:
73+
```
74+
etcdctl smembers /queues
75+
amqp://user:password@rabbitmq1
76+
amqp://user:password@rabbitmq2
77+
```
5278

53-
$ etcdctl sdel /queues amqp://user:password@rabbitmq1
54-
55-
## Building
79+
To delete a member:
5680

57-
./build
81+
```
82+
etcdctl sdel /queues amqp://user:password@rabbitmq1
83+
```
5884

5985
## Return Codes
6086

@@ -69,3 +95,18 @@ To delete a member:
6995
4 400 error from etcd
7096

7197
5 500 error from etcd
98+
99+
## Project Details
100+
101+
### Versioning
102+
103+
etcdctl uses [semantic versioning][semver].
104+
Releases will follow lockstep with the etcd release cycle.
105+
106+
[semver]: http://semver.org/
107+
108+
### License
109+
110+
etcdctl is under the Apache 2.0 license. See the [LICENSE][license] file for details.
111+
112+
[license]: https://github.com/coreos/etcdctl/blob/master/LICENSE

0 commit comments

Comments
 (0)