bat files are converted to sh files, and bugs are fixed.
1 if WScript.Arguments.Count <> 2 then
6 if WScript.Arguments.Item(0) = "lan" then
7 sConnectionName = "ローカル エリア接続"
9 sConnectionName = "ワイヤレス ネットワーク接続"
13 if WScript.Arguments.Item(1) = "enable" then
21 Const sConPaneName = "ネットワーク接続"
23 set shellApp = createobject("shell.application")
24 set oControlPanel = shellApp.Namespace(ssfCONTROLS)
25 set oNetConnections = nothing
27 for each folderitem in oControlPanel.items
28 if folderitem.name = sConPaneName then
29 set oNetConnections = folderitem.getfolder: exit for
33 if oNetConnections is nothing then
37 set oLanConnection = nothing
38 for each folderitem in oNetConnections.items
39 if lcase(folderitem.name) = lcase(sConnectionName) then
40 set oLanConnection = folderitem: exit for
44 if oLanConnection is nothing then
48 for each verb in oLanConnection.verbs
49 if verb.name = sVerb then