annotate tasks.py @ 34:3d8b98e9c01d

building, but without jsonld so far
author drewp@bigasterisk.com
date Fri, 27 Dec 2019 21:26:55 -0800
parents b82c05e22d9a
children 29d8ed02a275
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
drewp@localhost
parents:
diff changeset
1 from invoke import task # pytype: disable=import-error
drewp@localhost
parents:
diff changeset
2
drewp@localhost
parents:
diff changeset
3
drewp@localhost
parents:
diff changeset
4 @task
drewp@localhost
parents:
diff changeset
5 def setup_npm(ctx):
33
b82c05e22d9a change to npm with a build that worked better as a local package to be shared
drewp@bigasterisk.com
parents: 31
diff changeset
6 ctx.run('npm run install')
0
drewp@localhost
parents:
diff changeset
7
drewp@localhost
parents:
diff changeset
8 @task
drewp@localhost
parents:
diff changeset
9 def serve_demo(ctx):
33
b82c05e22d9a change to npm with a build that worked better as a local package to be shared
drewp@bigasterisk.com
parents: 31
diff changeset
10 ctx.run('npm run webpack-dev-server')
0
drewp@localhost
parents:
diff changeset
11
drewp@localhost
parents:
diff changeset
12 @task
drewp@localhost
parents:
diff changeset
13 def build(ctx):
33
b82c05e22d9a change to npm with a build that worked better as a local package to be shared
drewp@bigasterisk.com
parents: 31
diff changeset
14 ctx.run(f'npm run webpack-build', pty=True)
b82c05e22d9a change to npm with a build that worked better as a local package to be shared
drewp@bigasterisk.com
parents: 31
diff changeset
15 ctx.run(f'cp build/bundle.js /my/site/homepage/www/rdf/streamed-graph.bundle.js')
b82c05e22d9a change to npm with a build that worked better as a local package to be shared
drewp@bigasterisk.com
parents: 31
diff changeset
16 ctx.run(f'cp src/streamed-graph.css /my/site/homepage/www/rdf/streamed-graph.css')
29
45ed53428e74 fix configs to run tests (all in one bundle though)
drewp@bigasterisk.com
parents: 25
diff changeset
17
45ed53428e74 fix configs to run tests (all in one bundle though)
drewp@bigasterisk.com
parents: 25
diff changeset
18 @task
45ed53428e74 fix configs to run tests (all in one bundle though)
drewp@bigasterisk.com
parents: 25
diff changeset
19 def build_forever(ctx):
33
b82c05e22d9a change to npm with a build that worked better as a local package to be shared
drewp@bigasterisk.com
parents: 31
diff changeset
20 ctx.run(f'npm run run webpack-build-forever', pty=True)
29
45ed53428e74 fix configs to run tests (all in one bundle though)
drewp@bigasterisk.com
parents: 25
diff changeset
21
45ed53428e74 fix configs to run tests (all in one bundle though)
drewp@bigasterisk.com
parents: 25
diff changeset
22 @task
45ed53428e74 fix configs to run tests (all in one bundle though)
drewp@bigasterisk.com
parents: 25
diff changeset
23 def dev_server(ctx):
33
b82c05e22d9a change to npm with a build that worked better as a local package to be shared
drewp@bigasterisk.com
parents: 31
diff changeset
24 ctx.run(f'npm run webpack-dev-server', pty=True)
9
26d3e4860adc working on porting graph_view to n3.js. also working on making tests run
drewp@bigasterisk.com
parents: 0
diff changeset
25
26d3e4860adc working on porting graph_view to n3.js. also working on making tests run
drewp@bigasterisk.com
parents: 0
diff changeset
26 @task
26d3e4860adc working on porting graph_view to n3.js. also working on making tests run
drewp@bigasterisk.com
parents: 0
diff changeset
27 def test(ctx):
33
b82c05e22d9a change to npm with a build that worked better as a local package to be shared
drewp@bigasterisk.com
parents: 31
diff changeset
28 ctx.run(f'npm run test', pty=True)
29
45ed53428e74 fix configs to run tests (all in one bundle though)
drewp@bigasterisk.com
parents: 25
diff changeset
29
45ed53428e74 fix configs to run tests (all in one bundle though)
drewp@bigasterisk.com
parents: 25
diff changeset
30 @task
45ed53428e74 fix configs to run tests (all in one bundle though)
drewp@bigasterisk.com
parents: 25
diff changeset
31 def test_forever(ctx):
33
b82c05e22d9a change to npm with a build that worked better as a local package to be shared
drewp@bigasterisk.com
parents: 31
diff changeset
32 ctx.run(f'npm run test-forever', pty=True)