File tree Expand file tree Collapse file tree 4 files changed +11
-4
lines changed Expand file tree Collapse file tree 4 files changed +11
-4
lines changed Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ FROM mcr.microsoft.com/windows/servercore:ltsc2019
33SHELL ["powershell" , "-Command" , "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';" ]
44
55# PATH isn't actually set in the Docker image, so we have to set it from within the container
6- RUN $newPath = ('C:\n odejs;{0}\Y arn\b in;{1}; C:\P rogram Files (x86)\G nuPG\b in' -f $env:LOCALAPPDATA, $env:PATH); \
6+ RUN $newPath = ('C:\n odejs;{0}\Y arn\b in;C:\P rogram Files (x86)\G nuPG\b in;{1} ' -f $env:LOCALAPPDATA, $env:PATH); \
77 Write-Host ('Updating PATH: {0}' -f $newPath); \
88 [Environment]::SetEnvironmentVariable('PATH' , $newPath, [EnvironmentVariableTarget]::Machine)
99# doing this first to share cache across versions more aggressively
Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ FROM mcr.microsoft.com/windows/servercore:ltsc2022
33SHELL ["powershell" , "-Command" , "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';" ]
44
55# PATH isn't actually set in the Docker image, so we have to set it from within the container
6- RUN $newPath = ('C:\n odejs;{0}\Y arn\b in;{1}; C:\P rogram Files (x86)\G nuPG\b in' -f $env:LOCALAPPDATA, $env:PATH); \
6+ RUN $newPath = ('C:\n odejs;{0}\Y arn\b in;C:\P rogram Files (x86)\G nuPG\b in;{1} ' -f $env:LOCALAPPDATA, $env:PATH); \
77 Write-Host ('Updating PATH: {0}' -f $newPath); \
88 [Environment]::SetEnvironmentVariable('PATH' , $newPath, [EnvironmentVariableTarget]::Machine)
99# doing this first to share cache across versions more aggressively
Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ FROM mcr.microsoft.com/windows/servercore:version
33SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"]
44
55# PATH isn't actually set in the Docker image, so we have to set it from within the container
6- RUN $newPath = ('C:\nodejs;{0}\Yarn\bin;{1}; C:\Program Files (x86)\GnuPG\bin' -f $env:LOCALAPPDATA, $env:PATH); \
6+ RUN $newPath = ('C:\nodejs;{0}\Yarn\bin;C:\Program Files (x86)\GnuPG\bin;{1} ' -f $env:LOCALAPPDATA, $env:PATH); \
77 Write-Host ('Updating PATH: {0}' -f $newPath); \
88 [Environment]::SetEnvironmentVariable('PATH', $newPath, [EnvironmentVariableTarget]::Machine)
99# doing this first to share cache across versions more aggressively
Original file line number Diff line number Diff line change @@ -8,21 +8,28 @@ const testFiles = [
88] ;
99
1010const nodeDirRegex = / ^ \d + $ / ;
11+ // Directories starting with 'windows-' are excluded from the matrix windows-2019 are excluded for example
1112const windowsDirRegex = / ^ w i n d o w s - / ;
1213
1314const areTestFilesChanged = ( changedFiles ) => changedFiles
1415 . some ( ( file ) => testFiles . includes ( file ) ) ;
1516
1617// Returns a list of the child directories in the given path, excluding those starting with 'windows-'
1718const getChildDirectories = ( parent ) => fs . readdirSync ( parent , { withFileTypes : true } )
18- . filter ( ( dirent ) => dirent . isDirectory ( ) && ! windowsDirRegex . test ( dirent . name ) )
19+ . filter ( ( directory ) => directory . isDirectory ( ) )
1920 . map ( ( { name } ) => path . resolve ( parent , name ) ) ;
2021
2122const getNodeVersionDirs = ( base ) => getChildDirectories ( base )
2223 . filter ( ( childPath ) => nodeDirRegex . test ( path . basename ( childPath ) ) ) ;
2324
2425// Returns the paths of Dockerfiles that are at: base/*/Dockerfile
2526const getDockerfilesInChildDirs = ( base ) => getChildDirectories ( base )
27+ . filter ( ( directory ) => directory . isDirectory ( ) && ! windowsDirRegex . test ( directory . name ) )
28+ // Test print the directories
29+ . map ( ( childDir ) => {
30+ console . log ( childDir ) ;
31+ return childDir ;
32+ } )
2633 . map ( ( childDir ) => path . resolve ( childDir , 'Dockerfile' ) ) ;
2734
2835const getAllDockerfiles = ( base ) => getNodeVersionDirs ( base ) . flatMap ( getDockerfilesInChildDirs ) ;
You can’t perform that action at this time.
0 commit comments