upload du fichier ini template

commit avant de rajouter le fichier ini au fichier gitignore
This commit is contained in:
Guillaume 2022-04-24 14:35:20 +02:00
parent 337f7f5488
commit c352cc9ff8
3 changed files with 47 additions and 0 deletions

1
.gitignore vendored
View File

@ -138,3 +138,4 @@ dmypy.json
# Cython debug symbols
cython_debug/
chromedriver

3
login.ini Normal file
View File

@ -0,0 +1,3 @@
[linkedin]
login = user@domain.com
password = password

43
main.py Normal file
View File

@ -0,0 +1,43 @@
#%%
from unicodedata import name
from selenium import webdriver
from selenium.webdriver.common.keys import Keys
from selenium.webdriver.chrome.options import Options
import bs4 as BeautifulSoup
from random import uniform
import configparser
def connection_linkedin(driver:webdriver, user:str, mdp:str):
"""permet de gérer la connexion à linkedin dans le webdriver
Args:
driver (webdriver): instance du webdriver active
user (str): adresse mail du compte linkedin
mdp (str): mot de passe du compte linkedin
"""
if __name__ == "__main__":
print("coucou")
config = configparser.ConfigParser()
config.read('login.ini')
config['bitbucket.org'] = {}
chrome_options = Options()
#chrome_options.add_argument("--disable-extensions")
#chrome_options.add_argument("--disable-gpu")
#chrome_options.add_argument("--headless")
driver = webdriver.Chrome(executable_path = './chromedriver', chrome_options=chrome_options)