Skip to content

Commit 467a981

Browse files
committed
feat: Add 'IS_MAC' util
1 parent 9f1915a commit 467a981

File tree

3 files changed

+5
-2
lines changed

3 files changed

+5
-2
lines changed

dist/setup/index.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -65430,6 +65430,7 @@ const semver = __importStar(__nccwpck_require__(1383));
6543065430
const exec = __importStar(__nccwpck_require__(1514));
6543165431
exports.IS_WINDOWS = process.platform === 'win32';
6543265432
exports.IS_LINUX = process.platform === 'linux';
65433+
exports.IS_MAC = process.platform === 'darwin';
6543365434
exports.WINDOWS_ARCHS = ['x86', 'x64'];
6543465435
exports.WINDOWS_PLATFORMS = ['win32', 'win64'];
6543565436
const PYPY_VERSION_FILE = 'PYPY_VERSION';
@@ -65761,4 +65762,4 @@ module.exports = JSON.parse('["ac","com.ac","edu.ac","gov.ac","net.ac","mil.ac",
6576165762
/******/ module.exports = __webpack_exports__;
6576265763
/******/
6576365764
/******/ })()
65764-
;
65765+
;

src/setup-python.ts

+2-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,8 @@ import fs from 'fs';
77
import {getCacheDistributor} from './cache-distributions/cache-factory';
88
import {
99
isCacheFeatureAvailable,
10-
logWarning
10+
logWarning,
11+
IS_MAC
1112
} from './utils';
1213

1314
function isPyPyVersion(versionSpec: string) {

src/utils.ts

+1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ import * as exec from '@actions/exec';
77

88
export const IS_WINDOWS = process.platform === 'win32';
99
export const IS_LINUX = process.platform === 'linux';
10+
export const IS_MAC = process.platform === 'darwin';
1011
export const WINDOWS_ARCHS = ['x86', 'x64'];
1112
export const WINDOWS_PLATFORMS = ['win32', 'win64'];
1213
const PYPY_VERSION_FILE = 'PYPY_VERSION';

0 commit comments

Comments
 (0)