Skip to content
Permalink
Browse files
Imported environment variables
  • Loading branch information
hollan84 committed May 3, 2020
1 parent 0fc6cc0 commit e209cfc7f40de9adee97de78f93dff8bfe49a968
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 1 deletion.
@@ -4,4 +4,6 @@ Custom.py
nicknames/
oldCustom/
__pycache__/
lib/custom.py
lib/custom.py
lib/..env.swp
lib/__pycache__/librarySetup.cpython-36.pyc
Binary file not shown.
@@ -5,6 +5,10 @@ from mcstatus import MinecraftServer
from datetime import datetime
from datetime import timedelta
from shutil import copyfile
copyfile(".env", "lib/.env")

from dotenv import load_dotenv
load_dotenv()

server = MinecraftServer(os.environ['SERVER'], int(os.environ['PORT']))

@@ -18,6 +18,13 @@ def checkLibraries():
import mcstatus
except:
os.system("pip3 install mcstatus")
try:
import status
except:
os.system("pip3 install status")
try:
import dotenv
except:
os.system("pip3 install python-dotenv")

checkLibraries()

0 comments on commit e209cfc

Please sign in to comment.