This repository was archived by the owner on Sep 21, 2021. It is now read-only.
File tree 4 files changed +15
-9
lines changed
4 files changed +15
-9
lines changed Original file line number Diff line number Diff line change @@ -10,10 +10,10 @@ Tests notebooks using [nbmake](https://github.com/treebeardtech/nbmake) via pyte
10
10
## Quick Start
11
11
12
12
``` yaml
13
- -
uses :
" treebeardtech/[email protected] "
13
+ - uses : " treebeardtech/nbmake-action @v0.2"
14
14
with :
15
15
path : " ./examples"
16
- html : true
16
+ path-output : .
17
17
notebooks : |
18
18
nb1.ipynb
19
19
'sub dir/*.ipynb'
Original file line number Diff line number Diff line change @@ -23,7 +23,6 @@ inputs:
23
23
path-output :
24
24
description : " Create an html report to `{path_output}_build/html`"
25
25
required : false
26
- default : " ."
27
26
28
27
overwrite :
29
28
description : >
Original file line number Diff line number Diff line change @@ -2866,7 +2866,7 @@ function run() {
2866
2866
const notebooks = core . getInput ( 'notebooks' ) ;
2867
2867
const ignore = core . getInput ( 'ignore' ) ;
2868
2868
const workdir = core . getInput ( 'workdir' ) ;
2869
- const pathOutput = path . resolve ( core . getInput ( 'path-output' ) ) ;
2869
+ const pathOutput = core . getInput ( 'path-output' ) && path . resolve ( core . getInput ( 'path-output' ) ) ;
2870
2870
const verbose = core . getInput ( 'verbose' ) . toLowerCase ( ) === 'true' ;
2871
2871
const overwrite = core . getInput ( 'overwrite' ) . toLowerCase ( ) === 'true' ;
2872
2872
const extraPytestArgs = core . getInput ( 'extra-pytest-args' ) ;
@@ -2875,7 +2875,11 @@ function run() {
2875
2875
yield exec . exec ( 'bash' , [ '-c' , 'pwd && ls -la' ] ) ;
2876
2876
}
2877
2877
core . startGroup ( 'Install test packages' ) ;
2878
- yield exec . exec ( 'pip install pytest "git+https://github.com/treebeardtech/nbmake.git@main"' ) ;
2878
+ // const pkg = `git+https://github.com/treebeardtech/nbmake.git@main${
2879
+ // pathOutput ? '#egg=nbmake[html]' : ''
2880
+ // }`
2881
+ const pkg = `nbmake${ pathOutput ? '[html]' : '' } ==0.1` ;
2882
+ yield exec . exec ( `pip install ${ pkg } ` ) ;
2879
2883
core . endGroup ( ) ;
2880
2884
const paths = notebooks . split ( '\n' ) . filter ( n => n ) ;
2881
2885
const ignores = ignore . split ( '\n' ) . filter ( i => i ) ;
Original file line number Diff line number Diff line change @@ -11,7 +11,8 @@ async function run(): Promise<void> {
11
11
const notebooks = core . getInput ( 'notebooks' )
12
12
const ignore = core . getInput ( 'ignore' )
13
13
const workdir = core . getInput ( 'workdir' )
14
- const pathOutput = path . resolve ( core . getInput ( 'path-output' ) )
14
+ const pathOutput =
15
+ core . getInput ( 'path-output' ) && path . resolve ( core . getInput ( 'path-output' ) )
15
16
const verbose = core . getInput ( 'verbose' ) . toLowerCase ( ) === 'true'
16
17
const overwrite = core . getInput ( 'overwrite' ) . toLowerCase ( ) === 'true'
17
18
const extraPytestArgs = core . getInput ( 'extra-pytest-args' )
@@ -23,9 +24,11 @@ async function run(): Promise<void> {
23
24
}
24
25
25
26
core . startGroup ( 'Install test packages' )
26
- await exec . exec (
27
- 'pip install pytest "git+https://github.com/treebeardtech/nbmake.git@main"'
28
- )
27
+ // const pkg = `git+https://github.com/treebeardtech/nbmake.git@main${
28
+ // pathOutput ? '#egg=nbmake[html]' : ''
29
+ // }`
30
+ const pkg = `nbmake${ pathOutput ? '[html]' : '' } ==0.1`
31
+ await exec . exec ( `pip install ${ pkg } ` )
29
32
core . endGroup ( )
30
33
31
34
const paths = notebooks . split ( '\n' ) . filter ( n => n )
You can’t perform that action at this time.
0 commit comments