@@ -137,6 +137,14 @@ def main():
137
137
method = args .method or method
138
138
logger .debug ('Inventory Method: %s' , method )
139
139
140
+ organization = config_json .get ('organization' , '' )
141
+ organization = args .organization or organization
142
+ logger .debug ('Organization: %s' , organization )
143
+
144
+ contact_email = config_json .get ('contact_email' , '' )
145
+ contact_email = args .contact_email or contact_email
146
+ logger .debug ('Contact Email: %s' , contact_email )
147
+
140
148
github_orgs = config_json .get ('github_orgs' , [])
141
149
github_orgs .extend (args .github_orgs )
142
150
logger .debug ('GitHub.com Organizations: %s' , github_orgs )
@@ -169,15 +177,15 @@ def main():
169
177
logger .warning ('Unbale to find DOECode json file: %s' , doecode_json )
170
178
171
179
# Force certain fields
172
- if args . organization :
173
- logger .debug ('Forcing Organiation to: %s' , args . organzation )
180
+ if organization :
181
+ logger .debug ('Forcing Organiation to: %s' , organization )
174
182
for release in code_json ['releases' ]:
175
- release ['organization' ] = args . organization
183
+ release ['organization' ] = organization
176
184
177
- if args . contact_email :
178
- logger .debug ('Forcing Contact Email to: %s' , args . contact_email )
185
+ if contact_email :
186
+ logger .debug ('Forcing Contact Email to: %s' , contact_email )
179
187
for release in code_json ['releases' ]:
180
- release ['contact' ]['email' ] = args . contact_email
188
+ release ['contact' ]['email' ] = contact_email
181
189
182
190
str_org_projects = code_json .to_json ()
183
191
0 commit comments