Fixed Git LFS
This commit is contained in:
parent
9641c572c1
commit
e50cdce379
@ -30,6 +30,7 @@ sites:
|
|||||||
git_repo:
|
git_repo:
|
||||||
url: ssh://gitea/jim/dogma-jimfinium.git
|
url: ssh://gitea/jim/dogma-jimfinium.git
|
||||||
branch: pub
|
branch: pub
|
||||||
|
lfs: true
|
||||||
build_cache: ./build/dogma-jimfinium
|
build_cache: ./build/dogma-jimfinium
|
||||||
web_root: ./dist/dogma-jimfinium
|
web_root: ./dist/dogma-jimfinium
|
||||||
assets:
|
assets:
|
||||||
|
|||||||
@ -19,6 +19,13 @@ def pull_git_repo(repo: GitRepo, build_cache: str) -> None:
|
|||||||
else:
|
else:
|
||||||
run(f"git clone {repo.url}{(' -b '+repo.branch) if repo.branch else ''} -o {repo.remote} {build_cache}")
|
run(f"git clone {repo.url}{(' -b '+repo.branch) if repo.branch else ''} -o {repo.remote} {build_cache}")
|
||||||
|
|
||||||
|
# Download all LFS files.
|
||||||
|
if repo.lfs:
|
||||||
|
run('git lfs fetch --all')
|
||||||
|
run('git lfs pull')
|
||||||
|
|
||||||
|
return None
|
||||||
|
|
||||||
|
|
||||||
def copy_assets(site: SiteConfig) -> None:
|
def copy_assets(site: SiteConfig) -> None:
|
||||||
'''Copies the list of site assets from the build cache to the web root.
|
'''Copies the list of site assets from the build cache to the web root.
|
||||||
|
|||||||
@ -30,6 +30,7 @@ class GitRepo(pydantic.BaseModel):
|
|||||||
url: str
|
url: str
|
||||||
branch: Optional[str] = None
|
branch: Optional[str] = None
|
||||||
remote: Optional[str] = 'origin'
|
remote: Optional[str] = 'origin'
|
||||||
|
lfs: Optional[bool] = False
|
||||||
|
|
||||||
class SiteConfig(pydantic.BaseModel):
|
class SiteConfig(pydantic.BaseModel):
|
||||||
base_url: str
|
base_url: str
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user