yao/cmd/inspect.go
Max 789cc85996 feat(certificates): inject commercial license root certificates into build process
- Added steps in both Linux and macOS workflows to inject commercial license root certificates from GitHub Secrets during the build process.
- Updated the `inspect` and `load` packages to include license information, enhancing the application's licensing capabilities.
- Included license metadata in the OpenAPI response for better visibility of licensing status.
2026-03-27 12:51:30 +08:00

30 lines
646 B
Go

package cmd
import (
"github.com/spf13/cobra"
"github.com/yaoapp/kun/maps"
"github.com/yaoapp/kun/utils"
"github.com/yaoapp/yao/commercial"
"github.com/yaoapp/yao/config"
"github.com/yaoapp/yao/engine"
"github.com/yaoapp/yao/share"
)
var inspectCmd = &cobra.Command{
Use: "inspect",
Short: L("Show app configure"),
Long: L("Show app configure"),
Run: func(cmd *cobra.Command, args []string) {
Boot()
engine.InspectExtTools()
res := maps.Map{
"version": share.VERSION,
"config": config.Conf,
}
res["license"] = commercial.License
if share.Tools != nil {
res["tools"] = share.Tools
}
utils.Dump(res)
},
}