From 0c24f709e89dc3363ce17a8b2bbc03ce658660e0 Mon Sep 17 00:00:00 2001 From: Andreas Gerler Date: Fri, 16 Dec 2016 12:03:09 +0100 Subject: [PATCH] aws yasnippets - some updates for my aws cli yasnippets. Signed-off-by: Andreas Gerler --- snippets/eshell-mode/aws-ec2-get-instance-details | 2 +- snippets/eshell-mode/aws-ec2-get-instance-volumes | 5 +++++ snippets/eshell-mode/aws-ec2-get-snapshot-details | 2 +- snippets/eshell-mode/aws-ec2-volume-details | 2 +- 4 files changed, 8 insertions(+), 3 deletions(-) create mode 100644 snippets/eshell-mode/aws-ec2-get-instance-volumes diff --git a/snippets/eshell-mode/aws-ec2-get-instance-details b/snippets/eshell-mode/aws-ec2-get-instance-details index 4078f0da..644ed68a 100644 --- a/snippets/eshell-mode/aws-ec2-get-instance-details +++ b/snippets/eshell-mode/aws-ec2-get-instance-details @@ -1,5 +1,5 @@ # -*- mode: snippet -*- # name: aws-ec2-get-instance-details (yank) -# key: ec2-details +# key: ec2-det # -- aws --profile=${1:$$(yas-choose-value '("prod" "test"))} ${2:--region=${3:$$(yas-choose-value bba-aws-regions)}} ec2 describe-instances --instance-ids ${4:`(yank)`} $0 \ No newline at end of file diff --git a/snippets/eshell-mode/aws-ec2-get-instance-volumes b/snippets/eshell-mode/aws-ec2-get-instance-volumes new file mode 100644 index 00000000..466025ce --- /dev/null +++ b/snippets/eshell-mode/aws-ec2-get-instance-volumes @@ -0,0 +1,5 @@ +# -*- mode: snippet -*- +# name: aws-ec2-get-instance-volumes +# key: ec2-vol +# -- +aws --profile=${1:$$(yas-choose-value '("prod" "test"))} ${2:--region=${3:$$(yas-choose-value "\$\{REGION\}" bba-aws-regions)}} ec2 describe-instances --query "Reservations[].Instances[].[join(\`,\`,Tags[?Key==\`Name\`].Value),join(' ', BlockDeviceMappings[].Ebs.VolumeId)]" --output ${4:$$(yas-choose-value '("text" "table" "json"))} $0 diff --git a/snippets/eshell-mode/aws-ec2-get-snapshot-details b/snippets/eshell-mode/aws-ec2-get-snapshot-details index 27360b18..ec293a9a 100644 --- a/snippets/eshell-mode/aws-ec2-get-snapshot-details +++ b/snippets/eshell-mode/aws-ec2-get-snapshot-details @@ -1,5 +1,5 @@ # -*- mode: snippet -*- # name: aws-ec2-get-snapshot-details (yank) -# key: snap-details +# key: snap-det # -- aws --profile=${1:$$(yas-choose-value '("prod" "test"))} ${2:--region=${3:$$(yas-choose-value "\$\{REGION\}" bba-aws-regions)}} ec2 describe-snapshots --snapshot-id ${4:`(yank)`} --output ${5:$$(yas-choose-value '("text" "table" "json"))} $0 \ No newline at end of file diff --git a/snippets/eshell-mode/aws-ec2-volume-details b/snippets/eshell-mode/aws-ec2-volume-details index e86e2897..621b7294 100644 --- a/snippets/eshell-mode/aws-ec2-volume-details +++ b/snippets/eshell-mode/aws-ec2-volume-details @@ -1,5 +1,5 @@ # -*- mode: snippet -*- # name: aws-ec2-volume-details (yank) -# key: ebs-details +# key: ebs-det # -- aws --profile=${1:$$(yas-choose-value '("prod" "test"))} ${2:--region=${3:$$(yas-choose-value "\$\{REGION\}" bba-aws-regions)}} ec2 describe-volumes --volume-ids ${4:`(yank)`} --output ${5:$$(yas-choose-value '("text" "table" "json"))} $0 -- 2.47.3