File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -154,7 +154,7 @@ options:
154154
155155Retrieve all workflows and actions associated with the organization.
156156``` bash
157- raven download org --token $GITHUB_TOKEN --org-name microsoft --debug
157+ raven download org --token $GITHUB_TOKEN --org-name microsoft --org-name google -- debug
158158```
159159
160160Scrape all publicly accessible GitHub repositories.
Original file line number Diff line number Diff line change @@ -8,7 +8,6 @@ monotonic==1.6
88packaging == 23.1
99pansi == 2020.7.3
1010pluggy == 1.3.0
11- py2neo == 2021.2.3
1211Pygments == 2.16.1
1312pytest == 7.4.2
1413pytz == 2023.3.post1
@@ -19,4 +18,6 @@ six==1.16.0
1918slack-sdk == 3.22.0
2019tabulate == 0.9.0
2120tqdm == 4.66.1
22- urllib3 == 2.0.5
21+ urllib3 == 2.0.5
22+
23+ py2neo @ git+https://github.com/elad-pticha/py2neo.git@d684901abeeb1484e5b396d4b6cef491c4bd8271#egg=py2neo
Original file line number Diff line number Diff line change @@ -151,6 +151,8 @@ def raven() -> None:
151151 org_download_parser .add_argument (
152152 "--org-name" ,
153153 required = True ,
154+ action = "append" ,
155+ type = str ,
154156 help = "Organization name to download the workflows" ,
155157 )
156158
Original file line number Diff line number Diff line change @@ -96,7 +96,7 @@ class Config:
9696 github_token : str = None
9797 min_stars : int = None
9898 max_stars : int = None
99- org_name : str = None
99+ org_name : list [ str ] = []
100100
101101 # Indexer Configs
102102 clean_neo4j : bool = None
Original file line number Diff line number Diff line change @@ -34,14 +34,17 @@ def download_org_workflows_and_actions() -> None:
3434 We are trying to cache the downloads as much as we can to reduce redundant download attempts.
3535 """
3636 log .debug ("[+] Starting organization repository iterator" )
37- generator = get_organization_repository_generator (Config .org_name )
3837
39- # Clean redis
40- if Config . clean_redis :
41- clean_redis_db ( )
38+ for organization in Config . org_name :
39+ log . debug ( f"[+] Scanning { organization } " )
40+ generator = get_organization_repository_generator ( organization )
4241
43- for repo in generator :
44- download_workflows_and_actions (repo )
42+ # Clean redis
43+ if Config .clean_redis :
44+ clean_redis_db ()
45+
46+ for repo in generator :
47+ download_workflows_and_actions (repo )
4548
4649
4750def download_all_workflows_and_actions () -> None :
Original file line number Diff line number Diff line change 1515
1616def load_integration_tests_config () -> None :
1717 load_downloader_config (
18- {"debug" : False , "token" : getenv ("GITHUB_TOKEN" ), "org_name" : "RavenDemo" }
18+ {"debug" : False , "token" : getenv ("GITHUB_TOKEN" ), "org_name" : [ "RavenDemo" ] }
1919 )
2020
2121 load_indexer_config (
You can’t perform that action at this time.
0 commit comments