File tree Expand file tree Collapse file tree 5 files changed +23
-10
lines changed Expand file tree Collapse file tree 5 files changed +23
-10
lines changed Original file line number Diff line number Diff line change 7575 " MongoDB Compass Dev-linux-x64/resources/app.asar" ,
7676 " MongoDB Compass Dev-linux-x64/resources/app.asar.unpacked" ,
7777 " MongoDB Compass Dev-linux-x64/resources/app.asar.unpacked/build" ,
78- " MongoDB Compass Dev-linux-x64/resources/app.asar.unpacked/build/84fc954083bb6d32e961b8196464fa9d .node" ,
78+ " MongoDB Compass Dev-linux-x64/resources/app.asar.unpacked/build/replaced-1 .node" ,
7979 " MongoDB Compass Dev-linux-x64/resources/app.asar.unpacked/build/assets" ,
8080 " MongoDB Compass Dev-linux-x64/resources/app.asar.unpacked/build/assets/mongo_crypt_v1.95074f92a2e898e8b2a6.so" ,
81- " MongoDB Compass Dev-linux-x64/resources/app.asar.unpacked/build/f8bdb8f7103e2cc8bfcca2814d77ec78 .node" ,
81+ " MongoDB Compass Dev-linux-x64/resources/app.asar.unpacked/build/replaced-2 .node" ,
8282 " MongoDB Compass Dev-linux-x64/resources/app.asar.unpacked/node_modules" ,
8383 " MongoDB Compass Dev-linux-x64/resources/app.asar.unpacked/node_modules/@mongosh" ,
8484 " MongoDB Compass Dev-linux-x64/resources/app.asar.unpacked/node_modules/@mongosh/node-runtime-worker-thread" ,
Original file line number Diff line number Diff line change 200200 " MongoDB Compass Dev.app/Contents/Resources/app.asar" ,
201201 " MongoDB Compass Dev.app/Contents/Resources/app.asar.unpacked" ,
202202 " MongoDB Compass Dev.app/Contents/Resources/app.asar.unpacked/build" ,
203- " MongoDB Compass Dev.app/Contents/Resources/app.asar.unpacked/build/1c37937dc0a3f1fcd210973f7aede3b3 .node" ,
203+ " MongoDB Compass Dev.app/Contents/Resources/app.asar.unpacked/build/replaced-1 .node" ,
204204 " MongoDB Compass Dev.app/Contents/Resources/app.asar.unpacked/build/assets" ,
205205 " MongoDB Compass Dev.app/Contents/Resources/app.asar.unpacked/build/assets/mongo_crypt_v1.2aae5c180e2677cc866d.dylib" ,
206206 " MongoDB Compass Dev.app/Contents/Resources/app.asar.unpacked/build/assets/mongo_crypt_v1.dylib" ,
207- " MongoDB Compass Dev.app/Contents/Resources/app.asar.unpacked/build/eb4812b21f732c9e226a92c5ea318857 .node" ,
207+ " MongoDB Compass Dev.app/Contents/Resources/app.asar.unpacked/build/replaced-2 .node" ,
208208 " MongoDB Compass Dev.app/Contents/Resources/app.asar.unpacked/node_modules" ,
209209 " MongoDB Compass Dev.app/Contents/Resources/app.asar.unpacked/node_modules/@mongosh" ,
210210 " MongoDB Compass Dev.app/Contents/Resources/app.asar.unpacked/node_modules/@mongosh/node-runtime-worker-thread" ,
Original file line number Diff line number Diff line change 7575 " MongoDB Compass Dev-linux-x64/resources/app.asar" ,
7676 " MongoDB Compass Dev-linux-x64/resources/app.asar.unpacked" ,
7777 " MongoDB Compass Dev-linux-x64/resources/app.asar.unpacked/build" ,
78- " MongoDB Compass Dev-linux-x64/resources/app.asar.unpacked/build/23881719120af2f3e971578efe6a9091 .node" ,
78+ " MongoDB Compass Dev-linux-x64/resources/app.asar.unpacked/build/replaced-1 .node" ,
7979 " MongoDB Compass Dev-linux-x64/resources/app.asar.unpacked/build/assets" ,
8080 " MongoDB Compass Dev-linux-x64/resources/app.asar.unpacked/build/assets/mongo_crypt_v1.95074f92a2e898e8b2a6.so" ,
81- " MongoDB Compass Dev-linux-x64/resources/app.asar.unpacked/build/f41384f0b23bc22383fa90d00e0bfcbe .node" ,
81+ " MongoDB Compass Dev-linux-x64/resources/app.asar.unpacked/build/replaced-2 .node" ,
8282 " MongoDB Compass Dev-linux-x64/resources/app.asar.unpacked/node_modules" ,
8383 " MongoDB Compass Dev-linux-x64/resources/app.asar.unpacked/node_modules/@mongosh" ,
8484 " MongoDB Compass Dev-linux-x64/resources/app.asar.unpacked/node_modules/@mongosh/node-runtime-worker-thread" ,
Original file line number Diff line number Diff line change 7272 " resources\\ app.asar" ,
7373 " resources\\ app.asar.unpacked" ,
7474 " resources\\ app.asar.unpacked\\ build" ,
75- " resources\\ app.asar.unpacked\\ build\\ 3e0a6b397ac0a712067ac5a63a043913 .node" ,
76- " resources\\ app.asar.unpacked\\ build\\ 56bf5c88a1dda8379713beba45d2c6ee .node" ,
75+ " resources\\ app.asar.unpacked\\ build\\ replaced-1 .node" ,
76+ " resources\\ app.asar.unpacked\\ build\\ replaced-2 .node" ,
7777 " resources\\ app.asar.unpacked\\ build\\ assets" ,
7878 " resources\\ app.asar.unpacked\\ build\\ assets\\ mongo_crypt_v1.9a36fabb6daeb1938ef0.dll" ,
7979 " resources\\ app.asar.unpacked\\ node_modules" ,
Original file line number Diff line number Diff line change @@ -66,11 +66,24 @@ function run() {
6666 const destinationPath = fs . mkdtempSync ( 'compass-package-' ) ;
6767 const fixturePath = path . resolve ( __dirname , 'fixtures' ) ;
6868
69+ let nextNumber = 1 ;
70+
71+ const nextName = ( extension : string ) => {
72+ return `replaced-${ nextNumber ++ } .${ extension } ` ;
73+ } ;
74+
6975 try {
7076 const kind = extractArchive ( artifactsDir , destinationPath ) ;
7177
72- const paths = globSync ( '**/*' , { cwd : destinationPath } ) ;
73- paths . sort ( ) ;
78+ const paths = globSync ( '**/*' , { cwd : destinationPath } )
79+ . sort ( )
80+ . map ( ( p ) : string => {
81+ return p . replace (
82+ / \b ( [ 0 - 9 a - f ] ) + \. ( n o d e ) $ / ,
83+ ( match : string , name : string , ext : string ) => nextName ( ext )
84+ ) ;
85+ } ) ;
86+
7487 const expectedPaths = JSON . parse (
7588 fs . readFileSync ( path . join ( fixturePath , `${ kind } -paths.json` ) , 'utf8' )
7689 ) ;
You can’t perform that action at this time.
0 commit comments