mirror of
https://gitee.com/johng/gf
synced 2026-06-07 02:12:11 +08:00
add more common types for package g
This commit is contained in:
22
.example/os/gcmd/main.go
Normal file
22
.example/os/gcmd/main.go
Normal file
@ -0,0 +1,22 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
|
||||
"github.com/gogf/gf/frame/g"
|
||||
"github.com/gogf/gf/os/gcmd"
|
||||
)
|
||||
|
||||
func main() {
|
||||
p, err := gcmd.Parse(g.MapStrBool{
|
||||
"n,name": true,
|
||||
"p,prefix": true,
|
||||
"f,force": false,
|
||||
"t,tail": false,
|
||||
"i,interactive": false,
|
||||
})
|
||||
if err != nil {
|
||||
fmt.Println(err)
|
||||
}
|
||||
g.Dump(p)
|
||||
}
|
||||
Reference in New Issue
Block a user