Skip to content

Commit 36b3ba3

Browse files
carlevisonconst-cloudinary
authored andcommitted
Update help and README.
1 parent 0fc58c9 commit 36b3ba3

File tree

9 files changed

+18
-39
lines changed

9 files changed

+18
-39
lines changed

README.md

Lines changed: 7 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -12,17 +12,14 @@ Python 3.6 or later. You can install Python from [https://www.python.org/](http
1212

1313
## Setup and Installation
1414

15-
1. Set your account's CLOUDINARY_URL environment variable in your terminal configuration file.
16-
You can do this by adding `export <YOUR_ENVIRONMENT_VARIABLE>` to `~/.bash_profile` from the terminal. For example:
17-
18-
```
19-
echo "export CLOUDINARY_URL=cloudinary://123456789012345:abcdefghijklmnopqrstuvwxyzA@cloud_name" >> ~/.bash_profile && source ~/.bash_profile
20-
```
15+
1. To install this package, run: `pip3 install cloudinary-cli`
16+
2. To make all your `cld` commands point to your Cloudinary account, set up your CLOUDINARY\_URL environment variable. For example:
17+
* On Mac or Linux:<br>`export CLOUDINARY_URL=cloudinary://123456789012345:abcdefghijklmnopqrstuvwxyzA@cloud_name`
18+
* On Windows:<br>`set CLOUDINARY_URL=cloudinary://123456789012345:abcdefghijklmnopqrstuvwxyzA@cloud_name`
2119

2220
_**Note:** you can copy and paste your account environment variable from the Account Details section of the Dashboard page in the Cloudinary console._
2321

24-
2. To install this package, run: `pip3 install cloudinary-cli`
25-
3. Make sure your configuration is set up properly by running `cld config`. A response of the following form is returned:
22+
3. Check your configuration by running `cld config`. A response of the following form is returned:
2623

2724
```
2825
cloud_name: <CLOUD_NAME>
@@ -212,6 +209,8 @@ Whereas using the saved configuration "accountx":
212209
cld -C accountx admin usage
213210
```
214211
212+
_**Caution:** Creating a saved configuration may put your API secret at risk as it is stored in a local plain text file._
213+
215214
You can create, delete and list saved configurations using the `config` command.
216215
217216
```
@@ -220,25 +219,6 @@ cld config [options]
220219
221220
For details, see the [Cloudinary CLI documentation](https://cloudinary.com/documentation/cloudinary_cli#config).
222221
223-
## Sample resources
224-
225-
Creates a URL based on a sample resource from the demo account.
226-
227-
Usage:
228-
229-
```
230-
cld <sample_resource> <transformation>
231-
```
232-
233-
- `sample` - http://res.cloudinary.com/demo/image/upload/sample
234-
- `couple` - http://res.cloudinary.com/demo/image/upload/couple
235-
- `dog` - http://res.cloudinary.com/demo/video/upload/dog
236-
237-
Example: create the URL for the dog video with optimized quality.
238-
239-
```
240-
cld dog q_auto
241-
```
242222
243223
# TODOs
244224
- Globbing support

cloudinary_cli/cli.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,9 @@
1515

1616

1717
@click.group(context_settings=CONTEXT_SETTINGS)
18-
@click.option("-c", "--config", help="""Temporary configuration to use. To use environment config:
19-
echo \"export CLOUDINARY_URL=YOUR_CLOUDINARY_URL\" >> ~/.bash_profile && source ~/.bash_profile
18+
@click.option("-c", "--config", help="""Tell the CLI which account to run the command on by specifying an account environment variable.
2019
""")
21-
@click.option("-C", "--config_saved", help="""Saved configuration to use - see `config` command""")
20+
@click.option("-C", "--config_saved", help="""Tell the CLI which account to run the command on by specifying a saved configuration - see `config` command.""")
2221
@click_log.simple_verbosity_option(logger)
2322
def cli(config, config_saved):
2423
if config:

cloudinary_cli/core/admin.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
@command("admin",
1010
short_help="Run any methods that can be called through the admin API.",
1111
help="""\b
12-
Enables you to run any methods that can be called through the admin API.
12+
Run any methods that can be called through the admin API.
1313
Format: cld <cli options> admin <command options> <method> <method parameters>
1414
\te.g. cld admin resources max_results=10 tags=sample
1515
\t OR

cloudinary_cli/core/search.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@
1111

1212

1313
@command("search",
14-
short_help="Runs the admin API search method.",
14+
short_help="Run the admin API search method.",
1515
help="""\b
16-
Runs the admin API search method.
16+
Run the admin API search method.
1717
Format: cld <cli options> search <command options> <Lucene query syntax string>
1818
e.g. cld search cat AND tags:kitten -s public_id desc -f context -f tags -n 10
1919
""")

cloudinary_cli/core/uploader.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
short_help="Run any methods that can be called through the upload API.",
1212
help="""
1313
\b
14-
Enables you to run any methods that can be called through the upload API.
14+
Run any methods that can be called through the upload API.
1515
Format: cld <cli options> uploader <command options> <method> <method parameters>
1616
\te.g. cld uploader upload http://res.cloudinary.com/demo/image/upload/sample public_id=flowers invalidate=True
1717
\b

cloudinary_cli/core/utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
from cloudinary_cli.utils import logger
77

88

9-
@command("url", help="Generates a Cloudinary URL, which you can optionally open in your browser.")
9+
@command("url", help="Generate a Cloudinary URL, which you can optionally open in your browser.")
1010
@argument("public_id", required=True)
1111
@argument("transformation", default="")
1212
@option("-rt", "--resource_type", default="image", type=Choice(['image', 'video', 'raw']), help="The asset type")

cloudinary_cli/modules/make.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@
44
from cloudinary_cli.utils import load_template
55

66

7-
@command("make", short_help="Scaffold Cloudinary templates.",
7+
@command("make", short_help="Return template code for implementing the specified Cloudinary widget.",
88
help="""\b
9-
Returns template code for implementing the specified Cloudinary widget.
9+
Return template code for implementing the specified Cloudinary widget.
1010
e.g. cld make product_gallery
1111
""")
1212
@argument("template", nargs=-1)

cloudinary_cli/modules/sync.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515

1616

1717
@command("sync",
18-
short_help="Synchronizes between a local directory and a Cloudinary folder.",
18+
short_help="Synchronize between a local directory and a Cloudinary folder.",
1919
help="Synchronize between a local directory and a Cloudinary folder, maintaining the folder structure.")
2020
@argument("local_folder")
2121
@argument("cloudinary_folder")

cloudinary_cli/modules/upload_dir.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111

1212
@command("upload_dir",
13-
help="""Uploads a folder of assets, maintaining the folder structure.""")
13+
help="""Upload a folder of assets, maintaining the folder structure.""")
1414
@argument("directory", default=".")
1515
@option("-o", "--optional_parameter", multiple=True, nargs=2, help="Pass optional parameters as raw strings.")
1616
@option("-O", "--optional_parameter_parsed",

0 commit comments

Comments
 (0)