gophergala2016/we_for_golang

Name: we_for_golang

Owner: gophergala2016

Description: null

Created: 2016-01-22 19:24:55.0

Updated: 2016-01-23 06:06:22.0

Pushed: 2016-01-23 15:42:58.0

Homepage: null

Size: 10

Language: Go

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

'Schema generator' for mysql

This is an attempt to generate a bootstrap file which can be used as a base for ORM.

Use case

This app can be handy when we have a legacy application and wants to use ORM or when we have a data first, this will pull out its schema in golang Struct

Few Examples
Gorm
How to Use

This is a terminal based utility which accept mysql username, password, database & file name to generate a Struct.

./we_for_golang -u <USERNAME> -p <PASSWORD> -d <DATABASE> -f ~/workspace/my_project_schema.go
Environment set up

Download the latest stable Go distribution(go1.5.3) from the golang site and follow the instruction mentioned.

https://golang.org/doc/install
https://golang.org/dl/
Building Source Code

Open terminal at application directory, execute “go build” command. This will build entire application. More instruction can be found at

https://golang.org/cmd/go/   

This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.