$ vi str.tmp
test test1 test2 test3 |
$ vi bash_file.sh
#!/bin/bash STRNM=`cat str.tmp` if [ -z "$STRNM" ] then # -z 는 내용이 null 일 때 true // -n 은 내용이 null이 아닐 때 true elif # else if 내용 else # 문자열 반복 for str in $STRNM do echo $str done fi |
'개발' 카테고리의 다른 글
[개발] MRT (Monitoring_tool for Altibase) (0) | 2024.01.18 |
---|---|
[개발] LINUX bash facility command (0) | 2020.08.20 |
[개발] Mybatis 통해 Mariadb Procedure 호출 에러 (0) | 2020.04.18 |