diff --git a/docs/source/install.rst b/docs/source/install.rst index e50cd8d..fbcb877 100644 --- a/docs/source/install.rst +++ b/docs/source/install.rst @@ -1,2 +1,14 @@ Installation -============ \ No newline at end of file +============ + +1. Git clone repository: + +https://gitlab.tjhsst.edu/understudyathon-2020/group-1/schoolos.git + +2. Install repository and create env + +cd SkoolOS +python3 -m venv env +source env/bin/activate +pip install -r requirements.txt + diff --git a/skoolos.py b/skoolos.py index a5dfb83..4b831bd 100644 --- a/skoolos.py +++ b/skoolos.py @@ -596,8 +596,22 @@ def authenticate(): # Linux: chromdriver-linux # Macos: chromdriver-mac # Windows: chromdriver.exe - path = os.path.join(os.getcwd(), 'chromedriver', 'chromedriver-mac') + print("OS: ") + print("MacOS") + print("Linux") + print("Windows") + os = input("Enter OS: ") + while(os != "Windows" or os != "Linux" or os != "Macos"): + print("Not valid OS") + os = input("Enter OS: ") + if(os == 'Windows'): + path = os.path.join(os.getcwd(), 'chromedriver', 'chromedriver.exe') + if(os == 'MacOS'): + path = os.path.join(os.getcwd(), 'chromedriver', 'chromedriver-linux') + if(os == 'Linux'): + path = os.path.join(os.getcwd(), 'chromedriver', 'chromedriver-mac') + browser = webdriver.Chrome(path) browser.get("localhost:8000/login")