Format in small and add copyright

This commit is contained in:
Aoran Zeng
2024-07-31 12:38:52 +08:00
parent 61690ba5a5
commit 8f5423f704
4 changed files with 31 additions and 24 deletions

View File

@@ -1,5 +1,6 @@
/** ------------------------------------------------------------
* SPDX-License-Identifier: GPL-3.0-or-later
* Copyright © 2023-2024 Aoran Zeng, Heng Guo
* -------------------------------------------------------------
* File : chsrc.h
* Authors : Aoran Zeng <ccmywish@qq.com>
@@ -254,15 +255,16 @@ test_speed_url (const char *url)
char *ipv6 = ""; // 默认不启用
if (Cli_Option_IPv6==true) {
ipv6 = "--ipv6";
}
if (Cli_Option_IPv6==true)
{
ipv6 = "--ipv6";
}
// 我们用 —L因为Ruby China源会跳转到其他地方
// npmmirror 也会跳转
char *curl_cmd = xy_strjoin (7, "curl -qsL ", ipv6,
" -o " xy_os_devnull,
" -w \"%{http_code} %{speed_download}\" -m", time_sec ,
" -w \"%{http_code} %{speed_download}\" -m", time_sec,
" -A chsrc/" Chsrc_Version " ", url);
// chsrc_info (xy_2strjoin ("测速命令 ", curl_cmd));
@@ -618,7 +620,7 @@ chsrc_view_file (const char *path)
{
char *cmd = NULL;
path = xy_uniform_path (path);
if(xy_on_windows)
if (xy_on_windows)
{
cmd = xy_2strjoin ("type ", path);
}

View File

@@ -1,5 +1,6 @@
/** ------------------------------------------------------------
* SPDX-License-Identifier: GPL-3.0-or-later
* Copyright © 2023-2024 Aoran Zeng, Heng Guo
* -------------------------------------------------------------
* File : source.h
* Authors : Aoran Zeng <ccmywish@qq.com>

View File

@@ -1,5 +1,6 @@
/** ------------------------------------------------------------
* SPDX-License-Identifier: MIT
* Copyright © 2023-2024 Aoran Zeng, Heng Guo
* -------------------------------------------------------------
* File : xy.h
* Authors : Aoran Zeng <ccmywish@qq.com>