README.md in cf-uaa-lib-1.3.0 vs README.md in cf-uaa-lib-1.3.1

- old
+ new

@@ -1,43 +1,34 @@ # CloudFoundry UAA Gem -Client gem for interacting with the CloudFoundry UAA server. +Client gem for interacting with the [CloudFoundry UAA server](https://github.com/cloudfoundry/uaa) -Set up a local ruby environment (so sudo not required): +## Install from rubygems - `$ rvm use 1.9.2` + $ gem install cf-uaa-lib -or +## Build from source - `$ rbenv global 1.9.2-p180` + $ bundle install + $ gem build cf-uaa-lib.gemspec + $ gem install cf-uaa-lib<version>.gem -see: https://rvm.io/ or http://rbenv.org/ +## Use the gem -Build the gem + #!/usr/bin/env ruby + require 'uaa' + token_issuer = CF::UAA::TokenIssuer.new("https://uaa.cloudfoundry.com", "vmc") + puts token\_issuer.prompts.inspect + token = token_issuer.implicit_grant_with_creds(username: "<your_username>", password: "<your_password>") + token_info = TokenCoder.decode(token.info["access_token"], nil, nil, false) #token signature not verified + puts token_info["user_name"] - `$ bundle install` - `$ gem build cf-uaa-lib.gemspec` - -Install it - - `$ gem install cf-uaa-lib<version>.gem` - -Use the gem: - - `#!/usr/bin/env ruby` - `require 'uaa'` - `token_issuer = CF::UAA::TokenIssuer.new("https://uaa.cloudfoundry.com", "vmc")` - `puts token\_issuer.prompts.inspect` - `token = token_issuer.implicit_grant_with_creds(username: "<your_username>", password: "<your_password>")` - `token_info = TokenCoder.decode(token.info["access_token"], nil, nil, false) #token signature not verified` - `puts token_info["user_name"]` - ## Tests Run the tests with rake: - `$ bundle exec rake test` + $ bundle exec rake test Run the tests and see a fancy coverage report: - `$ bundle exec rake cov` + $ bundle exec rake cov