Skip to content

Commit

Permalink
Merge pull request #374 from YangSen-qn/master
Browse files Browse the repository at this point in the history
qshell cmd  doc use README.md & version to 2.10.0
  • Loading branch information
bachue authored Mar 1, 2023
2 parents 102ed7f + 84815c3 commit 5d22870
Show file tree
Hide file tree
Showing 10 changed files with 122 additions and 290 deletions.
1 change: 1 addition & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -63,3 +63,4 @@ jobs:
goarch: ${{ matrix.goarch }}
goversion: "https://golang.org/dl/go1.20.1.linux-amd64.tar.gz"
ldflags: -X "github.com/qiniu/qshell/v2/iqshell/common/version.version=${{ env.APP_VERSION }}" -extldflags "-static"
project_path: "./main"
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# 2.9.3
# 2.10.0
1. expire 与 batchexpire 命令调整,deleteAfterDay 为 0 时取消文件的过期删除配置
2. 处理文件大小为 0 字节下载失败问题
3. 私有云支持仅配置 UC 域名
Expand Down
207 changes: 105 additions & 102 deletions README.md

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions cmd_test/qshell_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,15 @@ import (
)

func TestQShellDocument01(t *testing.T) {
prefix := "# 简介\n`qshell`"
prefix := "# qshell"
result, _ := test.RunCmdWithError()
if !strings.HasPrefix(result, prefix) {
t.Fatal("document test fail for cmd: qshell")
}
}

func TestQShellDocument02(t *testing.T) {
prefix := "# 简介\n`qshell`"
prefix := "# qshell"
result, _ := test.RunCmdWithError("--doc")
if !strings.HasPrefix(result, prefix) {
t.Fatal("document test fail for cmd: qshell")
Expand Down
2 changes: 1 addition & 1 deletion docs/batchexpire.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

## 注:
v2.7.0 到 v2.9.2 不支持取消过期时间配置,如果过期天数配置为 0 会立即删除文件。
v2.9.3 开始,过期天数配置为 0 时为取消过期时间配置。
v2.10.0 开始,过期天数配置为 0 时为取消过期时间配置。

# 格式
```
Expand Down
4 changes: 2 additions & 2 deletions docs/expire.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
`expire` 指令用来为空间中的一个文件修改 **过期时间**。(即多长时间后,该文件会被自动删除)

## 注:
v2.7.0 到 v2.9.2 不支持取消过期时间配置,如果 DeleteAfterDays(过期天数)配置为 0 会立即删除文件。
v2.9.3 开始, DeleteAfterDays(过期天数)配置为 0 时为取消过期时间配置。
v2.7.0 到 v2.9.2 不支持取消过期时间配置,如果过期天数配置为 0 会立即删除文件。
v2.10.0 开始,过期天数配置为 0 时为取消过期时间配置。

# 格式
```
Expand Down
9 changes: 4 additions & 5 deletions docs/qshell.go
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
package docs

import _ "embed"

//go:embed qshell.md
var qshellDocument string
import (
"github.com/qiniu/qshell/v2"
)

const QShellType = "qshell"

func init() {
addCmdDocumentInfo(QShellType, qshellDocument)
addCmdDocumentInfo(QShellType, qshell.ReadMeDocument)
}
177 changes: 0 additions & 177 deletions docs/qshell.md

This file was deleted.

File renamed without changes.
6 changes: 6 additions & 0 deletions readme.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
package qshell

import _ "embed"

//go:embed README.md
var ReadMeDocument string

0 comments on commit 5d22870

Please sign in to comment.