Skip to content

Commit

Permalink
update dependency
Browse files Browse the repository at this point in the history
  • Loading branch information
LinkLeong committed Jan 26, 2022
1 parent d1ab726 commit 3c9b410
Show file tree
Hide file tree
Showing 7 changed files with 17 additions and 15 deletions.
9 changes: 6 additions & 3 deletions model/zima.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
package model

import "time"

type Path struct {
Name string `json:"name"`
Path string `json:"path"`
IsDir bool `json:"is_dir"`
Name string `json:"name"`
Path string `json:"path"`
IsDir bool `json:"is_dir"`
Date time.Time `json:"date"`
}
1 change: 1 addition & 0 deletions pkg/utils/command/command_helper.go
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,7 @@ func ExecSmartCTLByPath(path string) []byte {
output, err := exec.CommandContext(ctx, "smartctl", "-a", path, "-j").Output()
if err != nil {
fmt.Println("smartctl", err)
fmt.Println("output", string(output))
return nil
}
return output
Expand Down
2 changes: 1 addition & 1 deletion route/route.go
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ func InitRouter() *gin.Engine {
v1FileGroup.PUT("/rename", v1.RenamePath)
v1FileGroup.GET("/read", v1.GetFilerContent)
v1FileGroup.POST("/upload", v1.PostFileUpload)
v1FileGroup.GET("/dirpath", v1.DirPath)
v1FileGroup.GET("/catalog", v1.DirPath)
//创建目录
v1FileGroup.POST("/mkdir", v1.MkdirAll)
v1FileGroup.POST("/create", v1.PostCreateFile)
Expand Down
4 changes: 2 additions & 2 deletions route/v1/system.go
Original file line number Diff line number Diff line change
Expand Up @@ -118,10 +118,10 @@ func GetSystemConfigDebug(c *gin.Context) {
for _, v := range *list {
systemAppStatus += v.Image + ",\n\t"
}
systemAppStatus += "Sync Key: " + config.SystemConfigInfo.SyncKey + "\n\t"

systemAppStatus += "Sync Key length: " + strconv.Itoa(len(config.SystemConfigInfo.SyncKey))

var bugContent string = fmt.Sprintf(`
**Desktop (please complete the following information):**
- OS: %s
- CasaOS Version: %s
- Disk Total: %v
Expand Down
5 changes: 3 additions & 2 deletions service/zima_info.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import (
"runtime"
"strconv"
"strings"
"time"

"github.com/IceWhaleTech/CasaOS/model"
"github.com/IceWhaleTech/CasaOS/pkg/config"
Expand Down Expand Up @@ -86,10 +87,10 @@ func (c *zima) GetDirPath(path string) []model.Path {

if strings.Count(path, "/") > 0 {
for _, l := range ls {
dirs = append(dirs, model.Path{Name: l.Name(), Path: path + "/" + l.Name(), IsDir: l.IsDir()})
dirs = append(dirs, model.Path{Name: l.Name(), Path: path + "/" + l.Name(), IsDir: l.IsDir(), Date: l.ModTime()})
}
} else {
dirs = append(dirs, model.Path{Name: "DATA", Path: "/DATA/", IsDir: true})
dirs = append(dirs, model.Path{Name: "DATA", Path: "/DATA/", IsDir: true, Date: time.Now()})
}
return dirs
}
Expand Down
6 changes: 2 additions & 4 deletions shell/assist.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,9 @@ version_0_2_3() {
}

# add in v0.2.5
readonly CASA_DEPANDS="curl smartmontools"
version_0_2_5{
readonly CASA_DEPANDS="curl smartmontools parted fdisk partprobe"
version_0_2_5() {
install_depends "$CASA_DEPANDS"


}


Expand Down
5 changes: 2 additions & 3 deletions types/system.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package types

const CURRENTVERSION = "0.2.5"

const BODY = "<li>Storage Manager</li><li>File synchronization issues</li><li>Fix the app store classification problem</li>"
const CURRENTVERSION = "0.2.6"

const BODY = "<li>Fix a disk that cannot be formatted under certain circumstances</li>"

0 comments on commit 3c9b410

Please sign in to comment.