Compare commits
10 commits
main
...
dev/migrie
Author | SHA1 | Date | |
---|---|---|---|
c5e20398db | |||
46cca6ba57 | |||
c064b58a78 | |||
32be2d4d6c | |||
559c68079e | |||
44d23f4fce | |||
db0cd1f587 | |||
9d2c3ec2dd | |||
87571fb5d8 | |||
ae02a9c104 |
|
@ -5,6 +5,7 @@
|
|||
|
||||
#include "../TerminalApp/ColorScheme.h"
|
||||
#include "../TerminalApp/CascadiaSettings.h"
|
||||
#include <winrt/Microsoft.Terminal.TerminalConnection.h>
|
||||
|
||||
using namespace Microsoft::Console;
|
||||
using namespace TerminalApp;
|
||||
|
@ -31,6 +32,7 @@ namespace TerminalAppLocalTests
|
|||
END_TEST_CLASS()
|
||||
|
||||
TEST_METHOD(TryCreateWinRTType);
|
||||
TEST_METHOD(TryCreateConnection);
|
||||
TEST_METHOD(ValidateProfilesExist);
|
||||
TEST_METHOD(ValidateDefaultProfileExists);
|
||||
TEST_METHOD(ValidateDuplicateProfiles);
|
||||
|
@ -56,6 +58,12 @@ namespace TerminalAppLocalTests
|
|||
return root;
|
||||
}
|
||||
|
||||
void SettingsTests::TryCreateConnection()
|
||||
{
|
||||
winrt::Microsoft::Terminal::TerminalConnection::EchoConnection conn{};
|
||||
VERIFY_IS_NOT_NULL(conn);
|
||||
}
|
||||
|
||||
void SettingsTests::TryCreateWinRTType()
|
||||
{
|
||||
winrt::Microsoft::Terminal::Settings::TerminalSettings settings{};
|
||||
|
|
|
@ -3,7 +3,6 @@
|
|||
|
||||
#include "pch.h"
|
||||
|
||||
#include <winrt/Microsoft.Terminal.TerminalControl.h>
|
||||
#include <winrt/TerminalApp.h>
|
||||
|
||||
#include "NonClientIslandWindow.h"
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
<application>
|
||||
<!-- Windows 10 1903 -->
|
||||
<!-- See https://docs.microsoft.com/en-us/windows/apps/desktop/modernize/xaml-islands -->
|
||||
<maxVersionTested Id="10.0.18362.0"/>
|
||||
<maxversiontested Id="10.0.18362.0"/>
|
||||
<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}" />
|
||||
</application>
|
||||
</compatibility>
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
#include "pch.h"
|
||||
#include "AppHost.h"
|
||||
#include "resource.h"
|
||||
// #include <winrt/Microsoft.Terminal.TerminalConnection.h>
|
||||
|
||||
using namespace winrt;
|
||||
using namespace Windows::UI;
|
||||
|
@ -107,6 +108,8 @@ int __stdcall wWinMain(HINSTANCE, HINSTANCE, LPWSTR, int)
|
|||
// provides an implementation of Windows.UI.Xaml.Application.
|
||||
AppHost host;
|
||||
|
||||
// winrt::Microsoft::Terminal::TerminalConnection::EchoConnection conn{};
|
||||
|
||||
// !!! LOAD BEARING !!!
|
||||
// This is _magic_. Do the initial loading of our settings *BEFORE* we
|
||||
// initialize our COM apartment type. This is because the Windows.Storage
|
||||
|
|
54
tools/openterm.cmd
Normal file
54
tools/openterm.cmd
Normal file
|
@ -0,0 +1,54 @@
|
|||
@echo off
|
||||
|
||||
rem openterm - launch the Windows Terminal binary
|
||||
rem Runs the windowsterminal.exe binary generated by the build in the debug directory.
|
||||
rem Passes any args along.
|
||||
|
||||
setlocal
|
||||
set _last_build_bin=%OPENCON%\bin\%ARCH%\%_LAST_BUILD_CONF%
|
||||
set _last_build=%OPENCON%\%ARCH%\%_LAST_BUILD_CONF%
|
||||
set _package_root="%OPENCON%\src\cascadia\CascadiaPackage"
|
||||
set _package_obj=%_package_root%\obj\%ARCH%\%_LAST_BUILD_CONF%
|
||||
set _package_output=%_package_root%\bin\%ARCH%\%_LAST_BUILD_CONF%
|
||||
|
||||
if not exist %_last_build%\WindowsTerminal.exe (
|
||||
echo Could not locate the WindowsTerminal.exe in %_last_build%. Double check that it has been built and try again.
|
||||
goto :eof
|
||||
)
|
||||
|
||||
set _r=%random%
|
||||
set copy_dir=OpenConsole\%_r%\WindowsTerminal
|
||||
rem Generate a unique name, so that we can debug multiple revisions of the binary at the same time if needed.
|
||||
|
||||
(xcopy /Y %_last_build_bin%\OpenConsole.exe %TEMP%\%copy_dir%\conhost.exe*) > nul
|
||||
(xcopy /Y %_last_build_bin%\console.dll %TEMP%\%copy_dir%\console.dll*) > nul
|
||||
|
||||
(xcopy /Y %_last_build%\*.dll %TEMP%\%copy_dir%\*.dll*) > nul
|
||||
(xcopy /Y %_last_build%\*.xbf %TEMP%\%copy_dir%\*.xbf*) > nul
|
||||
(xcopy /Y %_last_build%\WindowsTerminal.exe %TEMP%\%copy_dir%\WindowsTerminal.exe*) > nul
|
||||
|
||||
rem If the resources.pri file is older than WindowsTerminal.exe binary, than we
|
||||
rem definitely need to rebuild it. This step will only work once the
|
||||
rem CascadiaPackage has been built once! Instead of trying to totally reverse
|
||||
rem engineer the wapproj MakePri machinery, we're just going to assume that 99%
|
||||
rem of the work was already done for us:
|
||||
|
||||
rem @echo on
|
||||
rem set _need_to_build_resources=1
|
||||
rem if (%_need_to_build_resources%)==(1) (
|
||||
rem "C:\Program Files (x86)\Windows Kits\10\bin\10.0.18362.0\x64\MakePri.exe" ^
|
||||
rem New -ProjectRoot %_package_root%\ ^
|
||||
rem -ConfigXml %_package_obj%\priconfig.xml ^
|
||||
rem -OutputFile %_package_output%\resources.pri ^
|
||||
rem -IndexName WindowsTerminalDev ^
|
||||
rem -Verbose -Overwrite
|
||||
rem )
|
||||
|
||||
rem Copy the resources form the package project to the same directory too. We
|
||||
rem need this to be able to launch. TODO: Find out how to generate this if we're
|
||||
rem _only_ building the WindowsTerminal project.
|
||||
(xcopy /Y %_package_output%\resources.pri %TEMP%\%copy_dir%\resources.pri*) > nul
|
||||
|
||||
rem start %TEMP%\%copy_dir%\WindowsTerminal.exe %*
|
||||
start %TEMP%\%copy_dir%\
|
||||
echo Launching %TEMP%\%copy_dir%\WindowsTerminal.exe...
|
Loading…
Reference in a new issue