Skip to content

Commit

Permalink
disable update opt-out
Browse files Browse the repository at this point in the history
  • Loading branch information
NelsonDane committed Jun 8, 2024
1 parent 04ac0f4 commit 52821ea
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 8 deletions.
2 changes: 0 additions & 2 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@ DISCORD_TOKEN=
DISCORD_CHANNEL=

## OPTIONAL SETTINGS
# Whether or not the bot should update automatically
ENABLE_AUTO_UPDATE="true"
# USE AT YOUR OWN RISK: Wether the bot should wait for a confirmation before executing trades in the CLI
DANGER_MODE="false"

Expand Down
7 changes: 1 addition & 6 deletions helperAPI.py
Original file line number Diff line number Diff line change
Expand Up @@ -334,11 +334,6 @@ def get_result(self):


def updater():
# Check if disabled
if os.getenv("ENABLE_AUTO_UPDATE", "").lower() == "false":
print("Auto update disabled, skipping...")
print()
return
# Check if git is installed
try:
import git
Expand All @@ -349,7 +344,7 @@ def updater():
)
print()
return
print("Starting auto update. To disable, set ENABLE_AUTO_UPDATE to false in .env")
print("Starting auto update...")
try:
repo = Repo(".")
except git.exc.InvalidGitRepositoryError:
Expand Down

0 comments on commit 52821ea

Please sign in to comment.