Conditions | 4 |
Total Lines | 21 |
Lines | 0 |
Ratio | 0 % |
1 | #!/usr/bin/env python3 |
||
9 | def main(): |
||
10 | if not os.path.exists(DEPLOY_DIR): |
||
11 | print('ERROR: Deploy dir ' + DEPLOY_DIR + ' does not exists. Please set it in local_settings.py') |
||
12 | |||
13 | print('Deploying to: ' + DEPLOY_DIR) |
||
14 | |||
15 | filepaths = { |
||
16 | 'website/index.html', |
||
17 | 'website/station_map.js' |
||
18 | } |
||
19 | |||
20 | filepaths_css = { |
||
21 | 'website/css/nsmaps.css', |
||
22 | 'website/css/bootstrap_readable.min.css' |
||
23 | } |
||
24 | |||
25 | for file in filepaths: |
||
26 | subprocess.check_call(['scp', file, DEPLOY_DIR]) |
||
27 | |||
28 | for file in filepaths_css: |
||
29 | subprocess.check_call(['scp', file, os.path.join(DEPLOY_DIR, 'css')]) |
||
30 | |||
33 | main() |