Lines Matching full:options
74 def is_npm_newer_than_6(options): argument
75 cmd = [options.npm, '-v']
76 stdout = run_cmd(cmd, options.source_path)
89 def build(options): argument
90 build_cmd = [options.npm, 'run', 'build']
91 pack_cmd = [options.npm, 'pack']
92 run_cmd(build_cmd, options.source_path)
93 run_cmd(pack_cmd, options.source_path)
96 def copy_output(options): argument
97 run_cmd(['rm', '-rf', options.output_path])
98 src = os.path.join(options.source_path, 'panda-tslinter-{}.tgz'.format(options.version))
99 dest = os.path.join(options.output_path, 'panda-tslinter-{}.tgz'.format(options.version))
103 tar.extractall(path=options.output_path)
106 copy_files(os.path.join(options.output_path, 'package'), options.output_path)
107 run_cmd(['rm', '-rf', os.path.join(options.output_path, 'package')])
109 src = os.path.join(options.source_path, 'tsconfig.json')
110 dest = os.path.join(options.output_path, 'tsconfig.json')
114 def install_typescript(options): argument
115 new_npm = is_npm_newer_than_6(options)
116 tsc_file = 'file:' + options.typescript
118 cmd = [options.npm, 'install', '--no-save', tsc_file, '--legacy-peer-deps', '--offline']
120 cmd = [options.npm, 'install', '--no-save', tsc_file]
121 run_cmd(cmd, options.source_path)
176 def aa_copy_lib_files(options): argument
177 aa_path = os.path.join(options.source_path, 'arkanalyzer')
185 def hc_copy_lib_files(options): argument
186 hc_path = os.path.join(options.source_path, 'homecheck')
192 def pack_arkanalyzer(options, new_npm): argument
193 aa_path = os.path.join(options.source_path, 'arkanalyzer')
194 tsc_file = 'file:' + options.typescript
200 …ts_install_cmd = [options.npm, 'install', '--no-save', tsc_file, '--legacy-peer-deps', '--offline']
202 ts_install_cmd = [options.npm, 'install', '--no-save', tsc_file]
203 compile_cmd = [options.npm, 'run', 'compile']
204 pack_cmd = [options.npm, 'pack']
206 aa_copy_lib_files(options)
211 def install_homecheck(options, max_retries, wait_time): argument
212 new_npm = is_npm_newer_than_6(options)
213 pack_arkanalyzer(options, new_npm)
214 aa_path = os.path.join(options.source_path, 'arkanalyzer')
215 hc_path = os.path.join(options.source_path, 'homecheck')
223 aa_install_cmd = [options.npm, 'install', aa_file, '--legacy-peer-deps', '--offline']
225 aa_install_cmd = [options.npm, 'install', aa_file]
231 tsc_file = 'file:' + options.typescript
233 …ts_install_cmd = [options.npm, 'install', '--no-save', tsc_file, '--legacy-peer-deps', '--offline']
235 ts_install_cmd = [options.npm, 'install', '--no-save', tsc_file]
236 pack_cmd = [options.npm, 'pack']
237 compile_cmd = [options.npm, 'run', 'compile']
239 hc_copy_lib_files(options)
246 hc_install_cmd = [options.npm, 'install', hc_file, '--legacy-peer-deps', '--offline']
248 hc_install_cmd = [options.npm, 'install', hc_file]
249 run_cmd_with_retry(max_retries, wait_time, hc_install_cmd, options.source_path)
274 options = parser.parse_args()
275 return options
279 options = parse_args()
280 backup_package_files(options.source_path)
281 install_homecheck(options, 5, 3)
282 install_typescript(options)
283 node_modules_path = os.path.join(options.source_path, "node_modules")
284 extract(options.typescript, node_modules_path, "typescript")
285 build(options)
286 copy_output(options)
287 clean_env(options.source_path)