This repository was archived by the owner on Sep 21, 2021. It is now read-only.
File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree 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
1010## Quick Start
1111
1212``` yaml
13- - uses : " treebeardtech/nbmake@v0.2"
13+ - uses : " treebeardtech/nbmake-action @v0.2"
1414 with :
1515 path : " ./examples"
16- html : true
16+ path-output : .
1717 notebooks : |
1818 nb1.ipynb
1919 'sub dir/*.ipynb'
Original file line number Diff line number Diff line change @@ -23,7 +23,6 @@ inputs:
2323 path-output :
2424 description : " Create an html report to `{path_output}_build/html`"
2525 required : false
26- default : " ."
2726
2827 overwrite :
2928 description : >
Original file line number Diff line number Diff line change @@ -2866,7 +2866,7 @@ function run() {
28662866 const notebooks = core . getInput ( 'notebooks' ) ;
28672867 const ignore = core . getInput ( 'ignore' ) ;
28682868 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' ) ) ;
28702870 const verbose = core . getInput ( 'verbose' ) . toLowerCase ( ) === 'true' ;
28712871 const overwrite = core . getInput ( 'overwrite' ) . toLowerCase ( ) === 'true' ;
28722872 const extraPytestArgs = core . getInput ( 'extra-pytest-args' ) ;
@@ -2875,7 +2875,11 @@ function run() {
28752875 yield exec . exec ( 'bash' , [ '-c' , 'pwd && ls -la' ] ) ;
28762876 }
28772877 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 } ` ) ;
28792883 core . endGroup ( ) ;
28802884 const paths = notebooks . split ( '\n' ) . filter ( n => n ) ;
28812885 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> {
1111 const notebooks = core . getInput ( 'notebooks' )
1212 const ignore = core . getInput ( 'ignore' )
1313 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' ) )
1516 const verbose = core . getInput ( 'verbose' ) . toLowerCase ( ) === 'true'
1617 const overwrite = core . getInput ( 'overwrite' ) . toLowerCase ( ) === 'true'
1718 const extraPytestArgs = core . getInput ( 'extra-pytest-args' )
@@ -23,9 +24,11 @@ async function run(): Promise<void> {
2324 }
2425
2526 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 } ` )
2932 core . endGroup ( )
3033
3134 const paths = notebooks . split ( '\n' ) . filter ( n => n )
You can’t perform that action at this time.
0 commit comments