Package: aws-shell
aws-shell - The interactive productivity booster for the AWS CLIInstallationThe aws-shell requires python andpipto install.
You can install the aws-shell usingpip:$ pip install aws-shellIf you are not installing into a virtualenv you can run:$ sudo pip install aws-shellMac OS X (10.11 El Capitan) users: There is a known issue with Apple and
its included python package dependencies (more info athttps://github.com/pypa/pip/issues/3165).
We are investigating ways to fix this issue but in the meantime,
to install the aws-shell, you can run:sudo pip installaws-shell--upgrade--ignore-installedsixOnce you’ve installed the aws-shell, you can now run:$ aws-shellTo exit the shell, pressCtrl-D.Upgrading the aws-shellIf you want to upgrade to the latest version of the aws-shell,
you can run:$ pip install --upgrade aws-shellYou can also use this upgrade command whenever a new version of the AWS CLI is
released that includes new services and API updates.  You will then be
able to use these new services and API updates in the aws-shell.Supported Python VersionsThe aws-shell works on the same python versions supported by the AWS CLI:2.6.5 and greater2.7.x and greater3.3.x and greater3.4.x and greaterConfigurationThe aws-shell uses the same configuration settings as the AWS CLI.
If you’ve never used the AWS CLI before, the easiest way to get
started is to run theconfigurecommand:$ aws-shell
aws> configure
AWS Access Key ID [None]: your-access-key-id
AWS Secret Access Key [None]: your-secret-access-key
Default region name [None]: region-to-use (e.g us-west-2, us-west-1, etc).
Default output format [None]:
aws>For more information about configure settings, see theAWS CLI Getting Started Guide.Basic UsageThe aws-shell accepts the same commands as the AWS CLI, except you don’t
need to provide theawsprefix.  For example, here are a few commands
you can try:$ aws-shell
aws> ec2 describe-regions
{
    "Regions": [
        {
            "Endpoint": "ec2.eu-west-1.amazonaws.com",
            "RegionName": "eu-west-1"
        },
        ...
aws> s3 ls
2015-12-07 15:03:34 bucket1
2015-12-07 15:03:34 bucket2
aws> dynamodb list-tables --output text
TABLENAMES     First
TABLENAMES     Second
TABLENAMES     ThirdProfilesThe aws-shell supports AWS CLI profiles.  You have two options to use
profiles.  First, you can provide a profile when you start the aws-shell:$ aws-shell --profile prod
aws>When you do this all the server side completion as well as CLI commands
you run will automatically use theprodprofile.You can also change the current profile while you’re in the aws-shell:$ aws-shell
aws> .profile demo
Current shell profile changed to: demoYou can also check what profile you’ve configured in the aws-shell using:aws> .profile
Current shell profile: demoAfter changing your profile using the.profiledot command, all
server side completion as well as CLI commands will automatically use
the new profile you’ve configured.FeaturesAuto Completion of Commands and OptionsThe aws-shell provides auto completion of commands and
options as you type.Shorthand Auto CompletionThe aws-shell can also fill in an example of the
shorthand syntax used for various AWS CLI options:Server Side Auto CompletionThe aws-shell also leveragesboto3, the AWS SDK for Python, to auto complete
server side resources such as Amazon EC2 instance Ids, Amazon Dynamodb table
names, AWS IAM user names, Amazon S3 bucket names, etc.This feature is under active development.  The list of supported resources
continues to grow.Fuzzy SearchingEvery auto completion value supports fuzzy searching.  This enables you to
specify the commands, options, and values you want to run with even less
typing.  You can try typing:The first letter of each sub word:ec2describe-reserved-instances-offerings->ec2 drioA little bit of each word:ec2describe-instances->ec2 descinstAny part of the command:dynamodb table-> Offers all commands that
contain the subsequencetable.Inline DocumentationThe aws-shell will automatically pull up documentation as you type commands.
It will show inline documentation for CLI options.  There is also a separate
documentation panel that will show documentation for the current command or
option you are typing. Pressing F9 will toggle focus to the documentation panel
allowing you to navigate it using your selected keybindings.Fish-Style Auto SuggestionsThe aws-shell supports Fish-style auto-suggestions. Use the right arrow key to
complete a suggestion.Command HistoryThe aws-shell records the commands you run and writes them to~/.aws/shell/history.  You can use the up and down arrow keys to scroll
through your history.Toolbar OptionsThe aws-shell has a bottom toolbar that provides several options:F2toggles between fuzzy and substring matchingF3toggles between VI and Emacs key bindingsF4toggles between single and multi column auto completionsF5shows and hides the help documentation paneF9toggles focus between the cli and documentation paneF10orCtrl-Dexits the aws-shellAs you toggle options in the toolbar, your preferences are persisted
to the~/.aws/shell/awsshellrcfile so that the next time you run
the aws-shell, your preferences will be restored.Dot CommandsThe aws-shell provides additional commands specific to the aws-shell.
The commands are available by adding the.prefix before a command.Exiting the ShellYou can run the.exitor.quitcommands to exit the shell.Creating Shell Scripts with .editThere are times when you may want to take a sequence of commands
you’ve run in the aws-shell and combine them into a shell script.
In addition to the command history that’s persisted to the
history file, the aws-shell also keeps track of all the commands
you’ve run since you first started your aws-shell session.You can run the.editcommand to open all these commands in
an editor.  The aws-shell will use theEDITORenvironment
variable before defaulting tonotepadon Windows andvion other platforms.aws> ec2 describe-instances
aws> dynamodb list-tables
aws> .editChanging Profiles with .profileYou can change the current AWS CLI profile used by the aws-shell
by using the.profiledot command.  If you run the.profilecommand with no arguments, the currently configured shell profile
will be printed.aws> .profile demo
Current shell profile changed to: demo
aws> .profile
Current shell profile: demo.cdYou can change the current working directory of the aws-shell by using
the.cdcommand:aws> !pwd
/usr
aws> .cd /tmp
aws> !pwd
/tmpExecuting Shell CommandsThe aws-shell integrates with other commands in several ways.
First, you can pipe AWS CLI commands to other processes as well
as redirect output to a file:aws> dynamodb list-tables --output text | head -n 1
TABLENAMES     First
aws> dynamodb list-tables --output text > /tmp/foo.txtSecond, if you want to run a shell command rather than an AWS CLI
command, you can add the!prefix to your command:aws> !ls /tmp/
foo.txt                                    bar.txtDeveloper Preview StatusThe aws-shell is currently in developer preview.
We welcome feedback, feature requests, and bug reports.
There may be backwards incompatible changes made in order
to respond to customer feedback as we continue to iterate
on the aws-shell.More InformationBelow are miscellaneous links for more information:AWS CLI Reference DocsAWS CLI User GuideAWS CLI BlogAWS CLI Github Repo