Added silent mode

main
Graham Helton 3 years ago
parent 8b78481ea1
commit c243961df5

@ -6,6 +6,11 @@ pip3 install selenium colorama
```
# Usage
To run simple create a file called config.json in the directory above where you installed the tool (Please don't put a config.json in a git directory...). I recommend not testing with real info until you're sure this behaves how you expect it to.
### Silent mode
Runs firefox in headless mode. (Does not open the browser)
```python
python3 happySnake.py -s
````
# Example
![](example.gif)

@ -7,6 +7,7 @@ from selenium.webdriver.support.select import Select
from colorama import init, Fore, Style
import json
import time
import sys
#Initialize variables and get config
with open('../config.json') as configFile:
data=json.load(configFile)
@ -37,7 +38,9 @@ print(Fore.GREEN +
def goToParent():
driver.switch_to.parent_frame();
#options.add_argument("--headless")
if "-s" in sys.argv:
options.add_argument("--headless")
driver = webdriver.Firefox(options=options)
driver.get("https://happymugcoffee.com/collections/roasted-coffee")

Loading…
Cancel
Save