-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add default properties for company object #24
Conversation
Makefile
Outdated
|
||
.PHONY: generate | ||
generate: ## generate go code (e.g. make generate OBJECT=Contact FILEPATH=contact.csv) | ||
cd $(TOOLS)/model_generator && go run model_gen.go $(OBJECT) $(FILEPATH) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cd $(TOOLS)/model_generator && go run model_gen.go $(OBJECT) $(FILEPATH) | |
@cd $(TOOLS)/model_generator && go run model_gen.go $(OBJECT) $(FILEPATH) |
### Sample | ||
|
||
```shell | ||
$ make generate OBJECT=Contact FILEPATH=contact.csv |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[opt] maybe good to add sample contact.csv
file?
tools/model_generator/model_gen.go
Outdated
log.Printf("Running with arges: %s\n", os.Args[1:]) // Without command name. | ||
|
||
if len(os.Args) != 3 { | ||
log.Fatal("Missing required parameters: <objectName> <csvFilePath>") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think cli tool is better not to use log, but use fmt.Print* because log has date&time prefix.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
…es-for-company-object Add default properties for company object
What to do
Background
Followup #23
Acceptance criteria