mirror of
https://github.com/minio/minio.git
synced 2024-12-24 22:25:54 -05:00
Merge pull request #129 from harshavardhana/pr_out_move_wrappers_at_pkgs_minio_back_to_cmd_minio_as_their_usage_is_limited
This commit is contained in:
commit
68eb14a1f6
@ -1,4 +1,4 @@
|
||||
package minio
|
||||
package main
|
||||
|
||||
import (
|
||||
"errors"
|
||||
@ -75,7 +75,7 @@ func parseInput(c *cli.Context) (inputConfig, error) {
|
||||
return config, nil
|
||||
}
|
||||
|
||||
func Getobjectdir(basename string) string {
|
||||
func getObjectdir(basename string) string {
|
||||
user, err := user.Current()
|
||||
if err != nil {
|
||||
log.Fatal(err)
|
@ -1,4 +1,4 @@
|
||||
package minio
|
||||
package main
|
||||
|
||||
import (
|
||||
"log"
|
||||
@ -6,7 +6,7 @@ import (
|
||||
"github.com/codegangsta/cli"
|
||||
)
|
||||
|
||||
func Encode(c *cli.Context) {
|
||||
func encode(c *cli.Context) {
|
||||
config, err := parseInput(c)
|
||||
if err != nil {
|
||||
log.Fatal(err)
|
@ -1,4 +1,4 @@
|
||||
package minio
|
||||
package main
|
||||
|
||||
import (
|
||||
"bytes"
|
@ -1,4 +1,4 @@
|
||||
package minio
|
||||
package main
|
||||
|
||||
import (
|
||||
"io"
|
||||
@ -8,7 +8,7 @@ import (
|
||||
"github.com/codegangsta/cli"
|
||||
)
|
||||
|
||||
func Get(c *cli.Context) {
|
||||
func get(c *cli.Context) {
|
||||
config, err := parseInput(c)
|
||||
if err != nil {
|
||||
log.Fatal(err)
|
1
cmd/minio/init.go
Normal file
1
cmd/minio/init.go
Normal file
@ -0,0 +1 @@
|
||||
package main
|
@ -1,4 +1,4 @@
|
||||
package minio
|
||||
package main
|
||||
|
||||
import (
|
||||
"io"
|
||||
@ -8,7 +8,7 @@ import (
|
||||
"github.com/codegangsta/cli"
|
||||
)
|
||||
|
||||
func List(c *cli.Context) {
|
||||
func list(c *cli.Context) {
|
||||
config, err := parseInput(c)
|
||||
if err != nil {
|
||||
log.Fatal(err)
|
@ -4,7 +4,6 @@ import (
|
||||
"os"
|
||||
|
||||
"github.com/codegangsta/cli"
|
||||
"github.com/minio-io/minio/pkgs/minio"
|
||||
)
|
||||
|
||||
func main() {
|
||||
@ -15,16 +14,16 @@ func main() {
|
||||
{
|
||||
Name: "encode",
|
||||
Usage: "erasure encode a byte stream",
|
||||
Action: minio.Encode,
|
||||
Action: encode,
|
||||
Flags: []cli.Flag{
|
||||
cli.StringFlag{
|
||||
Name: "root",
|
||||
Value: minio.Getobjectdir(".minio/erasure"),
|
||||
Value: getObjectdir(".minio/erasure"),
|
||||
Usage: "",
|
||||
},
|
||||
cli.StringFlag{
|
||||
Name: "staging",
|
||||
Value: minio.Getobjectdir(".minio/staging"),
|
||||
Value: getObjectdir(".minio/staging"),
|
||||
Usage: "",
|
||||
},
|
||||
cli.StringFlag{
|
||||
@ -42,11 +41,11 @@ func main() {
|
||||
{
|
||||
Name: "get",
|
||||
Usage: "get an object",
|
||||
Action: minio.Get,
|
||||
Action: get,
|
||||
Flags: []cli.Flag{
|
||||
cli.StringFlag{
|
||||
Name: "root",
|
||||
Value: minio.Getobjectdir(".minio/erasure"),
|
||||
Value: getObjectdir(".minio/erasure"),
|
||||
Usage: "",
|
||||
},
|
||||
cli.StringFlag{
|
||||
@ -64,11 +63,11 @@ func main() {
|
||||
{
|
||||
Name: "put",
|
||||
Usage: "put an object",
|
||||
Action: minio.Put,
|
||||
Action: put,
|
||||
Flags: []cli.Flag{
|
||||
cli.StringFlag{
|
||||
Name: "staging",
|
||||
Value: minio.Getobjectdir(".minio/staging"),
|
||||
Value: getObjectdir(".minio/staging"),
|
||||
Usage: "",
|
||||
},
|
||||
cli.StringFlag{
|
||||
@ -81,11 +80,11 @@ func main() {
|
||||
{
|
||||
Name: "list",
|
||||
Usage: "list objects",
|
||||
Action: minio.List,
|
||||
Action: list,
|
||||
Flags: []cli.Flag{
|
||||
cli.StringFlag{
|
||||
Name: "root",
|
||||
Value: minio.Getobjectdir(".minio/erasure"),
|
||||
Value: getObjectdir(".minio/erasure"),
|
||||
Usage: "",
|
||||
},
|
||||
},
|
||||
|
@ -1,4 +1,4 @@
|
||||
package minio
|
||||
package main
|
||||
|
||||
import (
|
||||
"log"
|
||||
@ -8,7 +8,7 @@ import (
|
||||
"github.com/codegangsta/cli"
|
||||
)
|
||||
|
||||
func Put(c *cli.Context) {
|
||||
func put(c *cli.Context) {
|
||||
config, err := parseInput(c)
|
||||
if err != nil {
|
||||
log.Fatal(err)
|
1
cmd/minio/verify.go
Normal file
1
cmd/minio/verify.go
Normal file
@ -0,0 +1 @@
|
||||
package main
|
@ -1 +0,0 @@
|
||||
package minio
|
@ -1 +0,0 @@
|
||||
package minio
|
Loading…
Reference in New Issue
Block a user