1
- import { v4 as uuidv4 } from 'uuid' ;
1
+ import { v4 as uuidv4 } from 'uuid' ;
2
2
import * as tc from '@actions/tool-cache' ;
3
3
import * as hc from '@actions/http-client' ;
4
4
import * as core from '@actions/core' ;
@@ -11,7 +11,7 @@ import * as path from 'path';
11
11
import os from 'os' ;
12
12
import fs from 'fs' ;
13
13
14
- import { NodeInputs , INodeVersion , INodeVersionInfo } from './base-models' ;
14
+ import { NodeInputs , INodeVersion , INodeVersionInfo } from './base-models' ;
15
15
16
16
export default abstract class BaseDistribution {
17
17
protected httpClient : hc . HttpClient ;
@@ -67,7 +67,7 @@ export default abstract class BaseDistribution {
67
67
protected evaluateVersions ( versions : string [ ] ) : string {
68
68
let version = '' ;
69
69
70
- const { range, options} = this . validRange ( this . nodeInfo . versionSpec ) ;
70
+ const { range, options } = this . validRange ( this . nodeInfo . versionSpec ) ;
71
71
72
72
core . debug ( `evaluating ${ versions . length } versions` ) ;
73
73
@@ -157,7 +157,7 @@ export default abstract class BaseDistribution {
157
157
const c = semver . clean ( versionSpec ) || '' ;
158
158
const valid = semver . valid ( c ) ?? versionSpec ;
159
159
160
- return { range : valid , options} ;
160
+ return { range : valid , options } ;
161
161
}
162
162
163
163
protected async acquireWindowsNodeFromFallbackLocation (
@@ -262,6 +262,9 @@ export default abstract class BaseDistribution {
262
262
case 'win32' :
263
263
dataFileName = `win-${ osArch } -exe` ;
264
264
break ;
265
+ case 'aix' :
266
+ dataFileName = `aix-${ osArch } ` ;
267
+ break ;
265
268
default :
266
269
throw new Error ( `Unexpected OS '${ this . osPlat } '` ) ;
267
270
}
@@ -285,9 +288,17 @@ export default abstract class BaseDistribution {
285
288
}
286
289
287
290
protected translateArchToDistUrl ( arch : string ) : string {
291
+ const endianness = os . endianness ( ) . toLowerCase ( )
288
292
switch ( arch ) {
289
293
case 'arm' :
290
294
return 'armv7l' ;
295
+ case 'ppc64' :
296
+ switch ( endianness ) {
297
+ case 'le' :
298
+ return 'ppc64le' ;
299
+ default :
300
+ return 'ppc64' ;
301
+ }
291
302
default :
292
303
return arch ;
293
304
}
0 commit comments