提交 dd25e7ea authored 作者: Jeff Lenk's avatar Jeff Lenk

FS-4768 part of garmts changes

上级 71e880a8
......@@ -126,9 +126,16 @@ Sub GetWgetEXE(DestFolder)
End If
End Sub
Function Strip(Str)
Set oRE = New Regexp
oRE.Pattern = "[\W_]"
oRE.Global = True
Strip=oRE.Replace(Str, "")
End Function
Sub UnCompress(Archive, DestFolder)
batname = "tmp" & CStr(Int(10000*Rnd)) & ".bat"
wscript.echo("Extracting: " & Archive)
batname = "tmp" & Strip(Archive) & CStr(Int(10000*Rnd)) & ".bat"
wscript.echo("Extracting: " & Archive & " - using: " & batname)
Set MyFile = fso.CreateTextFile(UtilsDir & batname, True)
MyFile.WriteLine("@" & quote & UtilsDir & "7za.exe" & quote & " x " & quote & Archive & quote & " -y -o" & quote & DestFolder & quote )
MyFile.Close
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论