Skip to content

Commit

Permalink
Modify generate update json
Browse files Browse the repository at this point in the history
  • Loading branch information
KangLin committed Feb 2, 2024
1 parent aa3e6a4 commit 412da1e
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 7 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/msvc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,9 @@ jobs:
working-directory: ${{github.workspace}}\build
run: |
${{github.workspace}}\build\install\bin\FaceRecognizerApp.exe ^
-f "update_windows.xml" ^
-f "update_windows.json" ^
--foc 1 ^
-n "FaceRecognizer_${{env.FaceRecognizer_VERSION}}_${{matrix.qt_arch}}_qt${{matrix.qt_version}}_Setup.exe" ^
-u https://github.com/KangLin/FaceRecognizer/releases/download/${{env.FaceRecognizer_VERSION}}/FaceRecognizer_${{env.FaceRecognizer_VERSION}}_${{matrix.qt_arch}}_qt${{matrix.qt_version}}_Setup.exe;https://sourceforge.net/projects/FaceRecognizer/files/${{env.FaceRecognizer_VERSION}}/FaceRecognizer_${{env.FaceRecognizer_VERSION}}_${{matrix.qt_arch}}_qt${{matrix.qt_version}}_Setup.exe ^
--pf FaceRecognizer_${{env.FaceRecognizer_VERSION}}_${{matrix.qt_arch}}_qt${{matrix.qt_version}}_Setup.exe ^
-m "${{env.FaceRecognizer_VERSION}}"
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/ubuntu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -134,9 +134,11 @@ jobs:
MD5=`md5sum facerecognizer_${{env.FaceRecognizer_VERSION}}_amd64.deb|awk '{print $1}'`
echo "MD5:${MD5}"
/bin/bash /opt/FaceRecognizer/bin/FaceRecognizer.sh \
-f "${{github.workspace}}/update_linux.xml" \
-f "${{github.workspace}}/update_linux.json" \
--foc 1 \
--md5 ${MD5} \
-m "${{env.FaceRecognizer_VERSION}}" \
-n "facerecognizer_${{env.FaceRecognizer_VERSION}}_amd64.deb" \
-u "https://github.com/KangLin/FaceRecognizer/releases/download/v${{env.FaceRecognizer_VERSION}}/facerecognizer_${{env.FaceRecognizer_VERSION}}_amd64.deb;https://sourceforge.net/projects/FaceRecognizer/files/v${{env.FaceRecognizer_VERSION}}/facerecognizer_${{env.FaceRecognizer_VERSION}}_amd64.deb"
- name: Update artifact
Expand Down
2 changes: 1 addition & 1 deletion App/MainWindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
#include <QScreen>
#include <QLoggingCategory>

Q_LOGGING_CATEGORY(log, "main")
static Q_LOGGING_CATEGORY(log, "main")

MainWindow::MainWindow(QWidget *parent) :
QMainWindow(parent),
Expand Down
2 changes: 1 addition & 1 deletion App/RecognizerThread.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

#include <QLoggingCategory>

Q_DECLARE_LOGGING_CATEGORY(log)
static Q_LOGGING_CATEGORY(log, "Thread")

CRecognizerThread::CRecognizerThread(CManageRecognizerVideo *parent) : QThread()
{
Expand Down
10 changes: 7 additions & 3 deletions App/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
*/

#include <QApplication>
#include <QLoggingCategory>
#if defined(Q_OS_ANDROID)
#include <QtAndroidExtras/QtAndroid>
#endif
Expand All @@ -15,7 +16,7 @@
#include "FrmUpdater/FrmUpdater.h"
#endif

Q_DECLARE_LOGGING_CATEGORY(log)
static Q_LOGGING_CATEGORY(log, "main")

int main(int argc, char *argv[])
{
Expand Down Expand Up @@ -49,8 +50,11 @@ int main(int argc, char *argv[])
#ifdef RABBITCOMMON
CFrmUpdater *pUpdate = new CFrmUpdater();
pUpdate->SetTitle(QImage(":/image/FaceRecognizer"));
if(!pUpdate->GenerateUpdateXml())
return 0;
if(app.arguments().length() > 1) {
pUpdate->GenerateUpdateJson();
pUpdate->GenerateUpdateXml();
return 0;
}
#endif

QFile f(":/qss/black.qss");
Expand Down

0 comments on commit 412da1e

Please sign in to comment.