development:goravel
This is an old revision of the document!
Table of Contents
Goravel
https://www.goravel.dev/getting-started/installation.html
git clone https://github.com/goravel/goravel.git && rm -rf goravel/.git* mv goravel goravel.example.com cp .env.example .env # Tải tất cả các dependencies được khai báo trong go.mod. # Xóa các dependencies không cần thiết. # Cập nhật file go.sum. go mod tidy go run . artisan key:generate # You need to generate JWT Token if you use Authentication. go run . artisan jwt:secret
$GOPATH, mặc định là ~/go/bin
Thêm Module
File go.mod:
module your_project_name go 1.21 require ( github.com/goravel/framework v1.0.0 )
Ví dụ: nếu github.com/goravel/framework chưa được khai báo, thêm nó vào require hoặc sử dụng lệnh sau để thêm module:
go get github.com/goravel/framework
Xóa và tải lại module
Xóa cache của Go:
go clean -modcache
Tải lại tất cả dependencies:
go mod tidy
Tải Air qua Go
go install github.com/cosmtrek/air@latest
development/goravel.1732685454.txt.gz · Last modified: 2024/11/27 05:30 by tungnt