File tree Expand file tree Collapse file tree 2 files changed +15
-0
lines changed Expand file tree Collapse file tree 2 files changed +15
-0
lines changed Original file line number Diff line number Diff line change @@ -28,6 +28,11 @@ cleanup_gomod() {
2828 return ;
2929 fi
3030
31+ if [ ! -f ./function/go.mod ]; then
32+ echo " module not initialized, skipping go.mod cleanup"
33+ return ;
34+ fi
35+
3136 echo " cleaning up go.mod"
3237
3338 # Copy the user's go.mod
Original file line number Diff line number Diff line change @@ -28,6 +28,11 @@ cleanup_gomod() {
2828 return ;
2929 fi
3030
31+ if [ ! -f ./function/go.mod ]; then
32+ echo " module not initialized, skipping go.mod cleanup"
33+ return ;
34+ fi
35+
3136 echo " cleaning up go.mod"
3237
3338 # Copy the user's go.mod
@@ -98,6 +103,11 @@ cleanup_vendor_modulestxt() {
98103 return ;
99104 fi
100105
106+ if [ -f ./function/go.mod ]; then
107+ echo " module not initialized, skipping go.mod cleanup"
108+ return ;
109+ fi
110+
101111 echo " cleanup vendor/modules.txt"
102112
103113 # just in case
You can’t perform that action at this time.
0 commit comments