diff --git a/.circleci/config.yml b/.circleci/config.yml index 090eea0d..71d70906 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -324,6 +324,10 @@ jobs: os: mac path: ./dist/macos-release subpath: ./macos-release/ + - build: + os: mac-universal + path: ./dist/macos-release + subpath: ./macos-release/ - run: name: Get rename without brew as it might fail command: curl -L https://github.com/ap/rename/archive/v1.601.tar.gz --output rename.tgz @@ -557,7 +561,6 @@ workflows: branches: only: - /^release-\d+(\.\d+){1,2}(-rc.*)?/ - - pull/1680 - store_artifacts: # for master/PR builds diff --git a/package.json b/package.json index e5364e9d..70c4519d 100644 --- a/package.json +++ b/package.json @@ -44,9 +44,10 @@ "test:unit": "npm-run-all test:unit:build test:unit:run", "test:unit:build": "cross-env NODE_ENV=test webpack-cli --bail --config webpack.config.test.js", "test:unit:run": "cross-env NODE_ENV=test mocha --reporter mocha-circleci-reporter dist/tests/test_bundle.js", - "package:all": "cross-env NODE_ENV=production npm-run-all check-build-config package:windows package:mac package:linux", + "package:all": "cross-env NODE_ENV=production npm-run-all check-build-config package:windows package:mac package:mac-universal package:linux", "package:windows": "cross-env NODE_ENV=production npm-run-all check-build-config build-prod && electron-builder --win --x64 --ia32 --publish=never", "package:mac": "cross-env NODE_ENV=production npm-run-all check-build-config build-prod && electron-builder --mac --x64 --arm64 --publish=never", + "package:mac-universal": "cross-env NODE_ENV=production npm-run-all check-build-config build-prod && electron-builder --mac --universal --publish=never", "package:linux": "cross-env NODE_ENV=production npm-run-all check-build-config build-prod && electron-builder --linux --x64 --ia32 --publish=never", "lint:js": "eslint --ignore-path .gitignore --ignore-pattern node_modules --ext .js --ext .jsx --ext .ts --ext .tsx .", "lint:js-quiet": "eslint --ignore-path .gitignore --ignore-pattern node_modules --ext .js --ext .jsx --ext .ts --ext .tsx . --quiet", diff --git a/scripts/cp_artifacts.sh b/scripts/cp_artifacts.sh index 53c62479..661405fc 100644 --- a/scripts/cp_artifacts.sh +++ b/scripts/cp_artifacts.sh @@ -52,10 +52,19 @@ if [[ -f "${SRC}/mattermost-desktop-${VERSION}-mac-arm64.zip" ]]; then fi SOMETHING_COPIED=$((SOMETHING_COPIED + 16)) fi +if [[ -f "${SRC}/mattermost-desktop-${VERSION}-mac-universal.zip" ]]; then + echo -e "Copying mac-universal\n" + cp "${SRC}/mattermost-desktop-${VERSION}-mac-universal.zip" "${DEST}/mattermost-desktop-${VERSION}-mac-universal.zip" + if [[ -f "${SRC}"/mattermost-desktop-${VERSION}-mac-universal.dmg ]]; then + cp "${SRC}/mattermost-desktop-${VERSION}-mac-universal.dmg.blockmap" "${DEST}/mattermost-desktop-${VERSION}-mac-universal.dmg.blockmap" + cp "${SRC}/mattermost-desktop-${VERSION}-mac-universal.dmg" "${DEST}/mattermost-desktop-${VERSION}-mac-universal.dmg" + fi + SOMETHING_COPIED=$((SOMETHING_COPIED + 32)) +fi if [[ -f "${SRC}"/mattermost-desktop-${VERSION}-linux-x64.tar.gz ]]; then echo -e "Copying linux\n" cp "${SRC}"/mattermost-desktop-*-linux-* "${DEST}/" - SOMETHING_COPIED=$((SOMETHING_COPIED + 32)) + SOMETHING_COPIED=$((SOMETHING_COPIED + 64)) fi if [[ $SOMETHING_COPIED -eq 0 ]]; then