From 0ac22704fae8cf34755dff2e13d7293a9c2523f3 Mon Sep 17 00:00:00 2001 From: Juha Karjalainen Date: Mon, 8 Oct 2018 15:20:07 +0300 Subject: Provisioning: Disable powershell quickedit Powershell quickedit causes powershell window freeze until quickedit mode is exited by pressing enter. For some reason quickedit mode get's activated during build. This causes time out as agent does not get any output from processes. Task-number: QTQAINFRA-2263 Change-Id: I2878cc7a39bae504f826c5622cc5817fd227d7f0 Reviewed-by: Heikki Halmet --- coin/provisioning/common/windows/disable-quickedit.ps1 | 13 +++++++++++++ .../qtci-windows-10-x86/85-disable_quickedit_powershell.ps1 | 1 + .../85-disable_quickedit_powershell.ps1 | 1 + 3 files changed, 15 insertions(+) create mode 100644 coin/provisioning/common/windows/disable-quickedit.ps1 create mode 100644 coin/provisioning/qtci-windows-10-x86/85-disable_quickedit_powershell.ps1 create mode 100644 coin/provisioning/qtci-windows-10-x86_64/85-disable_quickedit_powershell.ps1 diff --git a/coin/provisioning/common/windows/disable-quickedit.ps1 b/coin/provisioning/common/windows/disable-quickedit.ps1 new file mode 100644 index 00000000..09e18503 --- /dev/null +++ b/coin/provisioning/common/windows/disable-quickedit.ps1 @@ -0,0 +1,13 @@ +# Disabling cmd.exe and powershell QuickEdit && InsertMode +# +# These two can freeze console window on win10 sometimes +# manual recovery is pressing enter on console window + +. "$PSScriptRoot\helpers.ps1" + +Run-Executable "reg.exe" "ADD `"HKEY_CURRENT_USER\Console`" /V QuickEdit /T REG_dWORD /D 0 /F" +Run-Executable "reg.exe" "ADD `"HKEY_CURRENT_USER\Console`" /V InsertMode /T REG_dWORD /D 0 /F" +Run-Executable "reg.exe" "ADD `"HKEY_CURRENT_USER\Console\%SystemRoot%_System32_WindowsPowerShell_v1.0_powershell.exe`" /V QuickEdit /T REG_dWORD /D 0 /F" +Run-Executable "reg.exe" "ADD `"HKEY_CURRENT_USER\Console\%SystemRoot%_System32_WindowsPowerShell_v1.0_powershell.exe`" /V InsertMode /T REG_dWORD /D 0 /F" +Run-Executable "reg.exe" "ADD `"HKEY_CURRENT_USER\Console\%SystemRoot%_SysWOW64_WindowsPowerShell_v1.0_powershell.exe`" /V QuickEdit /T REG_dWORD /D 0 /F" +Run-Executable "reg.exe" "ADD `"HKEY_CURRENT_USER\Console\%SystemRoot%_SysWOW64_WindowsPowerShell_v1.0_powershell.exe`" /V InsertMode /T REG_dWORD /D 0 /F" diff --git a/coin/provisioning/qtci-windows-10-x86/85-disable_quickedit_powershell.ps1 b/coin/provisioning/qtci-windows-10-x86/85-disable_quickedit_powershell.ps1 new file mode 100644 index 00000000..547e15a8 --- /dev/null +++ b/coin/provisioning/qtci-windows-10-x86/85-disable_quickedit_powershell.ps1 @@ -0,0 +1 @@ +. "$PSScriptRoot\..\common\windows\disable-quickedit.ps1" diff --git a/coin/provisioning/qtci-windows-10-x86_64/85-disable_quickedit_powershell.ps1 b/coin/provisioning/qtci-windows-10-x86_64/85-disable_quickedit_powershell.ps1 new file mode 100644 index 00000000..547e15a8 --- /dev/null +++ b/coin/provisioning/qtci-windows-10-x86_64/85-disable_quickedit_powershell.ps1 @@ -0,0 +1 @@ +. "$PSScriptRoot\..\common\windows\disable-quickedit.ps1" -- cgit v1.2.3