1 Star 0 Fork 25

mkxue / gfstudy

forked from goflyfox / gfstudy 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
17.GoFrame工具链之基本介绍.md 3.12 KB
一键复制 编辑 原始数据 按行查看 历史
zcool321@sina.com 提交于 2020-04-29 01:42 . add gf tool chain

GoFrame工具链之基本介绍

GF工具链介绍

GF为GoFrame辅助工具链,地址:https://github.com/gogf/gf-cli;下载对应平台

D:\17.gfcli>gf -h
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.

install 安装

version 查看版本

update 更新

init 初始化项目

get 安装和更新包

run 热编译,自动编译

build 交叉编译

gen 自动生成,现在主要是生成model

pack 打成二进制包

docker 生成docker文件

swagger 解析和开始swagger

help 帮助

安装install

D:\>dir
2020/04/26  23:02        21,447,168 gf.exe

D:\>gf install
I found some installable paths for you:
        Id | Writable | Installed | Path
         0 |     true |     false | D:\develop\go\bin
         1 |     true |     false | D:\Program Files (x86)\NetSarang\Xshell 6\
         3 |     true |     false | D:\Program Files\Git\cmd
         5 |     true |     false | C:\Users\FLY的狐狸\AppData\Local\Microsoft\WindowsApps
         6 |     true |     false | D:\Program Files\Microsoft VS Code\bin
         7 |     true |     false | D:\Program Files\Fiddler
         8 |     true |     false | D:\develop\gopath\bin
please choose one installation destination [default 0]: 0
gf binary is successfully installed to: D:\develop\go\bin

版本version和更新update

D:\17.gfcli> gf version
GoFrame CLI Tool v0.7.1, https://goframe.org
Install Path: D:\develop\go\bin\gf.exe
Build Detail:
  Go Version:  go1.14
  GF Version:  v1.12.1
  Git Commit:  76483c62719736c36992edb7e4cea92c01ca6fc5
  Build Time:  2020-04-01 21:46:21
  
D:\17.gfcli> gf update
checking...
downloading...
installing...
gf binary is now updated to the latest version

D:\17.gfcli> gf version
GoFrame CLI Tool v0.7.3, https://goframe.org
Install Path: D:\develop\go\bin\gf.exe
Build Detail:
  Go Version:  go1.14
  GF Version:  v1.12.1
  Git Commit:  bd19f7af64f9d34fac2d4d10043ff8020a1ec74a
  Build Time:  2020-04-18 14:41:58
  
D:\17.gfcli>gf update
checking...
it's the latest version, no need updates
1
https://gitee.com/mkxue/gfstudy.git
git@gitee.com:mkxue/gfstudy.git
mkxue
gfstudy
gfstudy
master

搜索帮助