aboutsummaryrefslogtreecommitdiffstats
path: root/src/u_checks.go
diff options
context:
space:
mode:
authorJozanLeClerc <bousset.rudy@gmail.com>2022-04-01 19:44:27 +0200
committerJozanLeClerc <bousset.rudy@gmail.com>2022-04-01 19:44:27 +0200
commitb5b54feb70ba1dabc2ef425679f3c569b4e199fa (patch)
treee1f1605ab39455479d7d6c9c30e4e6f09badf729 /src/u_checks.go
parentRandom works fine (diff)
downloadgo2work-b5b54feb70ba1dabc2ef425679f3c569b4e199fa.tar.gz
go2work-b5b54feb70ba1dabc2ef425679f3c569b4e199fa.tar.bz2
go2work-b5b54feb70ba1dabc2ef425679f3c569b4e199fa.tar.xz
go2work-b5b54feb70ba1dabc2ef425679f3c569b4e199fa.tar.zst
go2work-b5b54feb70ba1dabc2ef425679f3c569b4e199fa.zip
In progress
Diffstat (limited to 'src/u_checks.go')
-rw-r--r--src/u_checks.go11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/u_checks.go b/src/u_checks.go
index 1a33232..6188803 100644
--- a/src/u_checks.go
+++ b/src/u_checks.go
@@ -39,7 +39,7 @@
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* go2work: src/u_checks.go
- * Wed Mar 30 01:25:35 CEST 2022
+ * Fri Apr 1 18:30:55 CEST 2022
* Joe
*
* Useful checks.
@@ -48,6 +48,7 @@
package main
import (
+ "os"
"os/exec"
)
@@ -78,3 +79,11 @@ func check_time_format(time [3]byte) bool {
}
return true
}
+
+func check_file_exists(file string) bool {
+ _, err := os.Stat(file)
+ if os.IsNotExist(err) == true {
+ return false
+ }
+ return true
+}