arden / gf-cli

GoFrame Command Line Interface, which is your helpmate for building GoFrame application with convenience.

Home Page:https://goframe.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

GF-CLI

gf-cli is a powerful CLI tool for building GF application with convenience.

1. Install

1). Binary

It's recommended using pre-compiled binaries:

After downloads, please use gf install command to install gf binary to system binary path.

  1. Linux & Mac

    wget https://goframe.org/cli/linux_amd64/gf && chmod +x gf && ./gf install

    If you're using zsh, you might need rename your alias by command alias gf=gf to resolve the conflicts between gf and git fetch.

  2. Windows

    Manually download, double click it and then follow the instruction.

2). Manually Install

You might need setting the goproxy to make through building.

  1. Latest version
    git clone https://github.com/gogf/gf-cli 
    cd gf-cli && go build main.go && ./main install
    
  2. Specified version
    git clone --branch v0.7.3 https://github.com/gogf/gf-cli 
    cd gf-cli && go build main.go && ./main install
    
  3. Database sqlite and oracle are not support in gf gen model command in default as it needs cgo and gcc, you can manually make some changes to the source codes and do the building.

2. Commands

$ gf
USAGE
    gf COMMAND [ARGUMENT] [OPTION]

COMMAND
    get        install or update GF to system in default...
    gen        automatically generate go files for ORM models...
    run        running go codes with hot-compiled-like feature...
    init       initialize an empty GF project at current working directory...
    help       show more information about a specified command
    pack       packing any file/directory to a resource file, or a go file
    build      cross-building go project for lots of platforms...
    docker     create a docker image for current GF project...
    swagger    parse and start a swagger feature server for current project...
    update     update current gf binary to latest one (might need root/admin permission)
    install    install gf binary to system (might need root/admin permission)
    version    show current binary version info

OPTION
    -y         all yes for all command without prompt ask
    -?,-h      show this help or detail for specified command
    -v,-i      show version information

ADDITIONAL
    Use 'gf help COMMAND' or 'gf COMMAND -h' for detail about a command, which has '...'
    in the tail of their comments.

About

GoFrame Command Line Interface, which is your helpmate for building GoFrame application with convenience.

https://goframe.org

License:MIT License


Languages

Language:Go 99.8%Language:Makefile 0.2%