File tree Expand file tree Collapse file tree 1 file changed +11
-4
lines changed Expand file tree Collapse file tree 1 file changed +11
-4
lines changed Original file line number Diff line number Diff line change @@ -35,11 +35,18 @@ function pyprojectTomlToRequirements() {
35
35
36
36
const editableLine = new RegExp ( / ^ - e / gm) ;
37
37
const sourceRequirements = path . join ( this . servicePath , 'requirements.txt' ) ;
38
- const requirementsContents = fse . readFileSync ( sourceRequirements , { encoding : 'utf-8' } ) ;
39
-
38
+ const requirementsContents = fse . readFileSync ( sourceRequirements , {
39
+ encoding : 'utf-8'
40
+ } ) ;
41
+
40
42
if ( requirementsContents . match ( editableLine ) ) {
41
- this . serverless . cli . log ( 'The generated file contains -e lines, removing them...' ) ;
42
- fse . writeFileSync ( sourceRequirements , requirementsContents . replace ( editableLine , '' ) )
43
+ this . serverless . cli . log (
44
+ 'The generated file contains -e lines, removing them...'
45
+ ) ;
46
+ fse . writeFileSync (
47
+ sourceRequirements ,
48
+ requirementsContents . replace ( editableLine , '' )
49
+ ) ;
43
50
}
44
51
45
52
fse . ensureDirSync ( path . join ( this . servicePath , '.serverless' ) ) ;
You can’t perform that action at this time.
0 commit comments