Skip to content

Commit

Permalink
πŸš€: add CI to build and deploy
Browse files Browse the repository at this point in the history
  • Loading branch information
Gamer92000 committed Dec 19, 2022
1 parent 8565a98 commit 9cf68f5
Show file tree
Hide file tree
Showing 22 changed files with 702 additions and 1,195 deletions.
13 changes: 13 additions & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# These are supported funding model platforms

github: Gamer92000
# patreon: # Replace with a single Patreon username
# open_collective: # Replace with a single Open Collective username
# ko_fi: # Replace with a single Ko-fi username
# tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
# community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
# liberapay: # Replace with a single Liberapay username
# issuehunt: # Replace with a single IssueHunt username
# otechie: # Replace with a single Otechie username
# lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry
# custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
21 changes: 21 additions & 0 deletions .github/renovate.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
"extends": [
"config:base"
],
"labels": ["πŸ“Œ dependencies"],
"commitMessagePrefix": "⬆️:",
"commitMessageAction": "Upgrade",
"packageRules": [
{
"updateTypes": ["pin"],
"commitMessagePrefix": "πŸ“Œ:",
"commitMessageAction": "Pin"
},
{
"updateTypes": ["rollback"],
"commitMessagePrefix": "⬇️:",
"commitMessageAction": "Downgrade"
}
]
}
121 changes: 121 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,121 @@
name: Build and Deploy

on:
push:
tags:
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10

jobs:
prebuild:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set Version In deploy/package.ini and src/definitions.h
# Version is the tag name without the v
run: |
sed -i "s/<version>/$(echo ${GITHUB_REF#refs/tags/v})/g" deploy/package.ini
sed -i "s/<version>/$(echo ${GITHUB_REF#refs/tags/v})/g" src/definitions.h
- name: Archive production artifacts
uses: actions/upload-artifact@v3
with:
name: prebuild
path: |
deploy/package.ini
src/definitions.h
build:
strategy:
fail-fast: true
matrix:
os:
- windows-2019
arch:
- x64
- x86
max-parallel: 3
runs-on: ${{ matrix.os }}
needs: prebuild
steps:
- uses: actions/checkout@v3
with:
submodules: true
- name: Download prebuild
uses: actions/download-artifact@v3
with:
name: prebuild
path: .
- uses: ilammy/msvc-dev-cmd@v1
with:
arch: ${{ matrix.arch }}
toolset: 14.0
- uses: actions/setup-python@v4
with:
python-version: '3.10'
architecture: ${{ matrix.arch }}
- name: Install Qt
uses: jurplel/install-qt-action@v3
with:
version: '5.15.2'
host: 'windows'
target: 'desktop'
arch: ${{ matrix.arch == 'x64' && 'win64_msvc2019_64' || 'win32_msvc2019' }}
dir: '${{ github.workspace }}'
cache: true
cache-key-prefix: ${{ runner.os }}
setup-python: 'false'
- name: Setup cmake
uses: jwlawson/[email protected]
- name: Build
run: |
cmake -A ${{ matrix.arch == 'x64' && 'x64' || 'Win32' }} .
cmake --build . --config Release
- name: Rename release (Windows)
if: matrix.os == 'windows-2019'
run: |
mv Release/TelegramBridge.dll TelegramBridge_win${{ matrix.arch == 'x64' && '64' || '32' }}.dll
- name: Archive production artifacts (Windows)
if: matrix.os == 'windows-2019'
uses: actions/upload-artifact@v3
with:
name: ${{ matrix.os }}${{ matrix.arch }}
path: TelegramBridge_win${{ matrix.arch == 'x64' && '64' || '32' }}.dll

release:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Download prebuild
uses: actions/download-artifact@v3
with:
name: prebuild
path: .
- name: Remove old artifacts
uses: geekyeggo/delete-artifact@v2
with:
name: prebuild
- name: Create Tmp Folder
run: |
mkdir -p tmp
- name: Collect artifacts
uses: actions/download-artifact@v3
with:
path: tmp
- name: Move artifacts to release
run: |
mv tmp/**/* deploy/plugins/
- name: Install zip
uses: montudor/action-zip@v1
- name: Zip output
run: zip -qq -r ../TelegramBridge.zip .
working-directory: deploy
- name: Rename release
run: |
mv TelegramBridge.zip TelegramBridge.${{ github.ref_name }}.ts3_plugin
- name: Release
uses: softprops/action-gh-release@v1
with:
files: |
./TelegramBridge.${{ github.ref_name }}.ts3_plugin
draft: false
prerelease: false
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
build
.vscode
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "ts3client-pluginsdk"]
path = ts3client-pluginsdk
url = https://github.com/TeamSpeak-Systems/ts3client-pluginsdk
74 changes: 74 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
###### 2022-12-19 _v3.4_
```
⬆️ Switch to Qt Version 5.15.2
πŸ“„ Switch to MIT License
πŸ“¦οΈ Move updater to GitHub
πŸ‘· Changed C++ toolset from v140_xp to v140
```
___
###### 26.08.2020 _v3.3.2_
```
✨ Add setting to disable the flood timer when using your own bot
(Telegram limits might kick in)
πŸ› Fix URL-encoding for some special characters
✨ Add update checker
```
___
###### 13.06.2020 _v3.3.1_
```
✨ Add an integrated Telegram Bot for ease of use
⚑️ Significantly improved performance and reliability
πŸ› Fix theme changing while the config window is open
```
___
###### 11.06.2020 _v3.3_
```
✨ Add menu item for easier access to the settings
πŸ’„ Significantly improved settings window design when using a custom theme
```
___
###### 08.06.2020 _v3.2.2_
```
πŸ‘· Changed C++ toolset from v142 to v140_xp
```
___
###### 28.03.2020 _v3.2.1_
```
πŸ› Fix a bug that crashed TS client on startup if greeting were enabled
```
___
###### 25.03.2020 _v3.2_
```
✨ Add responses
```
___
###### 10.03.2020 _v3.1.1_
```
✨ Add a setting to ignore own actions
```
___
###### 2020-03-10 _v3.1_
```
πŸ› Minor bugfixes
πŸ’„ New layout for the GUI
```
___
###### 2020-03-09 _v3.0_
```
♻️ Rebuild of backend
πŸ”₯ Remove multi language support
πŸ”₯ Remove useless settings
✨ Add GUI for config
```
___
###### 2019-06-27
```
🌐 Add first multi language support
✨ Add white- / blacklist for client UUIDs
πŸ› Fix url encoding - (added full UTF8 capability)
```
___
###### 2019-06-15
```
✨ Add support for responses from Telegram
```
39 changes: 39 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
cmake_minimum_required(VERSION 3.10)

set(CMAKE_GENERATOR_TOOLSET "v140")
set(CMAKE_VS_PLATFORM_TOOLSET "v140")
# Use this to locate Qt5.12.3 on your development machine
# list(APPEND CMAKE_PREFIX_PATH "H:/Qt/5.12.3/msvc2017_64")
set(CMAKE_INCLUDE_CURRENT_DIR ON)
set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTOUIC ON)

project("TelegramBridge")

message("Looking for Qt...")

find_package(Qt5 REQUIRED Widgets Network)
if (${Qt5_FOUND})
message("Found Qt " ${Qt5_VERSION})
else()
message("Couldn't find Qt")
endif()

include_directories("ts3client-pluginsdk/include")

set(sources
src/config.ui
src/config.cpp
src/plugin.cpp
src/update.ui
src/update.cpp
src/WebComm.cpp
)

add_library(${CMAKE_PROJECT_NAME} SHARED ${sources})

target_link_libraries(
${CMAKE_PROJECT_NAME}
Qt5::Widgets
Qt5::Network
)
Loading

0 comments on commit 9cf68f5

Please sign in to comment.