diff --git a/README.md b/README.md index 0c093d4..1c87f30 100644 --- a/README.md +++ b/README.md @@ -24,6 +24,6 @@ A command line tool using with online class. |
ren-yc (Yuchen Ren) |
jsh-jsh (jinshuhang) |
hjl2011 | | :---: | :---: | :---: | -| ![](https://shields.io/badge/Coding-green?logo=visual-studio-code&style=for-the-badge)
![](https://shields.io/badge/BugTester-yellow?logo=open-bug-bounty&style=for-the-badge) | ![](https://shields.io/badge/Creator-green?logo=visual-studio-code&style=for-the-badge)
![](https://shields.io/badge/BugTester-yellow?logo=open-bug-bounty&style=for-the-badge) | ![](https://shields.io/badge/Coding-green?logo=visual-studio-code&style=for-the-badge)
![](https://shields.io/badge/BugTester-yellow?logo=open-bug-bounty&style=for-the-badge) | +| ![](https://shields.io/badge/Maintainer-green?logo=visual-studio-code&style=for-the-badge)
![](https://shields.io/badge/BugTester-yellow?logo=open-bug-bounty&style=for-the-badge) | ![](https://shields.io/badge/Creator-green?logo=visual-studio-code&style=for-the-badge)
![](https://shields.io/badge/BugTester-yellow?logo=open-bug-bounty&style=for-the-badge) | ![](https://shields.io/badge/Coding-green?logo=visual-studio-code&style=for-the-badge)
![](https://shields.io/badge/BugTester-yellow?logo=open-bug-bounty&style=for-the-badge) | **For more information, please go to [Wiki](https://github.com/class-tools/Web-Class-Helper/wiki)**. \ No newline at end of file diff --git a/README.zh-CN.md b/README.zh-CN.md index b3ab189..b030a74 100644 --- a/README.zh-CN.md +++ b/README.zh-CN.md @@ -24,6 +24,6 @@ |
ren-yc (Yuchen Ren) |
jsh-jsh (jinshuhang) |
hjl2011 | | :---: | :---: | :---: | -| ![](https://shields.io/badge/Coding-green?logo=visual-studio-code&style=for-the-badge)
![](https://shields.io/badge/BugTester-yellow?logo=open-bug-bounty&style=for-the-badge) | ![](https://shields.io/badge/Creator-green?logo=visual-studio-code&style=for-the-badge)
![](https://shields.io/badge/BugTester-yellow?logo=open-bug-bounty&style=for-the-badge) | ![](https://shields.io/badge/Coding-green?logo=visual-studio-code&style=for-the-badge)
![](https://shields.io/badge/BugTester-yellow?logo=open-bug-bounty&style=for-the-badge) | +| ![](https://shields.io/badge/Maintainer-green?logo=visual-studio-code&style=for-the-badge)
![](https://shields.io/badge/BugTester-yellow?logo=open-bug-bounty&style=for-the-badge) | ![](https://shields.io/badge/Creator-green?logo=visual-studio-code&style=for-the-badge)
![](https://shields.io/badge/BugTester-yellow?logo=open-bug-bounty&style=for-the-badge) | ![](https://shields.io/badge/Coding-green?logo=visual-studio-code&style=for-the-badge)
![](https://shields.io/badge/BugTester-yellow?logo=open-bug-bounty&style=for-the-badge) | **更多信息请至 [Wiki](https://github.com/class-tools/Web-Class-Helper/wiki)**。 \ No newline at end of file diff --git a/WCH.cpp b/WCH.cpp index 2f60a8d..906c8ba 100644 --- a/WCH.cpp +++ b/WCH.cpp @@ -5,9 +5,9 @@ Copyright (c) 2022 Class Tools Develop Team Contributors: jsh-jsh ren-yc */ #define WCH_VER_MAIN TEXT("2.1.1") -#define WCH_VER_TYPE 1 +#define WCH_VER_TYPE 2 #if WCH_VER_TYPE != 0 - #define WCH_VER_BUILD 5 + #define WCH_VER_BUILD 1 #endif #include "./modules/file-process.hpp" #include "./modules/init.hpp" diff --git a/modules/init.hpp b/modules/init.hpp index b887c2d..f4b2a52 100644 --- a/modules/init.hpp +++ b/modules/init.hpp @@ -75,8 +75,8 @@ void WCH_Init_Bind() { // Initialization for bind. atexit(WCH_exit); WCH_signalHandler(); - assert(CoInitializeEx(nullptr, COINIT_APARTMENTTHREADED | COINIT_DISABLE_OLE1DDE) == S_OK); - assert(WCH_TBL.CoCreateInstance(CLSID_TaskbarList) == S_OK); + ignore = CoInitializeEx(nullptr, COINIT_APARTMENTTHREADED | COINIT_DISABLE_OLE1DDE); + ignore = WCH_TBL.CoCreateInstance(CLSID_TaskbarList); JSON_SWB.settings_ = []() { Json::Value def; Json::StreamWriterBuilder::setDefaults(&def); @@ -84,8 +84,8 @@ void WCH_Init_Bind() { return def; }(); WCH_window_handle = GetConsoleWindow(); - assert(_setmode(_fileno(stdin), _O_WTEXT) != -1); - assert(_setmode(_fileno(stdout), _O_WTEXT) != -1); + ignore = _setmode(_fileno(stdin), _O_WTEXT); + ignore = _setmode(_fileno(stdout), _O_WTEXT); wfin.imbue(locale(".UTF-8", LC_CTYPE)); wfout.imbue(locale(".UTF-8", LC_CTYPE)); _wsystem(L"CHCP 65001 > NUL"); diff --git a/scripts/build.ps1 b/scripts/build.ps1 index 73c4511..9816d3e 100644 --- a/scripts/build.ps1 +++ b/scripts/build.ps1 @@ -2,7 +2,7 @@ $devenv_path = (& (${env:ProgramFiles(x86)} + "\Microsoft Visual Studio\Installe $solution_path = ".\WCH.sln" $run_mode = "/Build" $configarray = "x86", "x64", "ARM", "ARM64" -if ($args[0] -eq "Debug" || $args[0] -eq "Release") { +if ($args[0] -eq "Debug" -or $args[0] -eq "Release") { foreach ($config in $configarray) { & $devenv_path $solution_path $run_mode ($args[0] + "|" + $config) }