find . -type f | perl -ne 'print $1 if m/\.([^.\/]+)$/' | sort -u


bash, while

카테고리 없음 2021. 6. 24. 14:18

# local pc files backup
echo " local pc files backup ..."
while true
do
        date "+%Y-%m-%d %H:%M:%S"

        d=$(date "+%H")
        echo  d is $d
        if [ "$d" -eq 14  ];then
                echo 'Dbeaver script Copy start =============================================='  ;

                cp /cygdrive/C/Users/hongkildong/AppData/Roaming/DBeaverData/workspace6/General/Scripts/* /cygdrive/d/backup-dbeaver-script

                echo 'Dbeaver script Copy end =============================================='  ;
        fi

        sleep 3600
done



탐색기 > 보기 > 파일확장명


multi project 에서 
1) ctrl + shift + r 창에서 입력하는 곳 오른 쪽 위 |(점 3개) 클릭
 후 두 항목 선택
show status line
show derived line
https://lifeonguide.tistory.com/47

2) parent 폴더에서
속성 > resource > resource filter 
에서 
children 폴더 적용

https://goni9071.tistory.com/362

 

 

(https://stackoverflow.com/questions/15064796/eclipse-file-search-finds-the-same-file-multiple-times/15067818)

Within the parent project, child ones were already visually hidden in my case, but still found through search and Ctrl-click links.

I solved this by using Resource filters:

  1. Right-click (parent) project > Properties > Resource > Resource Filters
  2. Click Add Filter..., select Applies to -> Folders and enter one child project's folder name, click OK
  3. Repeat 2. for all child project folders

By the end, you should have something like this:

 


curl -X POST -H 'Content-type: application/json' --data '{"text": "'"${message}"'"}'

(https://stackoverflow.com/questions/40852784/how-can-i-use-a-variable-in-curl-call-within-bash-script)




CREATE SP_FOR_LOOP_SAMPLE(
 OUT  o_return      INT
  ,  OUT  o_row_count   INT
)
BEGIN

-- -------------------------------------
-- declare (BEGIN)
-- -------------------------------------

DECLARE v_abc VARCHAR(100) CHARSET utf8mb4 COLLATE utf8mb4_bin DEFAULT 'RemoveApiLogBatch'; 

-- -------------------------------------
-- declare (END)
-- -------------------------------------
  

SET ii = 0;

label1: WHILE ii < v_max_cnt DO


SET @query = CONCAT (
  'DELETE FROM TEST_TABLE '
...
);

    PREPARE stmt FROM @query;
  EXECUTE stmt;
  SELECT ROW_COUNT(), LAST_INSERT_ID() INTO @row_count, @last_insert_id;
  DEALLOCATE PREPARE stmt;


IF @row_count < v_unit_cnt THEN

LEAVE label1; /* 종료 */

END IF;

  SET ii = ii + 1;

  END WHILE label1;
  
SET o_return = 0, o_row_count = @row_count;
  
END


import org.springframework.beans.factory.annotation.Value;