Merge pull request #2220 from stevvooe/redundant-pkg-name
cmd/ctr/app: remove redundant package name
This commit is contained in:
commit
07dfb0368a
@ -14,7 +14,7 @@
|
|||||||
limitations under the License.
|
limitations under the License.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package command
|
package app
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
@ -51,8 +51,8 @@ func init() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// App returns a *cli.App instance.
|
// New returns a *cli.App instance.
|
||||||
func App() *cli.App {
|
func New() *cli.App {
|
||||||
app := cli.NewApp()
|
app := cli.NewApp()
|
||||||
app.Name = "ctr"
|
app.Name = "ctr"
|
||||||
app.Version = version.Version
|
app.Version = version.Version
|
@ -16,7 +16,7 @@
|
|||||||
limitations under the License.
|
limitations under the License.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package command
|
package app
|
||||||
|
|
||||||
import "github.com/containerd/containerd/cmd/ctr/commands/shim"
|
import "github.com/containerd/containerd/cmd/ctr/commands/shim"
|
||||||
|
|
@ -20,14 +20,14 @@ import (
|
|||||||
"fmt"
|
"fmt"
|
||||||
"os"
|
"os"
|
||||||
|
|
||||||
"github.com/containerd/containerd/cmd/ctr/command"
|
"github.com/containerd/containerd/cmd/ctr/app"
|
||||||
"github.com/urfave/cli"
|
"github.com/urfave/cli"
|
||||||
)
|
)
|
||||||
|
|
||||||
var pluginCmds = []cli.Command{}
|
var pluginCmds = []cli.Command{}
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
app := command.App()
|
app := app.New()
|
||||||
app.Commands = append(app.Commands, pluginCmds...)
|
app.Commands = append(app.Commands, pluginCmds...)
|
||||||
if err := app.Run(os.Args); err != nil {
|
if err := app.Run(os.Args); err != nil {
|
||||||
fmt.Fprintf(os.Stderr, "ctr: %s\n", err)
|
fmt.Fprintf(os.Stderr, "ctr: %s\n", err)
|
||||||
|
Loading…
Reference in New Issue
Block a user