forked from Chatterino/chatterino2
-
Notifications
You must be signed in to change notification settings - Fork 78
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'upstream/master' into chatterino7
- Loading branch information
Showing
59 changed files
with
1,567 additions
and
541 deletions.
There are no files selected for viewing
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,47 @@ | ||
if (-not (Test-Path -PathType Container Chatterino2)) { | ||
Write-Error "Couldn't find a folder called 'Chatterino2' in the current directory."; | ||
exit 1 | ||
} | ||
|
||
# Check if we're on a tag | ||
$OldErrorActionPref = $ErrorActionPreference; | ||
$ErrorActionPreference = 'Continue'; | ||
git describe --exact-match --match 'v*' *> $null; | ||
$isTagged = $?; | ||
$ErrorActionPreference = $OldErrorActionPref; | ||
|
||
$defines = $null; | ||
if ($isTagged) { | ||
# This is a release. | ||
# Make sure, any existing `modes` file is overwritten for the user, | ||
# for example when updating from nightly to stable. | ||
Write-Output "" > Chatterino2/modes; | ||
$installerBaseName = "Chatterino.Installer"; | ||
} | ||
else { | ||
Write-Output nightly > Chatterino2/modes; | ||
$defines = "/DIS_NIGHTLY=1"; | ||
$installerBaseName = "Chatterino.Nightly.Installer"; | ||
} | ||
|
||
if ($Env:GITHUB_OUTPUT) { | ||
# This is used in CI when creating the artifact | ||
"C2_INSTALLER_BASE_NAME=$installerBaseName" >> "$Env:GITHUB_OUTPUT" | ||
} | ||
|
||
# Copy vc_redist.x64.exe | ||
if ($null -eq $Env:VCToolsRedistDir) { | ||
Write-Error "VCToolsRedistDir is not set. Forgot to set Visual Studio environment variables?"; | ||
exit 1 | ||
} | ||
Copy-Item "$Env:VCToolsRedistDir\vc_redist.x64.exe" .; | ||
|
||
# Build the installer | ||
ISCC ` | ||
/DWORKING_DIR="$($pwd.Path)\" ` | ||
/DINSTALLER_BASE_NAME="$installerBaseName" ` | ||
$defines ` | ||
/O. ` | ||
"$PSScriptRoot\chatterino-installer.iss"; | ||
|
||
Move-Item "$installerBaseName.exe" "$installerBaseName$($Env:VARIANT_SUFFIX).exe" |
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,87 @@ | ||
; Script generated by the Inno Setup Script Wizard. | ||
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES! | ||
|
||
#define MyAppName "Chatterino" | ||
#define MyAppVersion "2.4.4" | ||
#define MyAppPublisher "Chatterino Team" | ||
#define MyAppURL "https://www.chatterino.com" | ||
#define MyAppExeName "chatterino.exe" | ||
|
||
; used in build-installer.ps1 | ||
; if set, must end in a backslash | ||
#ifndef WORKING_DIR | ||
#define WORKING_DIR "" | ||
#endif | ||
|
||
[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={{F5FE6614-04D4-4D32-8600-0ABA0AC113A4} | ||
AppName={#MyAppName} | ||
AppVersion={#MyAppVersion} | ||
VersionInfoVersion={#MyAppVersion} | ||
AppVerName={#MyAppName} {#MyAppVersion} | ||
AppPublisher={#MyAppPublisher} | ||
AppPublisherURL={#MyAppURL} | ||
AppSupportURL={#MyAppURL} | ||
AppUpdatesURL={#MyAppURL} | ||
DefaultDirName={autopf}\{#MyAppName} | ||
DisableProgramGroupPage=yes | ||
ArchitecturesInstallIn64BitMode=x64 | ||
;Uncomment the following line to run in non administrative install mode (install for current user only.) | ||
;PrivilegesRequired=lowest | ||
PrivilegesRequiredOverridesAllowed=dialog | ||
OutputDir=out | ||
; This is defined by the build-installer.ps1 script, | ||
; but kept optional for regular use. | ||
#ifdef INSTALLER_BASE_NAME | ||
OutputBaseFilename={#INSTALLER_BASE_NAME} | ||
#else | ||
OutputBaseFilename=Chatterino.Installer | ||
#endif | ||
Compression=lzma | ||
SolidCompression=yes | ||
WizardStyle=modern | ||
UsePreviousTasks=no | ||
UninstallDisplayIcon={app}\{#MyAppExeName} | ||
RestartIfNeededByRun=no | ||
|
||
[Languages] | ||
Name: "english"; MessagesFile: "compiler:Default.isl" | ||
|
||
#ifdef IS_NIGHTLY | ||
[Messages] | ||
SetupAppTitle=Setup (Nightly) | ||
SetupWindowTitle=Setup - %1 (Nightly) | ||
#endif | ||
|
||
[Tasks] | ||
Name: "vcredist"; Description: "Install the required Visual C++ 2015/2017/2019/2022 Redistributable"; | ||
; GroupDescription: "{cm:AdditionalIcons}"; | ||
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; Flags: unchecked | ||
Name: "freshinstall"; Description: "Fresh install (delete old settings/logs)"; Flags: unchecked | ||
|
||
[Files] | ||
Source: "{#WORKING_DIR}Chatterino2\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs | ||
Source: "{#WORKING_DIR}vc_redist.x64.exe"; DestDir: "{tmp}"; Tasks: vcredist; | ||
; 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] | ||
; VC++ redistributable | ||
Filename: {tmp}\vc_redist.x64.exe; Parameters: "/install /passive /norestart"; StatusMsg: "Installing 64-bit Windows Universal Runtime..."; Flags: waituntilterminated; Tasks: vcredist | ||
; Run chatterino | ||
Filename: "{app}\{#MyAppExeName}"; Description: "{cm:LaunchProgram,{#StringChange(MyAppName, '&', '&&')}}"; Flags: nowait postinstall skipifsilent | ||
|
||
[InstallDelete] | ||
; Delete cache on install | ||
Type: filesandordirs; Name: "{userappdata}\Chatterino2\Cache" | ||
; Delete %appdata%\Chatterino2 on freshinstall | ||
Type: filesandordirs; Name: "{userappdata}\Chatterino2"; Tasks: freshinstall | ||
|
||
[UninstallDelete] | ||
; Delete cache on uninstall | ||
Type: filesandordirs; Name: "{userappdata}\Chatterino2\Cache" |
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,14 @@ | ||
# If a commit modifies a ton of files and doesn't really contribute to the | ||
# output of git-blame, please add it here | ||
# | ||
# Don't add commits from the same PR you are creating. We squash PRs into a | ||
# single commit, so references to those commits will be lost | ||
# | ||
# 2018 - changed to 80 max column | ||
f71ff08e686ae76c3dd4084d0f05f27ba9b3fdcb | ||
# | ||
# 2018 - added brace wrapping after if and for | ||
e259b9e39f46f3cb0e4838c988d4f320a03dfaa4 | ||
# | ||
# 2019 - Normalize line endings in already existing files | ||
b06eb9df835c25154899fbcf43e9b37addcea1b1 |
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 |
---|---|---|
|
@@ -100,15 +100,15 @@ jobs: | |
|
||
- name: Install Qt5 | ||
if: startsWith(matrix.qt-version, '5.') | ||
uses: jurplel/install-qt-action@v3.2.1 | ||
uses: jurplel/install-qt-action@v3.3.0 | ||
with: | ||
cache: true | ||
cache-key-prefix: ${{ runner.os }}-QtCache-${{ matrix.qt-version }}-v2 | ||
version: ${{ matrix.qt-version }} | ||
|
||
- name: Install Qt6 | ||
if: startsWith(matrix.qt-version, '6.') | ||
uses: jurplel/install-qt-action@v3.2.1 | ||
uses: jurplel/install-qt-action@v3.3.0 | ||
with: | ||
cache: true | ||
cache-key-prefix: ${{ runner.os }}-QtCache-${{ matrix.qt-version }}-v2 | ||
|
@@ -284,7 +284,7 @@ jobs: | |
|
||
- name: clang-tidy review | ||
if: matrix.clang-tidy-review && github.event_name == 'pull_request' | ||
uses: ZedThree/[email protected].2 | ||
uses: ZedThree/[email protected].3 | ||
with: | ||
build_dir: build-clang-tidy | ||
config_file: ".clang-tidy" | ||
|
@@ -311,7 +311,7 @@ jobs: | |
- name: clang-tidy-review upload | ||
if: matrix.clang-tidy-review && github.event_name == 'pull_request' | ||
uses: ZedThree/clang-tidy-review/[email protected].2 | ||
uses: ZedThree/clang-tidy-review/[email protected].3 | ||
|
||
- name: Package - AppImage (Ubuntu) | ||
if: startsWith(matrix.os, 'ubuntu-22.04') && !matrix.skip-artifact | ||
|
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,56 @@ | ||
name: Create installer | ||
|
||
on: | ||
workflow_run: | ||
workflows: ["Build"] | ||
types: [completed] | ||
# make sure this only runs on the default branch | ||
branches: [master] | ||
workflow_dispatch: | ||
|
||
jobs: | ||
create-installer: | ||
runs-on: windows-latest | ||
# Only run manually or when a build succeeds | ||
if: ${{ github.event_name == 'workflow_dispatch' || github.event.workflow_run.conclusion == 'success' }} | ||
strategy: | ||
matrix: | ||
qt-version: [5.15.2, 6.5.0] | ||
env: | ||
VARIANT_SUFFIX: ${{ startsWith(matrix.qt-version, '6.') && '.EXPERIMENTAL-Qt6' || '' }} | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 # allows for tags access | ||
|
||
- name: Download artifact | ||
uses: dawidd6/action-download-artifact@v2 | ||
with: | ||
workflow: build.yml | ||
name: chatterino-windows-x86-64-Qt-${{ matrix.qt-version }}.zip | ||
path: build/ | ||
|
||
- name: Unzip | ||
run: 7z e -spf chatterino-windows-x86-64-Qt-${{ matrix.qt-version }}.zip | ||
working-directory: build | ||
|
||
- name: Install InnoSetup | ||
run: choco install innosetup | ||
|
||
- name: Add InnoSetup to path | ||
run: echo "C:\Program Files (x86)\Inno Setup 6\" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append | ||
|
||
- name: Enable Developer Command Prompt | ||
uses: ilammy/[email protected] | ||
|
||
- name: Build installer | ||
id: build-installer | ||
working-directory: build | ||
run: ..\.CI\build-installer.ps1 | ||
shell: powershell | ||
|
||
- name: Upload installer | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
path: build/${{ steps.build-installer.outputs.C2_INSTALLER_BASE_NAME }}${{ env.VARIANT_SUFFIX }}.exe | ||
name: ${{ steps.build-installer.outputs.C2_INSTALLER_BASE_NAME }}${{ env.VARIANT_SUFFIX }}.exe |
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 |
---|---|---|
|
@@ -12,6 +12,6 @@ jobs: | |
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: ZedThree/clang-tidy-review/[email protected].2 | ||
- uses: ZedThree/clang-tidy-review/[email protected].3 | ||
with: | ||
lgtm_comment_body: "" |
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
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
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
Submodule miniaudio
updated
21 files
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.