Jonkman Microblog
  • Login
Show Navigation
  • Public

    • Public
    • Network
    • Groups
    • Popular
    • People

Conversation

Notices

  1. musicman (musicman@nu.federati.net)'s status on Thursday, 16-May-2019 21:51:27 EDT musicman musicman
    comparing variables in bash is ok, but it seems like bash is deciding total is not an int. variables in bash are not typed, but total only has numerals.

    I can test simple math outside of the loop on $total and it doesn't work.

    I was using a variable name that made sense, but all the examples use i, so I just went with that.

    #/bin/bash

    total=`./total.sh | awk '{ print $2 }'`

    echo $total

    i=0

    #testing another method
    while [ $i < $total ]
    do
    curl -X POST https://sandbox.plaid.com/institutions/get -H 'Content-Type: application/json' --data @<(cat <<EOF
    {
    "client_id": "5cc312cee54277001312d232",
    "secret": "",
    "count": 1,
    "offset": $i
    }
    EOF
    )
    echo $i
    ((i++))
    done
    In conversation Thursday, 16-May-2019 21:51:27 EDT from nu.federati.net permalink
  • Help
  • About
  • FAQ
  • TOS
  • Privacy
  • Source
  • Version
  • Contact

Jonkman Microblog is a social network, courtesy of SOBAC Microcomputer Services. It runs on GNU social, version 1.2.0-beta5, available under the GNU Affero General Public License.

Creative Commons Attribution 3.0 All Jonkman Microblog content and data are available under the Creative Commons Attribution 3.0 license.

Switch to desktop site layout.