Mercurial > code > home > repos > streamed-graph
comparison tasks.py @ 35:29d8ed02a275
build and tests, including jsonld
author | drewp@bigasterisk.com |
---|---|
date | Sat, 28 Dec 2019 02:01:23 -0800 |
parents | b82c05e22d9a |
children | 895ae7c5b0f4 |
comparison
equal
deleted
inserted
replaced
34:3d8b98e9c01d | 35:29d8ed02a275 |
---|---|
5 def setup_npm(ctx): | 5 def setup_npm(ctx): |
6 ctx.run('npm run install') | 6 ctx.run('npm run install') |
7 | 7 |
8 @task | 8 @task |
9 def serve_demo(ctx): | 9 def serve_demo(ctx): |
10 ctx.run('npm run webpack-dev-server') | 10 ctx.run('webfsd -Fp 8021') |
11 | 11 |
12 @task | 12 @task |
13 def build(ctx): | 13 def build(ctx): |
14 ctx.run(f'npm run webpack-build', pty=True) | 14 ctx.run(f'npm run build', pty=True) |
15 ctx.run(f'cp build/bundle.js /my/site/homepage/www/rdf/streamed-graph.bundle.js') | |
16 ctx.run(f'cp src/streamed-graph.css /my/site/homepage/www/rdf/streamed-graph.css') | |
17 | 15 |
18 @task | 16 @task |
19 def build_forever(ctx): | 17 def build_forever(ctx): |
20 ctx.run(f'npm run run webpack-build-forever', pty=True) | 18 ctx.run(f'npm run build_forever', pty=True) |
21 | |
22 @task | |
23 def dev_server(ctx): | |
24 ctx.run(f'npm run webpack-dev-server', pty=True) | |
25 | 19 |
26 @task | 20 @task |
27 def test(ctx): | 21 def test(ctx): |
28 ctx.run(f'npm run test', pty=True) | 22 ctx.run(f'npm run test', pty=True) |
29 | 23 |
30 @task | 24 @task |
31 def test_forever(ctx): | 25 def test_forever(ctx): |
32 ctx.run(f'npm run test-forever', pty=True) | 26 ctx.run(f'npm run test_forever', pty=True) |
27 | |
28 @task(pre=[build]) | |
29 def install(ctx): | |
30 ctx.run(f'cp build/bundle.js /my/site/homepage/www/rdf/streamed-graph.bundle.js') | |
31 ctx.run(f'cp src/streamed-graph.css /my/site/homepage/www/rdf/streamed-graph.css') |