zuv0 commited on
Commit
984396d
·
verified ·
1 Parent(s): 029780f

Update gc.sh

Browse files
Files changed (1) hide show
  1. gc.sh +11 -1
gc.sh CHANGED
@@ -1,17 +1,27 @@
1
  #!/bin/bash
2
 
 
 
3
  cd /workspace
4
  rm -rf output
 
5
  rm -f out*.tar*
6
  rm -f out*.zip*
7
 
8
  cd *
9
  rm -rf output
 
10
  rm -f out*.tar*
11
  rm -f out*.zip*
12
 
13
  cd SD
14
  rm -rf output
 
 
 
 
 
 
 
15
 
16
- #sudo rm -rf /tmp/*
17
  cd /workspace
 
1
  #!/bin/bash
2
 
3
+ FLAG_1=$1
4
+
5
  cd /workspace
6
  rm -rf output
7
+ rm -rf outputs
8
  rm -f out*.tar*
9
  rm -f out*.zip*
10
 
11
  cd *
12
  rm -rf output
13
+ rm -rf outputs
14
  rm -f out*.tar*
15
  rm -f out*.zip*
16
 
17
  cd SD
18
  rm -rf output
19
+ rm -rf outputs
20
+
21
+ if [[ "$FLAG_1" =~ 1 ]]; then
22
+ sudo rm -rf /tmp/*
23
+ else
24
+ find /tmp -mtime +2 -delete
25
+ fi
26
 
 
27
  cd /workspace