1 |
|
2 | #
|
3 | # Licensed to the Apache Software Foundation (ASF) under one
|
4 | # or more contributor license agreements. See the NOTICE file
|
5 | # distributed with this work for additional information
|
6 | # regarding copyright ownership. The ASF licenses this file
|
7 | # to you under the Apache License, Version 2.0 (the
|
8 | # "License"); you may not use this file except in compliance
|
9 | # with the License. You may obtain a copy of the License at
|
10 | #
|
11 | # http://www.apache.org/licenses/LICENSE-2.0
|
12 | #
|
13 | # Unless required by applicable law or agreed to in writing,
|
14 | # software distributed under the License is distributed on an
|
15 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
16 | # KIND, either express or implied. See the License for the
|
17 | # specific language governing permissions and limitations
|
18 | # under the License.
|
19 | #
|
20 | -->
|
21 | Bash shell support
|
22 | ==================
|
23 |
|
24 | Cordova CLI comes bundled with a script which provides command-line tab-completion for Bash. If you're running a sufficiently
|
25 | Unix-y operating system (Linux, BSD, OS X) you can install this to make typing cordova command lines easier.
|
26 |
|
27 | Installation
|
28 | ------------
|
29 |
|
30 | ### Linux
|
31 |
|
32 | To install on a Linux or BSD system, copy the `scripts/cordova.completion` file to your `/etc/bash_completion.d` directory. This will be read the next time you start a new shell.
|
33 |
|
34 | ### OS X
|
35 |
|
36 | On OS X, put the `scripts/cordova.completion` file anywhere readable, and add the following line to the end of your `~/.bashrc` file:
|
37 |
|
38 | source <path to>/cordova.completion
|
39 |
|
40 | This will be read the next time you start a new shell.
|
41 |
|
42 | Usage
|
43 | ------
|
44 |
|
45 | It's easy! As long as your command line begins with an executable called 'cordova', just hit `<TAB>` at any point to see a list of valid completions.
|
46 |
|
47 | Examples:
|
48 |
|
49 | $ cordova <TAB>
|
50 | build compile create emulate platform plugin prepare serve
|
51 |
|
52 | $ cordova pla<TAB>
|
53 |
|
54 | $ cordova platform <TAB>
|
55 | add ls remove rm
|
56 |
|
57 | $ cordova platform a<TAB>
|
58 |
|
59 | $ cordova platform add <TAB>
|
60 | android blackberry ios wp8 www
|
61 |
|
62 | $ cordova plugin rm <TAB>
|
63 |
|
64 | $ cordova plugin rm org.apache.cordova.<TAB>
|
65 | org.apache.cordova.file org.apache.cordova.inappbrowser
|