Clone this repository to $GOPATH/src/github.com/herusdianto
directory:
git clone https://github.com/herusdianto/gorm_crud_example.git
Install glide
:
https://glide.sh/
CD to gorm_crud_example
folder:
cd $GOPATH/src/github.com/herusdianto/gorm_crud_example
Install dependencies using glide
:
glide install
Open main.go
and modify this variable values:
dbUser, dbPassword, dbName := "root", "root", "gorm_crud_example"
Login to MySQL
and create the database:
create database gorm_crud_example;
Run main.go
:
go run main.go
If you want to watch step by step I'm making this, you can watch this videos.
Support me with subscribe to my channel on youtube, thank you.