reorganized
This commit is contained in:
3
server/types/__init__.py
Normal file
3
server/types/__init__.py
Normal file
@@ -0,0 +1,3 @@
|
||||
from .about import About # noqa: F401
|
||||
from .project import Project # noqa: F401
|
||||
from .lucas import Lucas # noqa: F401
|
||||
9
server/types/about.py
Normal file
9
server/types/about.py
Normal file
@@ -0,0 +1,9 @@
|
||||
from pydantic import BaseModel
|
||||
|
||||
|
||||
class About(BaseModel):
|
||||
name: str
|
||||
email: str
|
||||
bio: str
|
||||
github: str
|
||||
gitea: str
|
||||
8
server/types/lucas.py
Normal file
8
server/types/lucas.py
Normal file
@@ -0,0 +1,8 @@
|
||||
from pydantic import BaseModel
|
||||
from about import About
|
||||
from project import Project
|
||||
|
||||
|
||||
class Lucas(BaseModel):
|
||||
projects: list[Project]
|
||||
about: About
|
||||
11
server/types/project.py
Normal file
11
server/types/project.py
Normal file
@@ -0,0 +1,11 @@
|
||||
from pydantic import BaseModel
|
||||
from typing import Optional
|
||||
|
||||
|
||||
class Project(BaseModel):
|
||||
id: Optional[int] = None
|
||||
name: str
|
||||
description: str
|
||||
source: Optional[str] = None
|
||||
live: Optional[str] = None
|
||||
is_self_hosted: Optional[bool] = False
|
||||
Reference in New Issue
Block a user