Skip to content

Commit 907f639

Browse files
authored
Merge pull request #4 from lixiaojun629/develop
0.1.3
2 parents f67337b + 06746b3 commit 907f639

240 files changed

Lines changed: 8922 additions & 3616 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,11 @@
11
## Change Log
22

3+
v0.1.3
4+
* integrate auto completion.
5+
* Support uhost create, stop, delete and so on.
6+
7+
v0.1.2
8+
* simplify config and completion.
9+
310
v0.1.1
411
* UHost list; EIP list,delete and allocate; GlobalSSH list,delete,modify and create.

Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
export VERSION=0.1.2
1+
export VERSION=0.1.3
22

33
.PHONY : build
44
build:
5-
go install && mv ../../../../bin/ucloud-cli ../../../../bin/ucloud
5+
go install && mv ../../../../bin/ucloud-cli /usr/local/bin/ucloud
66

77
.PHONY : build_mac
88
build_mac:

README.md

Lines changed: 19 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -12,27 +12,6 @@ You can use [Homebrew](https://brew.sh/) on macOS or [Linuxbrew](http://linuxbre
1212
```
1313
brew install ucloud
1414
```
15-
16-
##### Download binary file
17-
Archive links:
18-
[Mac](http://ucloud-sdk.ufile.ucloud.com.cn/ucloud-cli-macosx-0.1.2-amd64.tgz)
19-
[Linux](http://ucloud-sdk.ufile.ucloud.com.cn/ucloud-cli-linux-0.1.2-amd64.tgz)
20-
[Windows](http://ucloud-sdk.ufile.ucloud.com.cn/ucloud-cli-windows-0.1.2-amd64.zip)
21-
22-
SHA-256 checksum
23-
```
24-
19b7a0803fc41ee689797a36fd67b288e993c383edf6087f56825a4d5bb17875 ucloud-cli-linux-0.1.2-amd64.tgz
25-
ecc787f4045ea14d583801cd0cfa746be357d50756c2cf0ba879e405c2325d1c ucloud-cli-macosx-0.1.2-amd64.tgz
26-
f48058ac96bb0283b18c660f0350eedba49d03a753775b0a2773b2081698b3f3 ucloud-cli-windows-0.1.2-amd64.zip
27-
```
28-
29-
Download the binary file and extract to /usr/local/bin directory or add it to the $PATH. Take macOS as an example.
30-
```
31-
$ curl -o ucloud-cli.tgz http://ucloud-sdk.ufile.ucloud.com.cn/ucloud-cli-macosx-0.1.2-amd64.tgz
32-
$ echo "ecc787f4045ea14d583801cd0cfa746be357d50756c2cf0ba879e405c2325d1c *ucloud-cli-macosx-0.1.2-amd64.tgz" | shasum -a 256 -c
33-
$ tar -zxf ucloud-cli.tgz
34-
$ cp ucloud /usr/local/bin
35-
```
3615
##### Build from source code
3716

3817
If you have installed golang, run the following commands to install the UCloud CLI.
@@ -45,12 +24,26 @@ $ cd ucloud-cli
4524
$ make install
4625
```
4726

27+
### Uninstall UCloud CLI
28+
29+
Remove the executable file /usr/local/bin/ucloud and the directory $HOME/.ucloud
30+
4831
### Config UCloud CLI
4932

50-
After install the cli, run 'ucloud config' to complete the cli configuration following the tips. Local settings will be saved in directory $HOME/.ucloud
51-
Command 'ucloud ls --object [region|project]' display all the regions and projects. You can change the default region and prject by runing 'ucloud config set [region|project] xxx'.
52-
Execute 'ucloud config --help' for more information.
33+
After install the cli, run 'ucloud init' to complete the cli configuration following the tips. Local settings will be saved in directory $HOME/.ucloud
5334

54-
### Uninstall UCloud CLI
35+
### Auto complete
36+
Run 'ucloud --completion' for help
5537

56-
Remove the executable file /usr/local/bin/ucloud and the directory $HOME/.ucloud
38+
#### Bash shell
39+
Please append the following scripts to file ~/.bash_profile or ~/.bashrc.
40+
```
41+
complete -C /usr/local/bin/ucloud ucloud
42+
```
43+
44+
#### Zsh shell
45+
Please append the following scripts to file ~/.zshrc.
46+
```
47+
autoload -U +X bashcompinit && bashcompinit
48+
complete -F /usr/local/bin/ucloud ucloud
49+
```

0 commit comments

Comments
 (0)