From 63847496f14c813a5d80efd5b7de0f1294ffe1e3 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sat, 13 Apr 2024 16:07:11 +0200 Subject: Adding upstream version 3.45.1. Signed-off-by: Daniel Baumann --- vsixtest/App.xaml | 8 + vsixtest/App.xaml.cpp | 120 +++++++ vsixtest/App.xaml.h | 27 ++ vsixtest/Assets/LockScreenLogo.scale-200.png | Bin 0 -> 1430 bytes vsixtest/Assets/SplashScreen.scale-200.png | Bin 0 -> 7700 bytes vsixtest/Assets/Square150x150Logo.scale-200.png | Bin 0 -> 2937 bytes vsixtest/Assets/Square44x44Logo.scale-200.png | Bin 0 -> 1647 bytes ...are44x44Logo.targetsize-24_altform-unplated.png | Bin 0 -> 1255 bytes vsixtest/Assets/StoreLogo.png | Bin 0 -> 1451 bytes vsixtest/Assets/Wide310x150Logo.scale-200.png | Bin 0 -> 3204 bytes vsixtest/MainPage.xaml | 13 + vsixtest/MainPage.xaml.cpp | 53 +++ vsixtest/MainPage.xaml.h | 22 ++ vsixtest/Package.appxmanifest | 49 +++ vsixtest/pch.cpp | 6 + vsixtest/pch.h | 11 + vsixtest/vsixtest.sln | 39 +++ vsixtest/vsixtest.tcl | 373 +++++++++++++++++++++ vsixtest/vsixtest.vcxproj.data | 198 +++++++++++ vsixtest/vsixtest.vcxproj.filters | 57 ++++ vsixtest/vsixtest_TemporaryKey.pfx | Bin 0 -> 2520 bytes 21 files changed, 976 insertions(+) create mode 100644 vsixtest/App.xaml create mode 100644 vsixtest/App.xaml.cpp create mode 100644 vsixtest/App.xaml.h create mode 100644 vsixtest/Assets/LockScreenLogo.scale-200.png create mode 100644 vsixtest/Assets/SplashScreen.scale-200.png create mode 100644 vsixtest/Assets/Square150x150Logo.scale-200.png create mode 100644 vsixtest/Assets/Square44x44Logo.scale-200.png create mode 100644 vsixtest/Assets/Square44x44Logo.targetsize-24_altform-unplated.png create mode 100644 vsixtest/Assets/StoreLogo.png create mode 100644 vsixtest/Assets/Wide310x150Logo.scale-200.png create mode 100644 vsixtest/MainPage.xaml create mode 100644 vsixtest/MainPage.xaml.cpp create mode 100644 vsixtest/MainPage.xaml.h create mode 100644 vsixtest/Package.appxmanifest create mode 100644 vsixtest/pch.cpp create mode 100644 vsixtest/pch.h create mode 100644 vsixtest/vsixtest.sln create mode 100644 vsixtest/vsixtest.tcl create mode 100644 vsixtest/vsixtest.vcxproj.data create mode 100644 vsixtest/vsixtest.vcxproj.filters create mode 100644 vsixtest/vsixtest_TemporaryKey.pfx (limited to 'vsixtest') diff --git a/vsixtest/App.xaml b/vsixtest/App.xaml new file mode 100644 index 0000000..8088902 --- /dev/null +++ b/vsixtest/App.xaml @@ -0,0 +1,8 @@ + + + diff --git a/vsixtest/App.xaml.cpp b/vsixtest/App.xaml.cpp new file mode 100644 index 0000000..c90604a --- /dev/null +++ b/vsixtest/App.xaml.cpp @@ -0,0 +1,120 @@ +// +// App.xaml.cpp +// Implementation of the App class. +// + +#include "pch.h" +#include "MainPage.xaml.h" + +using namespace vsixtest; + +using namespace Platform; +using namespace Windows::ApplicationModel; +using namespace Windows::ApplicationModel::Activation; +using namespace Windows::Foundation; +using namespace Windows::Foundation::Collections; +using namespace Windows::UI::Xaml; +using namespace Windows::UI::Xaml::Controls; +using namespace Windows::UI::Xaml::Controls::Primitives; +using namespace Windows::UI::Xaml::Data; +using namespace Windows::UI::Xaml::Input; +using namespace Windows::UI::Xaml::Interop; +using namespace Windows::UI::Xaml::Media; +using namespace Windows::UI::Xaml::Navigation; + +/// +/// Initializes the singleton application object. This is the first line of authored code +/// executed, and as such is the logical equivalent of main() or WinMain(). +/// +App::App() +{ + InitializeComponent(); + Suspending += ref new SuspendingEventHandler(this, &App::OnSuspending); +} + +/// +/// Invoked when the application is launched normally by the end user. Other entry points +/// will be used such as when the application is launched to open a specific file. +/// +/// Details about the launch request and process. +void App::OnLaunched(Windows::ApplicationModel::Activation::LaunchActivatedEventArgs^ e) +{ + +#if _DEBUG + // Show graphics profiling information while debugging. + if (IsDebuggerPresent()) + { + // Display the current frame rate counters + DebugSettings->EnableFrameRateCounter = true; + } +#endif + + auto rootFrame = dynamic_cast(Window::Current->Content); + + // Do not repeat app initialization when the Window already has content, + // just ensure that the window is active + if (rootFrame == nullptr) + { + // Create a Frame to act as the navigation context and associate it with + // a SuspensionManager key + rootFrame = ref new Frame(); + + rootFrame->NavigationFailed += ref new Windows::UI::Xaml::Navigation::NavigationFailedEventHandler(this, &App::OnNavigationFailed); + + if (e->PreviousExecutionState == ApplicationExecutionState::Terminated) + { + // TODO: Restore the saved session state only when appropriate, scheduling the + // final launch steps after the restore is complete + + } + + if (rootFrame->Content == nullptr) + { + // When the navigation stack isn't restored navigate to the first page, + // configuring the new page by passing required information as a navigation + // parameter + rootFrame->Navigate(TypeName(MainPage::typeid), e->Arguments); + } + // Place the frame in the current Window + Window::Current->Content = rootFrame; + // Ensure the current window is active + Window::Current->Activate(); + } + else + { + if (rootFrame->Content == nullptr) + { + // When the navigation stack isn't restored navigate to the first page, + // configuring the new page by passing required information as a navigation + // parameter + rootFrame->Navigate(TypeName(MainPage::typeid), e->Arguments); + } + // Ensure the current window is active + Window::Current->Activate(); + } +} + +/// +/// Invoked when application execution is being suspended. Application state is saved +/// without knowing whether the application will be terminated or resumed with the contents +/// of memory still intact. +/// +/// The source of the suspend request. +/// Details about the suspend request. +void App::OnSuspending(Object^ sender, SuspendingEventArgs^ e) +{ + (void) sender; // Unused parameter + (void) e; // Unused parameter + + //TODO: Save application state and stop any background activity +} + +/// +/// Invoked when Navigation to a certain page fails +/// +/// The Frame which failed navigation +/// Details about the navigation failure +void App::OnNavigationFailed(Platform::Object ^sender, Windows::UI::Xaml::Navigation::NavigationFailedEventArgs ^e) +{ + throw ref new FailureException("Failed to load Page " + e->SourcePageType.Name); +} diff --git a/vsixtest/App.xaml.h b/vsixtest/App.xaml.h new file mode 100644 index 0000000..5fa8837 --- /dev/null +++ b/vsixtest/App.xaml.h @@ -0,0 +1,27 @@ +// +// App.xaml.h +// Declaration of the App class. +// + +#pragma once + +#include "App.g.h" + +namespace vsixtest +{ + /// + /// Provides application-specific behavior to supplement the default Application class. + /// + ref class App sealed + { + protected: + virtual void OnLaunched(Windows::ApplicationModel::Activation::LaunchActivatedEventArgs^ e) override; + + internal: + App(); + + private: + void OnSuspending(Platform::Object^ sender, Windows::ApplicationModel::SuspendingEventArgs^ e); + void OnNavigationFailed(Platform::Object ^sender, Windows::UI::Xaml::Navigation::NavigationFailedEventArgs ^e); + }; +} diff --git a/vsixtest/Assets/LockScreenLogo.scale-200.png b/vsixtest/Assets/LockScreenLogo.scale-200.png new file mode 100644 index 0000000..735f57a Binary files /dev/null and b/vsixtest/Assets/LockScreenLogo.scale-200.png differ diff --git a/vsixtest/Assets/SplashScreen.scale-200.png b/vsixtest/Assets/SplashScreen.scale-200.png new file mode 100644 index 0000000..023e7f1 Binary files /dev/null and b/vsixtest/Assets/SplashScreen.scale-200.png differ diff --git a/vsixtest/Assets/Square150x150Logo.scale-200.png b/vsixtest/Assets/Square150x150Logo.scale-200.png new file mode 100644 index 0000000..af49fec Binary files /dev/null and b/vsixtest/Assets/Square150x150Logo.scale-200.png differ diff --git a/vsixtest/Assets/Square44x44Logo.scale-200.png b/vsixtest/Assets/Square44x44Logo.scale-200.png new file mode 100644 index 0000000..ce342a2 Binary files /dev/null and b/vsixtest/Assets/Square44x44Logo.scale-200.png differ diff --git a/vsixtest/Assets/Square44x44Logo.targetsize-24_altform-unplated.png b/vsixtest/Assets/Square44x44Logo.targetsize-24_altform-unplated.png new file mode 100644 index 0000000..f6c02ce Binary files /dev/null and b/vsixtest/Assets/Square44x44Logo.targetsize-24_altform-unplated.png differ diff --git a/vsixtest/Assets/StoreLogo.png b/vsixtest/Assets/StoreLogo.png new file mode 100644 index 0000000..7385b56 Binary files /dev/null and b/vsixtest/Assets/StoreLogo.png differ diff --git a/vsixtest/Assets/Wide310x150Logo.scale-200.png b/vsixtest/Assets/Wide310x150Logo.scale-200.png new file mode 100644 index 0000000..288995b Binary files /dev/null and b/vsixtest/Assets/Wide310x150Logo.scale-200.png differ diff --git a/vsixtest/MainPage.xaml b/vsixtest/MainPage.xaml new file mode 100644 index 0000000..7472ad8 --- /dev/null +++ b/vsixtest/MainPage.xaml @@ -0,0 +1,13 @@ + + + + + + diff --git a/vsixtest/MainPage.xaml.cpp b/vsixtest/MainPage.xaml.cpp new file mode 100644 index 0000000..e67dcb8 --- /dev/null +++ b/vsixtest/MainPage.xaml.cpp @@ -0,0 +1,53 @@ +// +// MainPage.xaml.cpp +// Implementation of the MainPage class. +// + +#include "pch.h" +#include "MainPage.xaml.h" +#include "sqlite3.h" + +using namespace vsixtest; + +using namespace Platform; +using namespace Windows::Foundation; +using namespace Windows::Foundation::Collections; +using namespace Windows::UI::Xaml; +using namespace Windows::UI::Xaml::Controls; +using namespace Windows::UI::Xaml::Controls::Primitives; +using namespace Windows::UI::Xaml::Data; +using namespace Windows::UI::Xaml::Input; +using namespace Windows::UI::Xaml::Media; +using namespace Windows::UI::Xaml::Navigation; + +// The Blank Page item template is documented at http://go.microsoft.com/fwlink/?LinkId=402352&clcid=0x409 + +MainPage::MainPage() +{ + InitializeComponent(); + UseSQLite(); +} + +void MainPage::UseSQLite(void) +{ + int rc = SQLITE_OK; + sqlite3 *pDb = nullptr; + + rc = sqlite3_open_v2("test.db", &pDb, + SQLITE_OPEN_READWRITE | SQLITE_OPEN_CREATE, nullptr); + + if (rc != SQLITE_OK) + throw ref new FailureException("Failed to open database."); + + rc = sqlite3_exec(pDb, "VACUUM;", nullptr, nullptr, nullptr); + + if (rc != SQLITE_OK) + throw ref new FailureException("Failed to vacuum database."); + + rc = sqlite3_close(pDb); + + if (rc != SQLITE_OK) + throw ref new FailureException("Failed to close database."); + + pDb = nullptr; +} diff --git a/vsixtest/MainPage.xaml.h b/vsixtest/MainPage.xaml.h new file mode 100644 index 0000000..ea327a3 --- /dev/null +++ b/vsixtest/MainPage.xaml.h @@ -0,0 +1,22 @@ +// +// MainPage.xaml.h +// Declaration of the MainPage class. +// + +#pragma once + +#include "MainPage.g.h" + +namespace vsixtest +{ + /// + /// An empty page that can be used on its own or navigated to within a Frame. + /// + public ref class MainPage sealed + { + public: + MainPage(); + void UseSQLite(void); + + }; +} diff --git a/vsixtest/Package.appxmanifest b/vsixtest/Package.appxmanifest new file mode 100644 index 0000000..106b3f1 --- /dev/null +++ b/vsixtest/Package.appxmanifest @@ -0,0 +1,49 @@ + + + + + + + + + + vsixtest + mistachkin + Assets\StoreLogo.png + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/vsixtest/pch.cpp b/vsixtest/pch.cpp new file mode 100644 index 0000000..97b544e --- /dev/null +++ b/vsixtest/pch.cpp @@ -0,0 +1,6 @@ +// +// pch.cpp +// Include the standard header and generate the precompiled header. +// + +#include "pch.h" diff --git a/vsixtest/pch.h b/vsixtest/pch.h new file mode 100644 index 0000000..b793236 --- /dev/null +++ b/vsixtest/pch.h @@ -0,0 +1,11 @@ +// +// pch.h +// Header for standard system include files. +// + +#pragma once + +#include +#include + +#include "App.xaml.h" diff --git a/vsixtest/vsixtest.sln b/vsixtest/vsixtest.sln new file mode 100644 index 0000000..1ab6e06 --- /dev/null +++ b/vsixtest/vsixtest.sln @@ -0,0 +1,39 @@ +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 14 +VisualStudioVersion = 14.0.24720.0 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "vsixtest", "vsixtest.vcxproj", "{60BB14A5-0871-4656-BC38-4F0958230F9A}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|ARM = Debug|ARM + Debug|x64 = Debug|x64 + Debug|x86 = Debug|x86 + Release|ARM = Release|ARM + Release|x64 = Release|x64 + Release|x86 = Release|x86 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {60BB14A5-0871-4656-BC38-4F0958230F9A}.Debug|ARM.ActiveCfg = Debug|ARM + {60BB14A5-0871-4656-BC38-4F0958230F9A}.Debug|ARM.Build.0 = Debug|ARM + {60BB14A5-0871-4656-BC38-4F0958230F9A}.Debug|ARM.Deploy.0 = Debug|ARM + {60BB14A5-0871-4656-BC38-4F0958230F9A}.Debug|x64.ActiveCfg = Debug|x64 + {60BB14A5-0871-4656-BC38-4F0958230F9A}.Debug|x64.Build.0 = Debug|x64 + {60BB14A5-0871-4656-BC38-4F0958230F9A}.Debug|x64.Deploy.0 = Debug|x64 + {60BB14A5-0871-4656-BC38-4F0958230F9A}.Debug|x86.ActiveCfg = Debug|Win32 + {60BB14A5-0871-4656-BC38-4F0958230F9A}.Debug|x86.Build.0 = Debug|Win32 + {60BB14A5-0871-4656-BC38-4F0958230F9A}.Debug|x86.Deploy.0 = Debug|Win32 + {60BB14A5-0871-4656-BC38-4F0958230F9A}.Release|ARM.ActiveCfg = Release|ARM + {60BB14A5-0871-4656-BC38-4F0958230F9A}.Release|ARM.Build.0 = Release|ARM + {60BB14A5-0871-4656-BC38-4F0958230F9A}.Release|ARM.Deploy.0 = Release|ARM + {60BB14A5-0871-4656-BC38-4F0958230F9A}.Release|x64.ActiveCfg = Release|x64 + {60BB14A5-0871-4656-BC38-4F0958230F9A}.Release|x64.Build.0 = Release|x64 + {60BB14A5-0871-4656-BC38-4F0958230F9A}.Release|x64.Deploy.0 = Release|x64 + {60BB14A5-0871-4656-BC38-4F0958230F9A}.Release|x86.ActiveCfg = Release|Win32 + {60BB14A5-0871-4656-BC38-4F0958230F9A}.Release|x86.Build.0 = Release|Win32 + {60BB14A5-0871-4656-BC38-4F0958230F9A}.Release|x86.Deploy.0 = Release|Win32 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal diff --git a/vsixtest/vsixtest.tcl b/vsixtest/vsixtest.tcl new file mode 100644 index 0000000..5dce821 --- /dev/null +++ b/vsixtest/vsixtest.tcl @@ -0,0 +1,373 @@ +#!/usr/bin/tclsh +# +# This script is used to quickly test a VSIX (Visual Studio Extension) file +# with Visual Studio 2015 on Windows. +# +# PREREQUISITES +# +# 1. This tool is Windows only. +# +# 2. This tool must be executed with "elevated administrator" privileges. +# +# 3. Tcl 8.4 and later are supported, earlier versions have not been tested. +# +# 4. The "sqlite-UWP-output.vsix" file is assumed to exist in the parent +# directory of the directory containing this script. The [optional] first +# command line argument to this script may be used to specify an alternate +# file. However, currently, the file must be compatible with both Visual +# Studio 2015 and the Universal Windows Platform. +# +# 5. The "VERSION" file is assumed to exist in the parent directory of the +# directory containing this script. It must contain a version number that +# matches the VSIX file being tested. +# +# 6. The temporary directory specified in the TEMP or TMP environment variables +# must refer to an existing directory writable by the current user. +# +# 7. The VS140COMNTOOLS environment variable must refer to the Visual Studio +# 2015 common tools directory. +# +# USAGE +# +# The first argument to this script is optional. If specified, it must be the +# name of the VSIX file to test. +# +package require Tcl 8.4 + +proc fail { {error ""} {usage false} } { + if {[string length $error] > 0} then { + puts stdout $error + if {!$usage} then {exit 1} + } + + puts stdout "usage:\ +[file tail [info nameofexecutable]]\ +[file tail [info script]] \[vsixFile\]" + + exit 1 +} + +proc isWindows {} { + # + # NOTE: Returns non-zero only when running on Windows. + # + return [expr {[info exists ::tcl_platform(platform)] && \ + $::tcl_platform(platform) eq "windows"}] +} + +proc isAdministrator {} { + # + # NOTE: Returns non-zero only when running as "elevated administrator". + # + if {[isWindows]} then { + if {[catch {exec -- whoami /groups} groups] == 0} then { + set groups [string map [list \r\n \n] $groups] + + foreach group [split $groups \n] { + # + # NOTE: Match this group line against the "well-known" SID for + # the "Administrators" group on Windows. + # + if {[regexp -- {\sS-1-5-32-544\s} $group]} then { + # + # NOTE: Match this group line against the attributes column + # sub-value that should be present when running with + # elevated administrator credentials. + # + if {[regexp -- {\sEnabled group(?:,|\s)} $group]} then { + return true + } + } + } + } + } + + return false +} + +proc getEnvironmentVariable { name } { + # + # NOTE: Returns the value of the specified environment variable or an empty + # string for environment variables that do not exist in the current + # process environment. + # + return [expr {[info exists ::env($name)] ? $::env($name) : ""}] +} + +proc getTemporaryPath {} { + # + # NOTE: Returns the normalized path to the first temporary directory found + # in the typical set of environment variables used for that purpose + # or an empty string to signal a failure to locate such a directory. + # + set names [list] + + foreach name [list TEMP TMP] { + lappend names [string toupper $name] [string tolower $name] \ + [string totitle $name] + } + + foreach name $names { + set value [getEnvironmentVariable $name] + + if {[string length $value] > 0} then { + return [file normalize $value] + } + } + + return "" +} + +proc appendArgs { args } { + # + # NOTE: Returns all passed arguments joined together as a single string + # with no intervening spaces between arguments. + # + eval append result $args +} + +proc readFile { fileName } { + # + # NOTE: Reads and returns the entire contents of the specified file, which + # may contain binary data. + # + set file_id [open $fileName RDONLY] + fconfigure $file_id -encoding binary -translation binary + set result [read $file_id] + close $file_id + return $result +} + +proc writeFile { fileName data } { + # + # NOTE: Writes the entire contents of the specified file, which may contain + # binary data. + # + set file_id [open $fileName {WRONLY CREAT TRUNC}] + fconfigure $file_id -encoding binary -translation binary + puts -nonewline $file_id $data + close $file_id + return "" +} + +proc putsAndEval { command } { + # + # NOTE: Outputs a command to the standard output channel and then evaluates + # it in the callers context. + # + catch { + puts stdout [appendArgs "Running: " [lrange $command 1 end] ...\n] + } + + return [uplevel 1 $command] +} + +proc isBadDirectory { directory } { + # + # NOTE: Returns non-zero if the directory is empty, does not exist, -OR- is + # not a directory. + # + catch { + puts stdout [appendArgs "Checking directory \"" $directory \"...\n] + } + + return [expr {[string length $directory] == 0 || \ + ![file exists $directory] || ![file isdirectory $directory]}] +} + +proc isBadFile { fileName } { + # + # NOTE: Returns non-zero if the file name is empty, does not exist, -OR- is + # not a regular file. + # + catch { + puts stdout [appendArgs "Checking file \"" $fileName \"...\n] + } + + return [expr {[string length $fileName] == 0 || \ + ![file exists $fileName] || ![file isfile $fileName]}] +} + +# +# NOTE: This is the entry point for this script. +# +set script [file normalize [info script]] + +if {[string length $script] == 0} then { + fail "script file currently being evaluated is unknown" true +} + +if {![isWindows]} then { + fail "this tool only works properly on Windows" +} + +if {![isAdministrator]} then { + fail "this tool must run with \"elevated administrator\" privileges" +} + +set path [file normalize [file dirname $script]] +set argc [llength $argv]; if {$argc > 1} then {fail "" true} + +if {$argc == 1} then { + set vsixFileName [lindex $argv 0] +} else { + set vsixFileName [file join \ + [file dirname $path] sqlite-UWP-output.vsix] +} + +############################################################################### + +if {[isBadFile $vsixFileName]} then { + fail [appendArgs \ + "VSIX file \"" $vsixFileName "\" does not exist"] +} + +set versionFileName [file join [file dirname $path] VERSION] + +if {[isBadFile $versionFileName]} then { + fail [appendArgs \ + "Version file \"" $versionFileName "\" does not exist"] +} + +set projectTemplateFileName [file join $path vsixtest.vcxproj.data] + +if {[isBadFile $projectTemplateFileName]} then { + fail [appendArgs \ + "Project template file \"" $projectTemplateFileName \ + "\" does not exist"] +} + +set envVarName VS140COMNTOOLS +set vsDirectory [getEnvironmentVariable $envVarName] + +if {[isBadDirectory $vsDirectory]} then { + fail [appendArgs \ + "Visual Studio 2015 directory \"" $vsDirectory \ + "\" from environment variable \"" $envVarName \ + "\" does not exist"] +} + +set vsixInstaller [file join \ + [file dirname $vsDirectory] IDE VSIXInstaller.exe] + +if {[isBadFile $vsixInstaller]} then { + fail [appendArgs \ + "Visual Studio 2015 VSIX installer \"" $vsixInstaller \ + "\" does not exist"] +} + +set envVarName ProgramFiles +set programFiles [getEnvironmentVariable $envVarName] + +if {[isBadDirectory $programFiles]} then { + fail [appendArgs \ + "Program Files directory \"" $programFiles \ + "\" from environment variable \"" $envVarName \ + "\" does not exist"] +} + +set msBuild [file join $programFiles MSBuild 14.0 Bin MSBuild.exe] + +if {[isBadFile $msBuild]} then { + fail [appendArgs \ + "MSBuild v14.0 executable file \"" $msBuild \ + "\" does not exist"] +} + +set temporaryDirectory [getTemporaryPath] + +if {[isBadDirectory $temporaryDirectory]} then { + fail [appendArgs \ + "Temporary directory \"" $temporaryDirectory \ + "\" does not exist"] +} + +############################################################################### + +set installLogFileName [appendArgs \ + [file rootname [file tail $vsixFileName]] \ + -install- [pid] .log] + +set commands(1) [list exec [file nativename $vsixInstaller]] + +lappend commands(1) /quiet /norepair +lappend commands(1) [appendArgs /logFile: $installLogFileName] +lappend commands(1) [file nativename $vsixFileName] + +############################################################################### + +set buildLogFileName [appendArgs \ + [file rootname [file tail $vsixFileName]] \ + -build-%configuration%-%platform%- [pid] .log] + +set commands(2) [list exec [file nativename $msBuild]] + +lappend commands(2) [file nativename [file join $path vsixtest.sln]] +lappend commands(2) /target:Rebuild +lappend commands(2) /property:Configuration=%configuration% +lappend commands(2) /property:Platform=%platform% + +lappend commands(2) [appendArgs \ + /logger:FileLogger,Microsoft.Build.Engine\;Logfile= \ + [file nativename [file join $temporaryDirectory \ + $buildLogFileName]] \;Verbosity=diagnostic] + +############################################################################### + +set uninstallLogFileName [appendArgs \ + [file rootname [file tail $vsixFileName]] \ + -uninstall- [pid] .log] + +set commands(3) [list exec [file nativename $vsixInstaller]] + +lappend commands(3) /quiet /norepair +lappend commands(3) [appendArgs /logFile: $uninstallLogFileName] +lappend commands(3) [appendArgs /uninstall:SQLite.UWP.2015] + +############################################################################### + +if {1} then { + catch { + puts stdout [appendArgs \ + "Install log: \"" [file nativename [file join \ + $temporaryDirectory $installLogFileName]] \"\n] + } + + catch { + puts stdout [appendArgs \ + "Build logs: \"" [file nativename [file join \ + $temporaryDirectory $buildLogFileName]] \"\n] + } + + catch { + puts stdout [appendArgs \ + "Uninstall log: \"" [file nativename [file join \ + $temporaryDirectory $uninstallLogFileName]] \"\n] + } +} + +############################################################################### + +if {1} then { + putsAndEval $commands(1) + + set versionNumber [string trim [readFile $versionFileName]] + set data [readFile $projectTemplateFileName] + set data [string map [list %versionNumber% $versionNumber] $data] + + set projectFileName [file join $path vsixtest.vcxproj] + writeFile $projectFileName $data + + set platforms [list x86 x64 ARM] + set configurations [list Debug Release] + + foreach platform $platforms { + foreach configuration $configurations { + putsAndEval [string map [list \ + %platform% $platform %configuration% $configuration] \ + $commands(2)] + } + } + + putsAndEval $commands(3) +} diff --git a/vsixtest/vsixtest.vcxproj.data b/vsixtest/vsixtest.vcxproj.data new file mode 100644 index 0000000..a64584c --- /dev/null +++ b/vsixtest/vsixtest.vcxproj.data @@ -0,0 +1,198 @@ + + + + {60bb14a5-0871-4656-bc38-4f0958230f9a} + vsixtest + en-US + 14.0 + true + Windows Store + 10.0.10586.0 + 10.0.10586.0 + 10.0 + + + + + Debug + ARM + + + Debug + Win32 + + + Debug + x64 + + + Release + ARM + + + Release + Win32 + + + Release + x64 + + + + Application + true + v140 + + + Application + true + v140 + + + Application + true + v140 + + + Application + false + true + v140 + true + + + Application + false + true + v140 + true + + + Application + false + true + v140 + true + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + vsixtest_TemporaryKey.pfx + + + + /bigobj %(AdditionalOptions) + 4453;28204 + + + + + /bigobj %(AdditionalOptions) + 4453;28204 + + + + + /bigobj %(AdditionalOptions) + 4453;28204 + + + + + /bigobj %(AdditionalOptions) + 4453;28204 + + + + + /bigobj %(AdditionalOptions) + 4453;28204 + + + + + /bigobj %(AdditionalOptions) + 4453;28204 + + + + + + App.xaml + + + MainPage.xaml + + + + + Designer + + + Designer + + + + + Designer + + + + + + + + + + + + + + + App.xaml + + + MainPage.xaml + + + Create + Create + Create + Create + Create + Create + + + + + + + + + \ No newline at end of file diff --git a/vsixtest/vsixtest.vcxproj.filters b/vsixtest/vsixtest.vcxproj.filters new file mode 100644 index 0000000..ac1dfca --- /dev/null +++ b/vsixtest/vsixtest.vcxproj.filters @@ -0,0 +1,57 @@ + + + + + 60bb14a5-0871-4656-bc38-4f0958230f9a + + + e6271362-8f96-476d-907f-4da227b02435 + bmp;fbx;gif;jpg;jpeg;tga;tiff;tif;png + + + + + + + + + + + + + + + + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + + + + + + + + + + \ No newline at end of file diff --git a/vsixtest/vsixtest_TemporaryKey.pfx b/vsixtest/vsixtest_TemporaryKey.pfx new file mode 100644 index 0000000..e6787bc Binary files /dev/null and b/vsixtest/vsixtest_TemporaryKey.pfx differ -- cgit v1.2.3