mirror of
https://github.com/pocketbase/pocketbase.git
synced 2026-10-29 00:10:24 +01:00
[#82] removed version cmd and make use of cobra.Version
This commit is contained in:
1 parent
320d1482a4
commit
ce857985be
2 files changed
+7
-27
No files matched your search
@@ -1,21 +0,0 @@
|
||||
// Package cmd implements various PocketBase system commands.
|
||||
package cmd
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
|
||||
"github.com/pocketbase/pocketbase/core"
|
||||
"github.com/spf13/cobra"
|
||||
)
|
||||
|
||||
// NewVersionCommand creates and returns new command that prints
|
||||
// the current PocketBase version.
|
||||
func NewVersionCommand(app core.App, version string) *cobra.Command {
|
||||
return &cobra.Command{
|
||||
Use: "version",
|
||||
Short: "Prints the current PocketBase app version",
|
||||
Run: func(command *cobra.Command, args []string) {
|
||||
fmt.Printf("PocketBase %s\n", version)
|
||||
},
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user