Coder Social home page Coder Social logo

get-aws-profile-bash's Issues

script is not executable by default (chmod u+x)

Fresh git clone:

➜  get-aws-profile-bash git:(master) ./get-aws-profile.sh  
zsh: permission denied: ./get-aws-profile.sh
➜  get-aws-profile-bash git:(master) chmod u+x get-aws-profile.sh 
➜  get-aws-profile-bash git:(master) ✗ ./get-aws-profile.sh 
./get-aws-profile.sh: line 118: cfg.section.default: command not found
Profile 'default' not found

I will see if I can submit a PR.

Script fails is not executed on the same directory

Hi, really cool script!

I have found that it only works if I called it from the same directory where it lives, i.e.

$ ./get-aws-profile.sh

but if I drop the script say in ~/bin and simply call

~$ get-aws-profile.sh --profile=saml
/Users/regulya/bin/get-aws-profile.sh: eval: line 41: syntax error near unexpected token `}'
/Users/regulya/bin/get-aws-profile.sh: eval: line 41: `}'
Parsing credentials file '/Users/regulya/.aws/credentials' failed

It fails with above error.

The same error happens if I call it with the full path, but not being on the same directory:

~$ ./bin/get-aws-profile.sh --profile=saml
./bin/get-aws-profile.sh: eval: line 41: syntax error near unexpected token `}'
./bin/get-aws-profile.sh: eval: line 41: `}'
Parsing credentials file '/Users/regulya/.aws/credentials' failed

Readme example commands

I was able to successfully use your script as follows (notice the = sign):
$ ./get-aws-profile.sh --profile=my-example --key

In your example however it says to run it as follows which did not work for me
$ ./get-aws-profile.sh --profile my-example --key

Following your example command it returned:
Unknown option --profile

Am I missing something?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.