The main Bubble source repository. Contains the Bubble API server, the web UI, documentation and utilities. https://getbubblenow.com
Nelze vybrat více než 25 témat Téma musí začínat písmenem nebo číslem, může obsahovat pomlčky („-“) a může být dlouhé až 35 znaků.

123456789101112131415161718192021222324
  1. #!/bin/bash
  2. #
  3. # Copyright (c) 2020 Bubble, Inc. All rights reserved. For personal (non-commercial) use, see license: https://getbubblenow.com/bubble-license/
  4. #
  5. #
  6. # Print all values for a JSON property name, among any given JSON via stdin.
  7. # JSON could be object, array, nested objects, etc.
  8. #
  9. # Note that this command redirects stderr to /dev/null, so it might mask errors.
  10. # If you get empty results when you expect something there, check the output of the command
  11. # before piping to jq-all-vals to verify
  12. #
  13. # Usage:
  14. #
  15. # some-command-that-produces-JSON | jq-all-vals prop-name
  16. #
  17. # prop-name : a property name
  18. #
  19. SCRIPT="${0}"
  20. SCRIPT_DIR=$(cd $(dirname ${SCRIPT}) && pwd)
  21. . ${SCRIPT_DIR}/bubble_common
  22. ARG=${1:?no property provided}
  23. jq -r 'getpath(path(.. | select(.'"${ARG}"' != null))) | .'"${ARG}"'' 2> /dev/null