mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
make installer use initial INVOKEAI_ROOT as default install location
This commit is contained in:
parent
781322a647
commit
c2eb50d1cd
@ -149,7 +149,7 @@ class Installer:
|
|||||||
return venv_dir
|
return venv_dir
|
||||||
|
|
||||||
def install(
|
def install(
|
||||||
self, root: str = "~/invokeai-3", version: str = "latest", yes_to_all=False, find_links: Path = None
|
self, root: str = "~/invokeai", version: str = "latest", yes_to_all=False, find_links: Path = None
|
||||||
) -> None:
|
) -> None:
|
||||||
"""
|
"""
|
||||||
Install the InvokeAI application into the given runtime path
|
Install the InvokeAI application into the given runtime path
|
||||||
@ -168,9 +168,7 @@ class Installer:
|
|||||||
|
|
||||||
messages.welcome()
|
messages.welcome()
|
||||||
|
|
||||||
invokeai_root = os.environ.get('INVOKEAI_ROOT')
|
default_path = os.environ.get('INVOKEAI_ROOT') or Path(root).expanduser().resolve()
|
||||||
default_path = invokeai_root or Path(root).expanduser().resolve()
|
|
||||||
|
|
||||||
self.dest = default_path if yes_to_all else messages.dest_path(root)
|
self.dest = default_path if yes_to_all else messages.dest_path(root)
|
||||||
|
|
||||||
# create the venv for the app
|
# create the venv for the app
|
||||||
|
@ -3,6 +3,7 @@ InvokeAI Installer
|
|||||||
"""
|
"""
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
|
import os
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
from installer import Installer
|
from installer import Installer
|
||||||
|
|
||||||
@ -15,7 +16,7 @@ if __name__ == "__main__":
|
|||||||
dest="root",
|
dest="root",
|
||||||
type=str,
|
type=str,
|
||||||
help="Destination path for installation",
|
help="Destination path for installation",
|
||||||
default="~/invokeai",
|
default=os.environ.get('INVOKEAI_ROOT') or "~/invokeai",
|
||||||
)
|
)
|
||||||
parser.add_argument(
|
parser.add_argument(
|
||||||
"-y",
|
"-y",
|
||||||
|
Loading…
Reference in New Issue
Block a user