mirror of
https://github.com/RubyMetric/chsrc.git
synced 2025-01-04 06:23:37 +08:00
Reset first
This commit is contained in:
parent
1b1f13aa71
commit
943d4edaf0
|
@ -5,11 +5,12 @@
|
||||||
* File Authors : Aoran Zeng <ccmywish@qq.com>
|
* File Authors : Aoran Zeng <ccmywish@qq.com>
|
||||||
* | Heng Guo <2085471348@qq.com>
|
* | Heng Guo <2085471348@qq.com>
|
||||||
* Contributors : Peng Gao <gn3po4g@outlook.com>
|
* Contributors : Peng Gao <gn3po4g@outlook.com>
|
||||||
* | Happy Game <happygame10124@gmail.com>
|
* | Happy Game <happygame10124@gmail.com>
|
||||||
|
* |
|
||||||
* Created On : <2023-08-29>
|
* Created On : <2023-08-29>
|
||||||
* Last Modified : <2024-11-04>
|
* Last Modified : <2024-11-08>
|
||||||
*
|
*
|
||||||
* chsrc 框架
|
* chsrc framework
|
||||||
* ------------------------------------------------------------*/
|
* ------------------------------------------------------------*/
|
||||||
|
|
||||||
#include "xy.h"
|
#include "xy.h"
|
||||||
|
@ -820,7 +821,13 @@ chsrc_conclude (SourceInfo *source, const char *last_word)
|
||||||
{
|
{
|
||||||
split_between_source_changing_process;
|
split_between_source_changing_process;
|
||||||
|
|
||||||
if (xy_streql (SetsrcType_Auto, last_word))
|
if ((ProgMode_CMD_Reset == true) || xy_streql (SetsrcType_Reset, last_word))
|
||||||
|
{
|
||||||
|
// source_is_upstream (source)
|
||||||
|
char *msg = CliOpt_InEnglish ? "Has been reset to the upstream default source" : "已重置为上游默认源";
|
||||||
|
chsrc_log (purple (msg));
|
||||||
|
}
|
||||||
|
else if (xy_streql (SetsrcType_Auto, last_word))
|
||||||
{
|
{
|
||||||
if (source)
|
if (source)
|
||||||
{
|
{
|
||||||
|
@ -843,12 +850,6 @@ chsrc_conclude (SourceInfo *source, const char *last_word)
|
||||||
chsrc_log (msg);
|
chsrc_log (msg);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (xy_streql (SetsrcType_Reset, last_word))
|
|
||||||
{
|
|
||||||
// source_is_upstream (source)
|
|
||||||
char *msg = CliOpt_InEnglish ? "Has been reset to the upstream default source" : "已重置为上游默认源";
|
|
||||||
chsrc_log (purple (msg));
|
|
||||||
}
|
|
||||||
else if (xy_streql (SetsrcType_SemiAuto, last_word))
|
else if (xy_streql (SetsrcType_SemiAuto, last_word))
|
||||||
{
|
{
|
||||||
if (source)
|
if (source)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user