baidubce-cli
Advanced tools
Comparing version 0.0.7 to 0.0.8
{ | ||
"name": "baidubce-cli", | ||
"version": "0.0.7", | ||
"version": "0.0.8", | ||
"description": "baidu cloud engine command line tools", | ||
@@ -31,4 +31,5 @@ "main": "index.js", | ||
"dependencies": { | ||
"baidubce-sdk": "~0.0.2", | ||
"baidubce-sdk": "^0.0.16", | ||
"debug": "^2.1.3", | ||
"humanize": "0.0.9", | ||
"moment": "^2.8.4", | ||
@@ -35,0 +36,0 @@ "q": "^1.1.2", |
@@ -5,3 +5,3 @@ ## baidubce-cli | ||
Currently support operations on BOS and Media service. | ||
Currently support operations on BS, BOS, Media service. | ||
@@ -67,2 +67,57 @@ ## Install | ||
## BS Usage | ||
### Configuration | ||
For first time, you should config the `ak`, `sk` and `endpoint`. | ||
``` | ||
baidubce bs -c bs.ak my_ak | ||
baidubce bs -c bs.sk my_sk | ||
baidubce bs -c bs.endpoint https://bs.baidu.com | ||
``` | ||
Btw, you can also set specific `bucket` to a different `endpoint` which will override the default configuration. | ||
``` | ||
baidubce bs -c bs.my-bucket-1.ak my_ak | ||
baidubce bs -c bs.my-bucket-1.sk my_sk | ||
baidubce bs -c bs.my-bucket-1.endpoint http://10.26.208.32:8998 | ||
``` | ||
### create a bucket | ||
``` | ||
baidubce bs --create-buckets my-bucket-1 my-bucket-2 | ||
``` | ||
### list all buckets | ||
``` | ||
baidubce bs --list-buckets | ||
``` | ||
### list all objects | ||
``` | ||
baidubce bs --list-objects my-bucket-1 | ||
baidubce bs --list-objects my-bucket-1 --start=10 --limit=20 | ||
``` | ||
### upload a regular file | ||
``` | ||
# Upload hello.js to my-bucket-1 and rename to world.js | ||
baidubce bs --put-object hello.js bs://my-bucket-1/world.js | ||
# Upload hello.js to my-bucket-1 and keep the same file name. | ||
baidubce bs --put-object hello.js bs://my-bucket-1/ | ||
baidubce bs --put-object hello.js bs://my-bucket-1 | ||
``` | ||
### upload a large file | ||
> Unimplemented. | ||
## Media Usage | ||
@@ -69,0 +124,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
48121
12
1134
182
8
9
+ Addedhumanize@0.0.9
+ Addedbaidubce-sdk@0.0.16(transitive)
+ Addedhumanize@0.0.9(transitive)
- Removedbaidubce-sdk@0.0.23(transitive)
Updatedbaidubce-sdk@^0.0.16