mirror of https://github.com/statping/statping
parent
a7b49500ca
commit
f953eea1dd
|
@ -1,3 +1,8 @@
|
|||
# 0.90.14
|
||||
- Updated SCSS compiling, and confirmed it works.
|
||||
- Added `$container-color` SCSS variable.
|
||||
- Fixed issue with JWT token (nil pointer) for the Cookie name
|
||||
|
||||
# 0.90.13
|
||||
- Added new function `utils.RenameDirectory` to rename directory
|
||||
- Added new function `(*DbConfig) BackupAssets` to backup a customized theme and place into a directory named `assets_backup`. Only for migration 0.80 to 0.90+, entirely new frontend.
|
||||
|
|
|
@ -42,9 +42,9 @@ func catchCLI(args []string) error {
|
|||
switch args[0] {
|
||||
case "version":
|
||||
if COMMIT != "" {
|
||||
fmt.Printf("%v (%v)\n", VERSION, COMMIT)
|
||||
fmt.Printf("%s (%s)\n", VERSION, COMMIT)
|
||||
} else {
|
||||
fmt.Printf("%v\n", VERSION)
|
||||
fmt.Printf("%s\n", VERSION)
|
||||
}
|
||||
return errors.New("end")
|
||||
case "assets":
|
||||
|
|
|
@ -73,8 +73,7 @@ func exit(err error) {
|
|||
}
|
||||
|
||||
func init() {
|
||||
core.App = new(core.Core)
|
||||
core.App.Version = VERSION
|
||||
core.New(VERSION)
|
||||
}
|
||||
|
||||
// main will run the Statping application
|
||||
|
|
|
@ -678,6 +678,7 @@ HTML,BODY {
|
|||
|
||||
.index_container {
|
||||
min-height: 980pt;
|
||||
background-color: $container-color;
|
||||
}
|
||||
|
||||
/* Enter and leave animations can use different */
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
/* Index Page */
|
||||
$background-color: #fcfcfc;
|
||||
$container-color: #fcfcfc;
|
||||
$max-width: 860px;
|
||||
$title-color: #464646;
|
||||
$description-color: #939393;
|
||||
|
|
|
@ -35,6 +35,7 @@ func init() {
|
|||
source.Assets()
|
||||
utils.InitLogs()
|
||||
dir = utils.Directory
|
||||
core.New("test")
|
||||
}
|
||||
|
||||
//func TestResetDatabase(t *testing.T) {
|
||||
|
|
|
@ -191,5 +191,5 @@ func resetRouter() {
|
|||
}
|
||||
|
||||
func resetCookies() {
|
||||
jwtKey = fmt.Sprintf("%v_%v", core.App.ApiSecret, utils.Now().Nanosecond())
|
||||
jwtKey = fmt.Sprintf("%s_%d", core.App.ApiSecret, utils.Now().Nanosecond())
|
||||
}
|
||||
|
|
|
@ -31,7 +31,7 @@ import (
|
|||
var (
|
||||
log = utils.Log.WithField("type", "source")
|
||||
TmplBox *rice.Box // HTML and other small files from the 'source/tmpl' directory, this will be loaded into '/assets'
|
||||
DefaultScss = []string{"scss/base.scss", "scss/mobile.scss"}
|
||||
DefaultScss = []string{"scss/main.scss", "scss/base.scss", "scss/mobile.scss"}
|
||||
)
|
||||
|
||||
// Assets will load the Rice boxes containing the CSS, SCSS, JS, and HTML files.
|
||||
|
@ -77,7 +77,9 @@ func CompileSASS(files ...string) error {
|
|||
return errors.Wrap(err, "failed to capture stdout or stderr")
|
||||
}
|
||||
|
||||
log.Infoln(fmt.Sprintf("out: %v | error: %v", stdout, stderr))
|
||||
if stdout != "" || stderr != "" {
|
||||
log.Infoln(fmt.Sprintf("out: %v | error: %v", stdout, stderr))
|
||||
}
|
||||
}
|
||||
log.Infoln("SASS Compiling is complete!")
|
||||
return nil
|
||||
|
|
|
@ -9,6 +9,11 @@ var (
|
|||
App *Core
|
||||
)
|
||||
|
||||
func New(version string) {
|
||||
App = new(Core)
|
||||
App.Version = version
|
||||
}
|
||||
|
||||
// Core struct contains all the required fields for Statping. All application settings
|
||||
// will be saved into 1 row in the 'core' table. You can use the core.CoreApp
|
||||
// global variable to interact with the attributes to the application, such as services.
|
||||
|
|
|
@ -53,10 +53,9 @@ func TestDir(t *testing.T) {
|
|||
}
|
||||
|
||||
func TestCommand(t *testing.T) {
|
||||
t.SkipNow()
|
||||
in, out, err := Command("pwd")
|
||||
in, out, err := Command("/bin/echo", "\"statping testing\"")
|
||||
assert.Nil(t, err)
|
||||
assert.Contains(t, in, "statping")
|
||||
assert.Contains(t, in, "statping testing")
|
||||
assert.Empty(t, out)
|
||||
}
|
||||
|
||||
|
|
|
@ -1 +1 @@
|
|||
0.90.13
|
||||
0.90.14
|
Loading…
Reference in New Issue