-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
task: Configured Windows subsystem, adjust binary settings, and add a…
…sset embedding & installation scripts
- Loading branch information
1 parent
4b8886a
commit 09e361c
Showing
10 changed files
with
315 additions
and
19 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,81 @@ | ||
; ******************************************************* | ||
; * * | ||
; * RustCraft Setup Script x64 * | ||
; * * | ||
; * NOTES FOR USERS: * | ||
; * 1. License File: * | ||
; * Replace `C:\path\to\LICENSE.txt` with the * | ||
; * actual path to your license file. * | ||
; * * | ||
; * 2. Setup Icon File: * | ||
; * Replace `C:\path\to\icon.ico` with the actual * | ||
; * path to your icon file. * | ||
; * * | ||
; * 3. Source Files: * | ||
; * Replace `C:\path\to\release\rustcraft.exe` * | ||
; * and `C:\path\to\assets\*` with the actual * | ||
; * paths to the executable and assets. * | ||
; * * | ||
; * 4. Output Base Filename: * | ||
; * This sets the name of the output installer * | ||
; * file to `RustCraft_Installation_Script_x64.exe` * | ||
; * Adjust as necessary. * | ||
; * * | ||
; ******************************************************* | ||
|
||
; Script generated by the Inno Setup Script Wizard. | ||
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES! | ||
|
||
#define MyAppName "Rustcraft" | ||
#define MyAppVersion "0.8.0-alpha" | ||
#define MyAppPublisher "franwbu" | ||
#define MyAppURL "https://www.franwbu.com/" | ||
#define MyAppExeName "Rustcraft.exe" | ||
|
||
[Setup] | ||
; NOTE: The value of AppId uniquely identifies this application. Do not use the same AppId value in installers for other applications. | ||
; (To generate a new GUID, click Tools | Generate GUID inside the IDE.) | ||
AppId={{5879C06F-7B45-4878-BE15-9C7FE0CBD477}} | ||
AppName={#MyAppName} | ||
AppVersion={#MyAppVersion} | ||
;AppVerName={#MyAppName} {#MyAppVersion} | ||
AppPublisher={#MyAppPublisher} | ||
AppPublisherURL={#MyAppURL} | ||
AppSupportURL={#MyAppURL} | ||
AppUpdatesURL={#MyAppURL} | ||
DefaultDirName={autopf}\{#MyAppName} | ||
; "ArchitecturesAllowed=x64compatible" specifies that Setup cannot run | ||
; on anything but x64 and Windows 11 on Arm. | ||
ArchitecturesAllowed=x64compatible | ||
; "ArchitecturesInstallIn64BitMode=x64compatible" requests that the | ||
; install be done in "64-bit mode" on x64 or Windows 11 on Arm, | ||
; meaning it should use the native 64-bit Program Files directory and | ||
; the 64-bit view of the registry. | ||
ArchitecturesInstallIn64BitMode=x64compatible | ||
DisableProgramGroupPage=yes | ||
LicenseFile=C:\path\to\LICENSE.txt | ||
; Remove the following line to run in administrative install mode (install for all users.) | ||
PrivilegesRequired=lowest | ||
OutputBaseFilename=RustCraft_Installation_Script_x64 | ||
SetupIconFile=C:\path\to\icon.ico | ||
Compression=lzma | ||
SolidCompression=yes | ||
WizardStyle=modern | ||
|
||
[Languages] | ||
Name: "english"; MessagesFile: "compiler:Default.isl" | ||
|
||
[Tasks] | ||
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked | ||
|
||
[Files] | ||
Source: "C:\path\to\release\rustcraft.exe"; DestDir: "{app}"; Flags: ignoreversion | ||
Source: "C:\path\to\assets\*"; DestDir: "{app}\assets"; Flags: recursesubdirs createallsubdirs | ||
; NOTE: Don't use "Flags: ignoreversion" on any shared system files | ||
|
||
[Icons] | ||
Name: "{autoprograms}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}" | ||
Name: "{autodesktop}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; Tasks: desktopicon | ||
|
||
[Run] | ||
Filename: "{app}\{#MyAppExeName}"; Description: "{cm:LaunchProgram,{#StringChange(MyAppName, '&', '&&')}}"; Flags: nowait postinstall skipifsilent |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
; ******************************************************* | ||
; * * | ||
; * RustCraft Setup Script x86 * | ||
; * * | ||
; * NOTES FOR USERS: * | ||
; * 1. License File: * | ||
; * Replace `C:\path\to\LICENSE.txt` with the * | ||
; * actual path to your license file. * | ||
; * * | ||
; * 2. Setup Icon File: * | ||
; * Replace `C:\path\to\icon.ico` with the actual * | ||
; * path to your icon file. * | ||
; * * | ||
; * 3. Source Files: * | ||
; * Replace `C:\path\to\release\rustcraft.exe` * | ||
; * and `C:\path\to\assets\*` with the actual * | ||
; * paths to the executable and assets. * | ||
; * * | ||
; * 4. Output Base Filename: * | ||
; * This sets the name of the output installer * | ||
; * file to `RustCraft_Installation_Script_x64.exe` * | ||
; * Adjust as necessary. * | ||
; * * | ||
; ******************************************************* | ||
|
||
; Script generated by the Inno Setup Script Wizard. | ||
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES! | ||
|
||
#define MyAppName "Rustcraft" | ||
#define MyAppVersion "0.8.0-alpha" | ||
#define MyAppPublisher "franwbu" | ||
#define MyAppURL "https://www.franwbu.com/" | ||
#define MyAppExeName "Rustcraft.exe" | ||
|
||
[Setup] | ||
; NOTE: The value of AppId uniquely identifies this application. Do not use the same AppId value in installers for other applications. | ||
; (To generate a new GUID, click Tools | Generate GUID inside the IDE.) | ||
AppId={{5879C06F-7B45-4878-BE15-9C7FE0CBD477}} | ||
AppName={#MyAppName} | ||
AppVersion={#MyAppVersion} | ||
;AppVerName={#MyAppName} {#MyAppVersion} | ||
AppPublisher={#MyAppPublisher} | ||
AppPublisherURL={#MyAppURL} | ||
AppSupportURL={#MyAppURL} | ||
AppUpdatesURL={#MyAppURL} | ||
DefaultDirName={autopf}\{#MyAppName} | ||
; "ArchitecturesAllowed=x86" specifies that Setup cannot run on anything but x86. | ||
ArchitecturesAllowed=x86 | ||
; "ArchitecturesInstallIn64BitMode=x86" requests that the install be done in "32-bit mode" on x86. | ||
ArchitecturesInstallIn64BitMode=x86 | ||
DisableProgramGroupPage=yes | ||
LicenseFile=C:\path\to\LICENSE.txt | ||
; Remove the following line to run in administrative install mode (install for all users.) | ||
PrivilegesRequired=lowest | ||
OutputBaseFilename=RustCraft_Installation_Script_x86 | ||
SetupIconFile=C:\path\to\icon.ico | ||
Compression=lzma | ||
SolidCompression=yes | ||
WizardStyle=modern | ||
|
||
[Languages] | ||
Name: "english"; MessagesFile: "compiler:Default.isl" | ||
|
||
[Tasks] | ||
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked | ||
|
||
[Files] | ||
Source: "C:\path\to\release\rustcraft.exe"; DestDir: "{app}"; Flags: ignoreversion | ||
Source: "C:\path\to\assets\*"; DestDir: "{app}\assets"; Flags: recursesubdirs createallsubdirs | ||
; NOTE: Don't use "Flags: ignoreversion" on any shared system files | ||
|
||
[Icons] | ||
Name: "{autoprograms}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}" | ||
Name: "{autodesktop}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; Tasks: desktopicon | ||
|
||
[Run] | ||
Filename: "{app}\{#MyAppExeName}"; Description: "{cm:LaunchProgram,{#StringChange(MyAppName, '&', '&&')}}"; Flags: nowait postinstall skipifsilent |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
use rust_embed::RustEmbed; | ||
|
||
#[derive(RustEmbed)] | ||
#[folder = "assets/"] | ||
struct Assets; | ||
|
||
pub fn get_asset(name: &str) -> Option<Vec<u8>> { | ||
Assets::get(name).map(|file| file.data.into_owned()) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.