ã¡ãã£ã¨è¨äºãé·ããªã£ã¡ãã£ãã®ã§ã ã¹ãã¼ã¹ãå«ããæååãè¡æ¯ã«ã«ã¼ãå¦çãããå ´åãæçµçã«ããæ¸ãã°è¯ããã ã¨ããã®ãå
ã«è¼ãã¦ãããã¨æãã¾ãã #!/bin/bash set -u # ãµã³ãã«ãã¼ã¿ (空ç½ãå«ãæåå) data=$(cat <<EOT hoge 123 piyo 456 foo 789 EOT ) # read -a ã§ãä¸è¡æ¯ã«é
åã«æ ¼ç´ while read -a arr; do echo "-----------" # ã«ã¼ãããããããããã罫ç·å¼ã echo " line: ${arr[*]}" # line echo "column1: ${arr[0]}" # ã«ã©ã 1 echo "column2: ${arr[1]}" # ã«ã©ã 2 done < <(echo "$data") # ããã»ã¹ç½®æã§å
¥åããã¹ãã¨ãã¦æ±ã åºåçµæ ----
{{#tags}}- {{label}}
{{/tags}}