Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions agentstack/repo.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
from typing import Optional
from types import ModuleType
from pathlib import Path
import shutil
import git
from agentstack import conf, log
from agentstack.exceptions import EnvironmentError


MAIN_BRANCH_NAME = "main"

AUTOMATION_NOTE = "\n\n(This commit was made automatically by AgentStack)"
Expand All @@ -15,6 +14,14 @@
_USE_GIT = None # global state to disable git for this run


# The python git module prints an excessive error message when git is not
# installed. We always want to allow git support to fail silently.
try:
import git
except ImportError:
_USE_GIT = False


def should_track_changes() -> bool:
"""
If git has been disabled for this run, return False. Next, look for the value
Expand Down
Loading