-
Notifications
You must be signed in to change notification settings - Fork 1.6k
WPF:WINDOWS Added ability to update application installed in Program Files folder #813
Changes from all commits
43d414e
12a2dd5
f30812a
05d0cd4
f73e390
ee0d067
54063fb
6adc3a1
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,6 +1,14 @@ | ||
| <?xml version="1.0" encoding="utf-8"?> | ||
| <?xml version="1.0" encoding="utf-8"?> | ||
| <configuration> | ||
| <startup> | ||
| <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6"/> | ||
| <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6" /> | ||
| </startup> | ||
| <runtime> | ||
| <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> | ||
| <dependentAssembly> | ||
| <assemblyIdentity name="System.Reactive.Core" publicKeyToken="94bc3704cddfc263" culture="neutral" /> | ||
| <bindingRedirect oldVersion="0.0.0.0-3.0.3000.0" newVersion="3.0.3000.0" /> | ||
| </dependentAssembly> | ||
| </assemblyBinding> | ||
| </runtime> | ||
| </configuration> |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,5 +1,5 @@ | ||
| <?xml version="1.0" encoding="utf-8"?> | ||
| <packages> | ||
| <package id="Facebook.Yoga" version="1.0.1-pre" targetFramework="net46" /> | ||
| <package id="Microsoft.ChakraCore" version="1.4.1-preview-00010-42060" targetFramework="net46" developmentDependency="true" /> | ||
| <package id="Facebook.Yoga" version="1.2.0-pre1" targetFramework="net46" /> | ||
| <package id="Microsoft.ChakraCore" version="1.4.1" targetFramework="net46" developmentDependency="true" /> | ||
| </packages> |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,10 +1,10 @@ | ||
| using System; | ||
| using System.Diagnostics; | ||
| using System.Linq; | ||
| using System.IO; | ||
| #if WINDOWS_UWP | ||
| using Windows.ApplicationModel; | ||
| using Windows.Storage; | ||
| #else | ||
| using System.IO; | ||
| #endif | ||
|
|
||
| namespace CodePush.ReactNative | ||
|
|
@@ -38,8 +38,7 @@ internal static string GetAppVersion() | |
| #if WINDOWS_UWP | ||
| return Package.Current.Id.Version.Major + "." + Package.Current.Id.Version.Minor + "." + Package.Current.Id.Version.Build; | ||
| #else | ||
| var version = FileVersionInfo.GetVersionInfo(Environment.GetCommandLineArgs()[0]); | ||
| return $"{version.FileMajorPart}.{version.FileMinorPart}.{version.FileBuildPart}"; | ||
| return applicationInfo.Version; | ||
| #endif | ||
| } | ||
|
|
||
|
|
@@ -61,13 +60,10 @@ internal static string GetAssetsBundlePrefix() | |
| #endif | ||
| } | ||
|
|
||
| internal static string GetFileBundlePrefix() | ||
| internal static string ExtractSubFolder(string fullPath) | ||
| { | ||
| #if WINDOWS_UWP | ||
| return CodePushConstants.FileBundlePrefix; | ||
| #else | ||
| return GetAppFolder(); | ||
| #endif | ||
| var codePushSubPathArray = fullPath.Split(Path.DirectorySeparatorChar); | ||
| return String.Join("/", codePushSubPathArray.SkipWhile((value, index) => codePushSubPathArray.Length - index > 4).ToArray()); | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @abodalevsky, could you please clarify what means number 4?
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 4 means last 4 segments of the path where JS bundle is located. The idea of the change was to unify the calculation of js bundle file location for UWP and WPF. While they have different prefix but last 4 segments are the same for both implementations. |
||
| } | ||
|
|
||
| } | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@abodalevsky, do I get it right if
FileBundlePrefixconst is used inGetJavaScriptBundleFileAsyncmethod only, so there are no possible issues with this change?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It should be fine I have checked it before commit