Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
yasuflatland-lf committed Jul 8, 2024
1 parent 4b21227 commit 91eb954
Showing 1 changed file with 21 additions and 1 deletion.
22 changes: 21 additions & 1 deletion backend/README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
# Backend of Flamingo Armond
Backend server implementation for Flamingo Armond by Go.

# Precondition
- Go 1.22.5
- Goose v3
- Echo v4.12.0
- Gorm v1.25.10
- Goose v3 (Data migration)
- gqlgen v0.17.49 (GraphQL code generator and framework)

# Set up
## Install Goose
Expand All @@ -28,7 +32,23 @@ At the root directory, run
docker compose up --build
```

# Generators
This backend uses some generated code. Here are the steps to generate code.

## Generate GraphQL
1. Revise table schemas under `/backend/db/migrations`
1. Revise GraphQL Schemas in `/backend/graph/schema.graphqls` accordingly.
1. At `/backend`, run `make gen`. It will generate `generated.go`, `resolver.go` and `schema.resolvers.go` accordingly.

## Generate Parser for Loading Flashcards' Texts
1. Revise `/backend/pkg/notion/parser.y`
2. At `/backend`, run `make parsergen`

# Tips
## How to see the Make Commands
```
make help
```

## How to Install goyacc

Expand Down

0 comments on commit 91eb954

Please sign in to comment.