os: implement a JS version of os.join_path_single too

pull/12550/head
Delyan Angelov 2021-11-22 15:03:05 +02:00
parent 7a0dc60d04
commit 6a252ed015
No known key found for this signature in database
GPG Key ID: 66886C0F12D595ED
1 changed files with 5 additions and 0 deletions

View File

@ -102,6 +102,11 @@ pub fn join_path(base string, dirs ...string) string {
return res
}
pub fn join_path_single(base string, elem string) string {
// TODO: deprecate this
return join_path(base, elem)
}
pub fn execute(cmd string) Result {
mut exit_code := 0
mut stdout := ''