My goal: is to automate a boring task on github
What: I want to click on "add file" and than "create new file"

If no id or the element has dynamic id, use XPATH. Using class is not ideal, since the class will possibly reused by many other elements.
In this case, use this XPATH: //summary[.//span[contains(text(),"Add file")]]
Best practice: use fluent wait
WebDriverWait(driver, 15).until(
EC.visibility_of_element_located(
(By.XPATH, '//summary[.//span[contains(text(),"Add file")]]')
))
Read docs about explicit/fluent wait: https://selenium-python.readthedocs.io/waits.html#explicit-waits
You could try driver.find_element_by_xpath("[xpath goes here]")
If you want to read more, here are the official docs for locating elements.
from selenium import webdirver
#define your executable path
browser = webdriver.Chrome(executable path=" ")
browser.get("**")
browser.find_element_by_xpath("put your copied xpath here")
driver.find_element_by_class_name