mirror of
https://github.com/photoprism/photoprism.git
synced 2025-10-05 08:47:12 +08:00
24 lines
395 B
Go
24 lines
395 B
Go
package commands
|
|
|
|
import (
|
|
"fmt"
|
|
|
|
"github.com/photoprism/photoprism/internal/context"
|
|
"github.com/urfave/cli"
|
|
)
|
|
|
|
// Prints current configuration
|
|
var VersionCommand = cli.Command{
|
|
Name: "version",
|
|
Usage: "Displays version information",
|
|
Action: versionAction,
|
|
}
|
|
|
|
func versionAction(ctx *cli.Context) error {
|
|
conf := context.NewConfig(ctx)
|
|
|
|
fmt.Println(conf.AppVersion())
|
|
|
|
return nil
|
|
}
|