mirror of
https://shylinux.com/x/icebergs
synced 2025-04-26 09:34:05 +08:00
opt some
This commit is contained in:
parent
f75b554fe3
commit
77d53af10f
@ -2,6 +2,7 @@ package cli
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"os"
|
"os"
|
||||||
|
"runtime"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
ice "shylinux.com/x/icebergs"
|
ice "shylinux.com/x/icebergs"
|
||||||
@ -24,6 +25,10 @@ func init() {
|
|||||||
Index.MergeCommands(ice.Commands{
|
Index.MergeCommands(ice.Commands{
|
||||||
FOREVER: {Name: "forever auto", Help: "启动", Actions: ice.Actions{
|
FOREVER: {Name: "forever auto", Help: "启动", Actions: ice.Actions{
|
||||||
START: {Hand: func(m *ice.Message, arg ...string) {
|
START: {Hand: func(m *ice.Message, arg ...string) {
|
||||||
|
if runtime.GOOS == WINDOWS {
|
||||||
|
m.Cmdy("serve", "start", arg)
|
||||||
|
return
|
||||||
|
}
|
||||||
env := []string{PATH, BinPath(), HOME, kit.Select(kit.Path(""), os.Getenv(HOME))}
|
env := []string{PATH, BinPath(), HOME, kit.Select(kit.Path(""), os.Getenv(HOME))}
|
||||||
for _, k := range ENV_LIST {
|
for _, k := range ENV_LIST {
|
||||||
if kit.Env(k) != "" {
|
if kit.Env(k) != "" {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user