mirror of
https://github.com/go-shiori/shiori.git
synced 2025-02-22 15:06:04 +08:00
20 lines
440 B
Go
20 lines
440 B
Go
|
package cmd
|
||
|
|
||
|
import (
|
||
|
"github.com/spf13/cobra"
|
||
|
)
|
||
|
|
||
|
func serveCmd() *cobra.Command {
|
||
|
cmd := &cobra.Command{
|
||
|
Use: "serve",
|
||
|
Short: "Serve web interface for managing bookmarks",
|
||
|
Long: "Run a simple annd performant web server which " +
|
||
|
"serves the site for managing bookmarks. If --port " +
|
||
|
"flag is not used, it will use port 8080 by default.",
|
||
|
}
|
||
|
|
||
|
cmd.Flags().IntP("port", "p", 8080, "Port that used by server")
|
||
|
|
||
|
return cmd
|
||
|
}
|