@@ -62,6 +62,19 @@ namespace epochnamespace::updater
6262 export inline const std::string PROJECT_PACKAGED_VERSION =
6363 epochnamespace::GetPackagedVersionString ();
6464
65+ export inline constexpr std::string_view WINDOWS_RUNTIME_BINARY_ASSET =
66+ " epoch_win10_x64.zip" ;
67+ export inline constexpr std::string_view LINUX_RUNTIME_BINARY_ASSET =
68+ " epoch_linux_x64.tar.gz" ;
69+ export inline constexpr std::string_view WINDOWS_BOOTSTRAP_BINARY_ASSET =
70+ " epoch_updater_shell_only_win10_x64.zip" ;
71+ export inline constexpr std::string_view LINUX_BOOTSTRAP_BINARY_ASSET =
72+ " epoch_updater_shell_only_linux_x64.tar.gz" ;
73+ export inline constexpr std::string_view WINDOWS_VERSION_ASSET =
74+ " version_windows.txt" ;
75+ export inline constexpr std::string_view LINUX_VERSION_ASSET =
76+ " version_linux.txt" ;
77+
6578 // ─────────────────────────────────────────
6679 // Runtime / source build metadata
6780 // ─────────────────────────────────────────
@@ -154,13 +167,13 @@ namespace epochnamespace::updater
154167 switch (platform::current_platform ())
155168 {
156169 case platform::RuntimePlatform::Windows:
157- return { " windows_version.txt " , " version.txt " };
170+ return { std::string{ WINDOWS_VERSION_ASSET } };
158171 case platform::RuntimePlatform::Linux:
159- return { " linux_version.txt " };
172+ return { std::string{ LINUX_VERSION_ASSET } };
160173 case platform::RuntimePlatform::MacOS:
161174 return { " macos_version.txt" };
162175 default :
163- return { " version.txt " };
176+ return { std::string{ WINDOWS_VERSION_ASSET } };
164177 }
165178 }
166179
@@ -169,13 +182,13 @@ namespace epochnamespace::updater
169182 switch (platform::current_platform ())
170183 {
171184 case platform::RuntimePlatform::Windows:
172- return { " windows_main.zip " , " main.zip " };
185+ return { std::string{ WINDOWS_RUNTIME_BINARY_ASSET } };
173186 case platform::RuntimePlatform::Linux:
174- return { " linux_main.tar.gz " };
187+ return { std::string{ LINUX_RUNTIME_BINARY_ASSET } };
175188 case platform::RuntimePlatform::MacOS:
176189 return { " macos_main.tar.gz" };
177190 default :
178- return { " main.zip " };
191+ return { std::string{ WINDOWS_RUNTIME_BINARY_ASSET } };
179192 }
180193 }
181194
@@ -184,13 +197,13 @@ namespace epochnamespace::updater
184197 switch (platform::current_platform ())
185198 {
186199 case platform::RuntimePlatform::Windows:
187- return " version.txt " ;
200+ return std::string{ WINDOWS_VERSION_ASSET } ;
188201 case platform::RuntimePlatform::Linux:
189- return " linux_version.txt " ;
202+ return std::string{ LINUX_VERSION_ASSET } ;
190203 case platform::RuntimePlatform::MacOS:
191204 return " macos_version.txt" ;
192205 default :
193- return " version.txt " ;
206+ return std::string{ WINDOWS_VERSION_ASSET } ;
194207 }
195208 }
196209
@@ -199,13 +212,28 @@ namespace epochnamespace::updater
199212 switch (platform::current_platform ())
200213 {
201214 case platform::RuntimePlatform::Windows:
202- return " main.zip " ;
215+ return std::string{ WINDOWS_RUNTIME_BINARY_ASSET } ;
203216 case platform::RuntimePlatform::Linux:
204- return " linux_main.tar.gz " ;
217+ return std::string{ LINUX_RUNTIME_BINARY_ASSET } ;
205218 case platform::RuntimePlatform::MacOS:
206219 return " macos_main.tar.gz" ;
207220 default :
208- return " main.zip" ;
221+ return std::string{ WINDOWS_RUNTIME_BINARY_ASSET };
222+ }
223+ }
224+
225+ export inline std::string LATEST_BOOTSTRAP_BINARY_ASSET_NAME ()
226+ {
227+ switch (platform::current_platform ())
228+ {
229+ case platform::RuntimePlatform::Windows:
230+ return std::string{ WINDOWS_BOOTSTRAP_BINARY_ASSET };
231+ case platform::RuntimePlatform::Linux:
232+ return std::string{ LINUX_BOOTSTRAP_BINARY_ASSET };
233+ case platform::RuntimePlatform::MacOS:
234+ return " epoch_updater_shell_only_macos_x64.tar.gz" ;
235+ default :
236+ return std::string{ WINDOWS_BOOTSTRAP_BINARY_ASSET };
209237 }
210238 }
211239
0 commit comments