github.com/mattyw/juju@v0.0.0-20140610034352-732aecd63861/cmd/charm-admin/main.go (about)

     1  // Copyright 2012, 2013 Canonical Ltd.
     2  // Licensed under the AGPLv3, see LICENCE file for details.
     3  
     4  package main
     5  
     6  import (
     7  	"fmt"
     8  	"os"
     9  
    10  	"github.com/juju/juju/cmd"
    11  )
    12  
    13  func main() {
    14  	ctx, err := cmd.DefaultContext()
    15  	if err != nil {
    16  		fmt.Fprintf(os.Stderr, "error: %v\n", err)
    17  		os.Exit(2)
    18  	}
    19  
    20  	admcmd := cmd.NewSuperCommand(cmd.SuperCommandParams{
    21  		Name: "charm-admin",
    22  		Log:  &cmd.Log{},
    23  	})
    24  
    25  	admcmd.Register(&DeleteCharmCommand{})
    26  
    27  	os.Exit(cmd.Main(admcmd, ctx, os.Args[1:]))
    28  }