Skip to content

Commit 612b8d1

Browse files
author
stonebig
committed
cleanup
1 parent a45e9fa commit 612b8d1

File tree

1 file changed

+0
-35
lines changed

1 file changed

+0
-35
lines changed

make.py

Lines changed: 0 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -653,41 +653,6 @@ def _create_batch_scripts(self):
653653
path = conv(self.prepath) + ";%PATH%;" + conv(self.postpath)
654654

655655

656-
self.create_batch_script('Add_or_removeLine.vbs',r"""
657-
'from http://blogs.technet.com/b/heyscriptingguy/archive/2007/09/07/
658-
' how-can-i-remove-any-line-in-a-text-file-that-contains-a-specified-string-value.aspx
659-
If WScript.Arguments.Count <> 3 then
660-
WScript.Echo "usage: Add_or_removeLine.vbs filename word_to_find line_to_add" &_
661-
vbNewLine & "or Add_or_removeLine.vbs filename word_to_find -remove"
662-
WScript.Quit
663-
end If
664-
665-
Set colArgs = WScript.Arguments
666-
Add_or_removeLine colArgs(0), colArgs(1), colArgs(2)
667-
668-
function Add_or_removeLine(strFilename, strFind, strAction)
669-
Set inputFile = CreateObject("Scripting.FileSystemObject").OpenTextFile(strFilename, 1)
670-
a_change = False
671-
Do Until inputFile.AtEndOfStream
672-
strLine = inputFile.ReadLine
673-
If InStr(strLine, strFind) = 0 Then
674-
result_text= result_text & strLine & vbNewLine
675-
else
676-
a_change = True
677-
if strAction <> "-remove" then result_text= result_text & strLine & vbNewLine & strAction & vbNewLine
678-
End If
679-
Loop
680-
inputFile.Close
681-
682-
if a_change then
683-
Set outputFile = CreateObject("Scripting.FileSystemObject").OpenTextFile(strFilename,2,true)
684-
outputFile.Write result_text
685-
outputFile.Close
686-
end if
687-
end function
688-
""")
689-
690-
691656
# Prepare a live patch on python (shame we need it) to have mingw64ok
692657
patch_distutils = r"""
693658

0 commit comments

Comments
 (0)