mirror of
https://github.com/Cian-H/I-Form_Server_Node_Deployer.git
synced 2025-12-23 22:52:01 +00:00
15 lines
313 B
Python
15 lines
313 B
Python
from functools import wraps
|
|
from pathlib import Path
|
|
from typing import Callable
|
|
|
|
import config
|
|
|
|
|
|
def ensure_build_dir(f: Callable) -> Callable:
|
|
@wraps(f)
|
|
def wrapper(*args, **kwargs):
|
|
Path(config.BUILD_DIR).mkdir(exist_ok=True, parents=True)
|
|
return f(*args, **kwargs)
|
|
|
|
return wrapper
|