clan-cli: Fix clan flakes create not working in nix shell
This commit is contained in:
@@ -1,6 +1,5 @@
|
|||||||
import json
|
import json
|
||||||
import logging
|
import logging
|
||||||
import os
|
|
||||||
import shutil
|
import shutil
|
||||||
import stat
|
import stat
|
||||||
from dataclasses import dataclass, field
|
from dataclasses import dataclass, field
|
||||||
@@ -63,10 +62,12 @@ class ClanExports(TypedDict):
|
|||||||
def get_clan_nix_attrset(clan_dir: FlakeId | None = None) -> ClanExports:
|
def get_clan_nix_attrset(clan_dir: FlakeId | None = None) -> ClanExports:
|
||||||
# Check if the clan directory is provided, otherwise use the environment variable
|
# Check if the clan directory is provided, otherwise use the environment variable
|
||||||
if not clan_dir:
|
if not clan_dir:
|
||||||
clan_core_path = os.environ.get("CLAN_CORE_PATH")
|
# TODO: Quickfix, templates dir seems to be missing in CLAN_CORE_PATH??
|
||||||
if not clan_core_path:
|
clan_core_path = "git+https://git.clan.lol/clan/clan-core"
|
||||||
msg = "Environment var CLAN_CORE_PATH is not set, this shouldn't happen"
|
# clan_core_path = os.environ.get("CLAN_CORE_PATH")
|
||||||
raise ClanError(msg)
|
# if not clan_core_path:
|
||||||
|
# msg = "Environment var CLAN_CORE_PATH is not set, this shouldn't happen"
|
||||||
|
# raise ClanError(msg)
|
||||||
|
|
||||||
clan_dir = FlakeId(clan_core_path)
|
clan_dir = FlakeId(clan_core_path)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user