diff options
| author | Arturs Artamonovs <arturs.artamonovs@protonmail.com> | 2026-09-24 11:02:35 +0100 |
|---|---|---|
| committer | Arturs Artamonovs <arturs.artamonovs@protonmail.com> | 2026-09-24 11:02:35 +0100 |
| commit | 505b23afc68ecbb63b8f0a7d44c0b0ad063d5cfd (patch) | |
| tree | d38b29a0cf23041571eb08fd79f49fdad8deb85f /Utils/FileUtils.swift | |
| parent | 056ee0c3355db995d7ea571e0635ebe8b09bf8ee (diff) | |
| download | ADSBDecoder-505b23afc68ecbb63b8f0a7d44c0b0ad063d5cfd.tar.gz ADSBDecoder-505b23afc68ecbb63b8f0a7d44c0b0ad063d5cfd.zip | |
rearrange source, move common parts to framework
Diffstat (limited to 'Utils/FileUtils.swift')
| -rw-r--r-- | Utils/FileUtils.swift | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/Utils/FileUtils.swift b/Utils/FileUtils.swift new file mode 100644 index 0000000..7a7f177 --- /dev/null +++ b/Utils/FileUtils.swift @@ -0,0 +1,23 @@ +// +// Utils.swift +// ADSBDecoder +// +// Created by Jacky Jack on 30/06/2024. +// + +import Foundation + +//return true if file excists +func checkIfFileExists(_ fname: String) -> Bool { + let fm = FileManager.default + if fm.fileExists(atPath: fname) { + return true + } + return false +} + +//get current run directory +func getCurrentDirPath() -> String { + return Process().currentDirectoryPath +} + |
