Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

202 lines
6.5 KiB

  1. @Echo Off
  2. Rem #########################################################################
  3. Rem
  4. Rem ��֤ CMD ��չ���Ƿ�������
  5. Rem
  6. if "A%cmdextversion%A" == "AA" (
  7. call cmd /e:on /c netcom40.cmd
  8. ) else (
  9. goto ExtOK
  10. )
  11. goto Done
  12. :ExtOK
  13. Rem #########################################################################
  14. Rem
  15. Rem ����֤ %RootDrive% �Ѿ������ã���Ϊ�����ű����øñ�����
  16. Rem
  17. Call "%SystemRoot%\Application Compatibility Scripts\ChkRoot.Cmd"
  18. If "%_CHKROOT%" == "FAIL" Goto Done
  19. Call "%SystemRoot%\Application Compatibility Scripts\SetPaths.Cmd"
  20. If "%_SETPATHS%" == "FAIL" Goto Done
  21. Rem #########################################################################
  22. Rem
  23. Rem ��ȡ NetScape �汾(4.5x �� 4.0x �IJ�һ��)
  24. Rem
  25. ..\ACRegL "%Temp%\NS4VER.Cmd" NS4VER "HKLM\Software\Netscape\Netscape Navigator" "CurrentVersion" "STRIPCHAR(1"
  26. If Not ErrorLevel 1 Goto Cont0
  27. Echo.
  28. Echo �޷���ע�������� Netscape Communicator 4 �汾��
  29. Echo ����֤ Communicator �Ƿ��Ѿ���װ�����ٴ�
  30. Echo ���������ű���
  31. Echo.
  32. Pause
  33. Goto Done
  34. :Cont0
  35. Call "%Temp%\NS4VER.Cmd"
  36. Del "%Temp%\NS4VER.Cmd" >Nul: 2>&1
  37. if /i "%NS4VER%" LSS "4.5 " goto NS40x
  38. Rem #########################################################################
  39. Rem Netscape 4.5x
  40. Rem
  41. Rem ��ע������ȡ Netscape Communicator 4.5 �İ�װλ�á�
  42. Rem �����Ҳ��������ٶ� Communicator û�а�װ��
  43. Rem ��ʾ������Ϣ��
  44. Rem
  45. ..\ACRegL "%Temp%\NS45.Cmd" NS40INST "HKCU\Software\Netscape\Netscape Navigator\Main" "Install Directory" "Stripchar\1"
  46. If Not ErrorLevel 1 Goto Cont1
  47. Echo.
  48. Echo �޷���ע�������� Netscape Communicator 4.5 ��װλ�á�
  49. Echo ����֤ Communicator �Ƿ��Ѿ���װ�����ٴ�����
  50. Echo �����ű���
  51. Echo.
  52. Pause
  53. Goto Done
  54. :Cont1
  55. Call "%Temp%\NS45.Cmd"
  56. Del "%Temp%\NS45.Cmd" >Nul: 2>&1
  57. Rem #########################################################################
  58. Rem
  59. Rem ���� Com40Usr.Cmd ����ӳĬ�� NetScape �û�Ŀ¼��
  60. Rem �������ӵ� UsrLogn2.Cmd �ű�
  61. Rem
  62. ..\acsr "#NSUSERDIR#" "%ProgramFiles%\Netscape\Users" ..\Logon\Template\Com40Usr.Cmd ..\Logon\Com40Usr.tmp
  63. ..\acsr "#NS40INST#" "%NS40INST%" ..\Logon\Com40Usr.tmp ..\Logon\Com40Usr.tm2
  64. ..\acsr "#NS4VER#" "4.5x" ..\Logon\Com40Usr.tm2 ..\Logon\Com40Usr.Cmd
  65. Rem #########################################################################
  66. Rem
  67. Rem ���� "quick launch" ͼ�굽 Netscape ��װĿ¼�Ա�
  68. Rem �����Ǹ��Ƶ�ÿ���û��������ļ�Ŀ¼��
  69. Rem
  70. If Exist "%UserProfile%\%App_Data%\Microsoft\Internet Explorer\Quick Launch\Netscape Composer.lnk" copy "%UserProfile%\%App_Data%\Microsoft\Internet Explorer\Quick Launch\Netscape Composer.lnk" "%NS40INST%"
  71. If Exist "%UserProfile%\%App_Data%\Microsoft\Internet Explorer\Quick Launch\Netscape Messenger.lnk" copy "%UserProfile%\%App_Data%\Microsoft\Internet Explorer\Quick Launch\Netscape Messenger.lnk" "%NS40INST%"
  72. If Exist "%UserProfile%\%App_Data%\Microsoft\Internet Explorer\Quick Launch\Netscape Navigator.lnk" copy "%UserProfile%\%App_Data%\Microsoft\Internet Explorer\Quick Launch\Netscape Navigator.lnk" "%NS40INST%"
  73. goto DoUsrLogn
  74. :NS40x
  75. Rem #########################################################################
  76. Rem Netscape 4.0x
  77. Rem
  78. Rem ��ע������ȡ Netscape Communicator 4.5 �İ�װλ�á�
  79. Rem �����Ҳ��������ٶ� Communicator û�а�װ��
  80. Rem ��ʾ������Ϣ��
  81. Rem
  82. ..\ACRegL "%Temp%\NS40.Cmd" NS40INST "HKCU\Software\Netscape\Netscape Navigator\Main" "Install Directory" ""
  83. If Not ErrorLevel 1 Goto Cont2
  84. Echo.
  85. Echo �޷���ע�������� Netscape Communicator 4 ��װλ�á�
  86. Echo ����֤ Communicator �Ѿ���װ������������
  87. Echo �����ű���
  88. Echo.
  89. Pause
  90. Goto Done
  91. :Cont2
  92. Call "%Temp%\NS40.Cmd"
  93. Del "%Temp%\NS40.Cmd" >Nul: 2>&1
  94. Rem #########################################################################
  95. Rem
  96. Rem ��Ĭ�������ļ��ӹ���Ա����Ŀ¼���Ƶ�һ��
  97. Rem ��֪λ�á��ڵ�¼�ڼ䣬���������ļ��ᱻ����
  98. Rem ��ÿ���û���Ŀ¼������ȫ��Ĭ�������ļ��Ѵ��ڣ���Ҫ��
  99. Rem ����д�����򣬹���Ա���ܻ����Ժ����������ű�ʱ
  100. Rem �����и�����Ϣ�Ƶ�ȫ��Ĭ�������ļ���
  101. Rem
  102. If Exist %RootDrive%\NS40 Goto Cont3
  103. Echo.
  104. Echo �� %RootDrive%\NS40 ���Ҳ���Ĭ�������ļ���������
  105. Echo �û������ļ�������������һ����Ϊ "Default" �������ļ���
  106. Echo �������������ļ�·������ʾʱ������������ʾ��·����
  107. Echo ��Ҫ��д���ƺ͵����ʼ�������Ŀ���������ڱ��������ļ���
  108. Echo ��������ɾ����������Щ����������������
  109. Echo �����ű���
  110. Echo.
  111. Pause
  112. Goto Done
  113. :Cont3
  114. If Exist "%NS40INST%\DfltProf" Goto Cont4
  115. Xcopy "%RootDrive%\NS40" "%NS40INST%\DfltProf" /E /I /K >NUL: 2>&1
  116. :Cont4
  117. Rem #########################################################################
  118. Rem
  119. Rem ���û������ļ��������ġ���ʼ���˵����ݷ�ʽ
  120. Rem ɾ���û��Ķ�ȡȨ������ֹ��ͨ�û������µ��û�
  121. Rem �����ļ���������Ա���ɿ��������û������ļ���������
  122. Rem
  123. If Not Exist "%COMMON_PROGRAMS%\Netscape Communicator\Utilities\User Profile Manager.Lnk" Goto Cont5
  124. Cacls "%COMMON_PROGRAMS%\Netscape Communicator\Utilities\User Profile Manager.Lnk" /E /R "Authenticated Users" >Nul: 2>&1
  125. Cacls "%COMMON_PROGRAMS%\Netscape Communicator\Utilities\User Profile Manager.Lnk" /E /R "Users" >Nul: 2>&1
  126. Cacls "%COMMON_PROGRAMS%\Netscape Communicator\Utilities\User Profile Manager.Lnk" /E /R "Everyone" >Nul: 2>&1
  127. :Cont5
  128. If Not Exist "%COMMON_PROGRAMS%\Netscape Communicator Professional Edition\Utilities\User Profile Manager.Lnk" Goto Cont6
  129. Cacls "%COMMON_PROGRAMS%\Netscape Communicator Professional Edition\Utilities\User Profile Manager.Lnk" /E /R "Authenticated Users" >Nul: 2>&1
  130. Cacls "%COMMON_PROGRAMS%\Netscape Communicator Professional Edition\Utilities\User Profile Manager.Lnk" /E /R "Users" >Nul: 2>&1
  131. Cacls "%COMMON_PROGRAMS%\Netscape Communicator Professional Edition\Utilities\User Profile Manager.Lnk" /E /R "Everyone" >Nul: 2>&1
  132. :Cont6
  133. Rem #########################################################################
  134. Rem
  135. Rem ���� Com40Usr.Cmd ����ӳʵ�ʰ�װĿ¼��
  136. Rem �������ӵ� UsrLogn2.Cmd �ű�
  137. Rem
  138. ..\acsr "#PROFDIR#" "%NS40INST%\DfltProf" ..\Logon\Template\Com40Usr.Cmd ..\Logon\Com40Usr.tmp
  139. ..\acsr "#NS4VER#" "4.0x" ..\Logon\Com40Usr.tmp ..\Logon\Com40Usr.Cmd
  140. :DoUsrLogn
  141. del ..\Logon\Com40Usr.tmp >Nul: 2>&1
  142. del ..\Logon\Com40Usr.tm2 >Nul: 2>&1
  143. FindStr /I Com40Usr %SystemRoot%\System32\UsrLogn2.Cmd >Nul: 2>&1
  144. If Not ErrorLevel 1 Goto Skip1
  145. Echo Call Com40Usr.Cmd >> %SystemRoot%\System32\UsrLogn2.Cmd
  146. :Skip1
  147. Echo.
  148. Echo Ҫ��֤ Netscape Communicator ���������У��������κ�
  149. Echo Ӧ�ó���֮ǰ��Ŀǰ��¼���û�������ע������
  150. Echo ���µ�¼
  151. Echo.
  152. Echo Netscape Communicator 4 ���û�Ӧ�ó��������ѽ���
  153. Pause
  154. :done