Permalink
Browse files

Remove usage of `echo -n`

  • Loading branch information...
1 parent edb53e9 commit 2d7bc8e02264f6f43cc77275bc78ffb08f344649 @decklin committed Jun 18, 2011
Showing with 2 additions and 3 deletions.
  1. +1 −1 curlicue
  2. +1 −2 curlicue-setup
View
@@ -65,7 +65,7 @@ echo_pair() {
# thing would be to use -passin, but it doesn't seem to affect -hmac.
hmac_sha1() {
- echo -n "$2" | openssl dgst -sha1 -hmac "$1" -binary | openssl base64
+ printf '%s' "$2" | openssl dgst -sha1 -hmac "$1" -binary | openssl base64
}
quote_vals() {
View
@@ -24,8 +24,7 @@ echo "oauth_consumer_key=$(curlicue -u "$key")&oauth_consumer_secret=$(
curlicue -f $consumer_tmp -p 'oauth_callback=oob' -- \
-s -d '' "$request_token_url" > $request_token_tmp
-echo -n 'Load this URL: '
-curlicue -f $consumer_tmp -f $request_token_tmp -e "$authorize_url"
+echo "Load this URL: $(curlicue -f $consumer_tmp -f $request_token_tmp -e "$authorize_url")"
read -p 'Paste the PIN you got here: ' pin
curlicue -f $consumer_tmp -f $request_token_tmp \

0 comments on commit 2d7bc8e

Please sign in to comment.