Skip to content

Commit 899295c

Browse files
committed
Add latest changes to schema
Add peopleSchema Add image field Fixes resumic#76 Add schema reference using vanity url Fixes: resumic#114 Move to numerical enums for skills and language
1 parent 3b688a6 commit 899295c

22 files changed

+3678
-1622
lines changed

.travis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
language: go
22

33
go:
4-
- "1.12.x"
4+
- "1.14.x"
55
- master
66

77
script:

Makefile

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,9 @@ pre-build:
1414

1515
build: pre-build
1616
@go build -ldflags "-X $(CODEPATH)/cmd.version=$(RESUMIC_VERSION)$(SUFFIX) -X $(CODEPATH)/cmd.gitCommit=$(GITCOMMIT)" -o resumic
17+
./resumic generate example
18+
./resumic generate uischema
19+
./resumic generate jsonschema
1720
@packr2 clean
1821

1922
release: pre-build
@@ -25,4 +28,4 @@ test: build
2528

2629
.PHONY: clean
2730
clean: ./resumic
28-
@rm resumic
31+
@rm resumic

cmd/generate_example.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,11 @@ import (
55
"fmt"
66
"io/ioutil"
77

8-
"go.resumic.org/schema/schema"
98
"github.com/spf13/cobra"
9+
"go.resumic.org/schema/schema"
1010
)
1111

12-
// Flag to specify output. Default value is "resume_example.json"
12+
// Flag to specify output. Default value is "resume-example.json"
1313
var outputFileName string
1414

1515
func generateExampleRun(cmd *cobra.Command, args []string) error {
@@ -38,6 +38,6 @@ var generateExampleCmd = &cobra.Command{
3838
}
3939

4040
func init() {
41-
generateExampleCmd.Flags().StringVarP(&outputFileName, "output", "o", "resume_example.json", "Specify a custom output file for example resume data.")
41+
generateExampleCmd.Flags().StringVarP(&outputFileName, "output", "o", "resume-example.json", "Specify a custom output file for example resume data.")
4242
generateCmd.AddCommand(generateExampleCmd)
4343
}

cmd/generate_example_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ func TestGenerateExampleRunValid(t *testing.T) {
1616
if err != nil {
1717
t.Fatalf("Could not generate example, %s", err)
1818
}
19-
r, err := compareJSONFiles("../example.json", tempFile.Name())
19+
r, err := compareJSONFiles("../resume-example.json", tempFile.Name())
2020
if err != nil {
2121
t.Fatalf("could not compare example.json and generated schema: %s", err)
2222
}

cmd/generate_jsonschema.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,6 @@ var generateJSONSchemaCmd = &cobra.Command{
3131
}
3232

3333
func init() {
34-
generateJSONSchemaCmd.Flags().StringVarP(&schemaPath, "output", "o", "resume.json", "Specify an output file for the resume data")
34+
generateJSONSchemaCmd.Flags().StringVarP(&schemaPath, "output", "o", "schema.json", "Specify an output file for the resume data")
3535
generateCmd.AddCommand(generateJSONSchemaCmd)
3636
}

cmd/generate_uischema.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,6 @@ var generateUISchemaCmd = &cobra.Command{
3131
}
3232

3333
func init() {
34-
generateUISchemaCmd.Flags().StringVarP(&uiSchemaPath, "output", "o", "resume.json", "Specify an output file for the resume data")
34+
generateUISchemaCmd.Flags().StringVarP(&uiSchemaPath, "output", "o", "ui-schema.json", "Specify an output file for the resume data")
3535
generateCmd.AddCommand(generateUISchemaCmd)
3636
}

cmd/generate_uischema_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ func TestGenerateUISchemaRunValid(t *testing.T) {
1616
if err != nil {
1717
t.Fatalf("Could not generate schema, %s", err)
1818
}
19-
r, err := compareJSONFiles("../ui.json", tempFile.Name())
19+
r, err := compareJSONFiles("../ui-schema.json", tempFile.Name())
2020
if err != nil {
2121
t.Fatalf("could not compare ui.json and generated schema: %s", err)
2222
}

cmd/render_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import (
77
)
88

99
func TestRenderRun(t *testing.T) {
10-
resumePath := "../example.json"
10+
resumePath := "../resume-example.json"
1111
htmlPath := "../example.html"
1212
cacheDir, err := ioutil.TempDir("", "")
1313
if err != nil {

cmd/validate_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ package cmd
33
import "testing"
44

55
func TestValidateRunValid(t *testing.T) {
6-
resumeFile := "../example.json"
6+
resumeFile := "../resume-example.json"
77
err := Execute([]string{"validate", "-r", resumeFile}) //validateRun(validateCmd, []string{"-r", resumeFile})
88
if err != nil {
99
t.Fatalf("Expected valid state, got error, %s", err)

example.html

Lines changed: 0 additions & 6 deletions
This file was deleted.

0 commit comments

Comments
 (0)