Skip to content

Commit

Permalink
Merge pull request #55 from makermadecnc/zkc-app-store
Browse files Browse the repository at this point in the history
[WIP] Fix AppStore Builds
  • Loading branch information
zaneclaes committed Dec 17, 2020
2 parents 0c66503 + 7881ccf commit 6d621f7
Show file tree
Hide file tree
Showing 21 changed files with 282 additions and 177 deletions.
178 changes: 89 additions & 89 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,101 +7,100 @@ branches:
# Job queue; see below for default job settings.
jobs:
# [Job] [Docker] multi-ach: https://www.docker.com/blog/multi-arch-build-what-about-travis/
- name: "Docker"
language: node_js
dist: bionic
sudo: required
os: linux
arch: amd64
# services:
# - docker
before_install:
- npm install -g npm
# Install Docker 19.x, not 18
- curl -fsSL https://get.docker.com | sh
- echo '{"experimental":"enabled"}' | sudo tee /etc/docker/daemon.json
- mkdir -p $HOME/.docker
- echo '{"experimental":"enabled"}' | sudo tee $HOME/.docker/config.json
- sudo service docker start
- docker --version
# Install docker-buildx plugin for cross-architecture compilation.
- mkdir -p ~/.docker/cli-plugins/
- curl -fsSL -o ~/.docker/cli-plugins/docker-buildx https://github.com/docker/buildx/releases/download/v0.4.1/buildx-v0.4.1.linux-amd64
- chmod a+x ~/.docker/cli-plugins/docker-buildx
- docker context ls
install:
# With a multi-arch build, installing on the host machine first is faster.
- npm install
# Create a multi-arch buildx user: https://github.com/docker/buildx/issues/138
- docker run --rm --privileged multiarch/qemu-user-static --reset -p yes
- docker buildx create --platform linux/arm64,linux/arm/v7 --name xbuilder --use
- docker buildx inspect --bootstrap
script:
- echo "Building $CI_SEMVER"
# Pre-build assets; this prevents the multi-arch from running each build in the Dockerfile.
- npm run build-latest
# Only the master branch supports a "deploy" step. For others, go ahead and push a dev image.
- scripts/docker.sh build
after_success: [] # Override.
addons:
apt:
packages:
- qemu-user-static # multi-arch build tools
- icnsutils
- graphicsmagick
- gcc-multilib
- g++-multilib
- rpm
deploy:
skip_cleanup: true # Leave build artifacts in place (don't git clean)
provider: script
script: scripts/docker.sh deploy
# [Job] Raspberry Pi Image built with Docker
- name: "Raspberry Pi OS Lite"
language: shell
sudo: required
os: linux
dist: bionic
install: []
services:
- docker
script:
- scripts/pack-rpi.sh lite
# [Job] Raspberry Pi Image built with Docker
- name: "Raspberry Pi OS Desktop"
language: shell
sudo: required
os: linux
dist: bionic
install: []
services:
- docker
script:
- scripts/pack-rpi.sh desktop
# [Job] Linux (Electron App)
- name: "Linux"
os: linux
script:
- npm run build-latest
- npm run build:linux-ia32
- npm run build:linux-x64
# - name: "Docker"
# language: node_js
# dist: bionic
# sudo: required
# os: linux
# arch: amd64
# # services:
# # - docker
# before_install:
# - npm install -g npm
# # Install Docker 19.x, not 18
# - curl -fsSL https://get.docker.com | sh
# - echo '{"experimental":"enabled"}' | sudo tee /etc/docker/daemon.json
# - mkdir -p $HOME/.docker
# - echo '{"experimental":"enabled"}' | sudo tee $HOME/.docker/config.json
# - sudo service docker start
# - docker --version
# # Install docker-buildx plugin for cross-architecture compilation.
# - mkdir -p ~/.docker/cli-plugins/
# - curl -fsSL -o ~/.docker/cli-plugins/docker-buildx https://github.com/docker/buildx/releases/download/v0.4.1/buildx-v0.4.1.linux-amd64
# - chmod a+x ~/.docker/cli-plugins/docker-buildx
# - docker context ls
# install:
# # With a multi-arch build, installing on the host machine first is faster.
# - npm install
# # Create a multi-arch buildx user: https://github.com/docker/buildx/issues/138
# - docker run --rm --privileged multiarch/qemu-user-static --reset -p yes
# - docker buildx create --platform linux/arm64,linux/arm/v7 --name xbuilder --use
# - docker buildx inspect --bootstrap
# script:
# - echo "Building $CI_SEMVER"
# # Pre-build assets; this prevents the multi-arch from running each build in the Dockerfile.
# - npm run build-latest
# # Only the master branch supports a "deploy" step. For others, go ahead and push a dev image.
# - scripts/docker.sh build
# after_success: [] # Override.
# addons:
# apt:
# packages:
# - qemu-user-static # multi-arch build tools
# - icnsutils
# - graphicsmagick
# - gcc-multilib
# - g++-multilib
# - rpm
# deploy:
# skip_cleanup: true # Leave build artifacts in place (don't git clean)
# provider: script
# script: scripts/docker.sh deploy
# # [Job] Raspberry Pi Image built with Docker
# - name: "Raspberry Pi OS Lite"
# language: shell
# sudo: required
# os: linux
# dist: bionic
# install: []
# services:
# - docker
# script:
# - scripts/pack-rpi.sh lite
# # [Job] Raspberry Pi Image built with Docker
# - name: "Raspberry Pi OS Desktop"
# language: shell
# sudo: required
# os: linux
# dist: bionic
# install: []
# services:
# - docker
# script:
# - scripts/pack-rpi.sh desktop
# # [Job] Linux (Electron App)
# - name: "Linux"
# os: linux
# script:
# - npm run build-latest
# - npm run build:linux-ia32
# - npm run build:linux-x64
# [Job] MacOS (Electron App)
- name: "MacOS"
os: osx
osx_image: xcode8.3
# before_install:
# - brew update
# before_deploy:
# - scripts/add-osx-cert.sh
osx_image: xcode12.2
before_install:
- scripts/add-osx-cert.sh
script:
- npm run build-latest
- npm run build:mac-x64
- travis_wait 50 npm run build:mac-x64

# [Job] Windows (Electron App)
- name: "Windows"
os: windows
script:
- npm run build-latest
- npm run build:win-x64
# - name: "Windows"
# os: windows
# script:
# - npm run build-latest
# - npm run build:win-x64

# --------------------------------------------------------------------------------------------------
# Default job settings, when not overwritten by specific jobs.
Expand All @@ -127,6 +126,7 @@ env:
- RELEASE_NAME="${PRODUCT_NAME} v${CI_VERSION}"
- RELEASE_FILE="makerverse-${CI_SEMVER}"
- LAST_COMMIT_DATE=`git log -1 --pretty=%cD`
- PUBLISH_FOR_PULL_REQUEST=true

cache:
directories:
Expand Down
Binary file removed electron-build/makermade.cer
Binary file not shown.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "makerverse",
"version": "1.1.0-dev",
"version": "1.1.2-dev",
"description": "A web-based interface for CNC milling controller.",
"homepage": "https://github.com/makermadecnc/makerverse",
"author": "Maker Made <info@makermade.com>",
Expand Down
16 changes: 8 additions & 8 deletions scripts/electron-builder.sh
Original file line number Diff line number Diff line change
Expand Up @@ -35,14 +35,14 @@ if [ ! -z "$CI_VERSION" ]; then
echo "Cleaning up \"`pwd`/node_modules\""
rm -rf node_modules

if [ "$1" = "--mac" ]; then
# https://github.com/electron-userland/electron-builder/issues/398
security import "scripts/certs/Certum-Code-Signing-CA-SHA2.cer" -k ~/Library/Keychains/login.keychain -T /usr/bin/codesign;
# https://github.com/electron-userland/electron-osx-sign/issues/83
# Temporarily Bypass Gatekeeper
sudo spctl --master-disable;
sudo spctl --status;
fi
# if [ "$1" = "--mac" ]; then
# # https://github.com/electron-userland/electron-builder/issues/398
# security import "scripts/certs/Certum-Code-Signing-CA-SHA2.cer" -k ~/Library/Keychains/login.keychain -T /usr/bin/codesign;
# # https://github.com/electron-userland/electron-osx-sign/issues/83
# # Temporarily Bypass Gatekeeper
# sudo spctl --master-disable;
# sudo spctl --status;
# fi
fi
echo "Installing packages..."
npm install --production
Expand Down
18 changes: 13 additions & 5 deletions src/app/i18n/cs/resource.json
Original file line number Diff line number Diff line change
Expand Up @@ -570,11 +570,7 @@
"Contribute": "",
"Unable to detect firmware version.": "",
"Icon": "",
"Could not download machine profiles.": "",
"You will need to use \"manual connection mode,\" below.": "",
"{{ axis }}-Axis": "",
"Accuracy is unusual": "",
"Precision is unusual.": "",
"Axes have been set by your machine profile.": "",
"Choose an icon": "",
"Prefer inches?": "",
Expand All @@ -600,5 +596,17 @@
"Is this a new machine?": "",
"Or, have you installed new firmware?": "",
"Selecting \"yes\" will reset (erase) and apply reccomended settings.": "",
"Welcome": ""
"Welcome": "",
"Could not download from the community catalog.": "",
"You will need to create a new machine, below.": "",
"Not sure what settings to use?": "",
"Can't find your machine?": "",
"Search the Community Catalog": "",
"Create a New Machine": "",
"Connect to a New Machine": "",
"Accuracy is unusual (defines minimum travel distance on axis).": "",
"Precision is unusual (defines number of digits for rounding).": "",
"Remember me (I consent to cookies)": "",
"I understand \"guest mode\" is hazardous. ": "",
"Continue as Guest": ""
}
18 changes: 13 additions & 5 deletions src/app/i18n/de/resource.json
Original file line number Diff line number Diff line change
Expand Up @@ -570,11 +570,7 @@
"Contribute": "",
"Unable to detect firmware version.": "",
"Icon": "",
"Could not download machine profiles.": "",
"You will need to use \"manual connection mode,\" below.": "",
"{{ axis }}-Axis": "",
"Accuracy is unusual": "",
"Precision is unusual.": "",
"Axes have been set by your machine profile.": "",
"Choose an icon": "",
"Prefer inches?": "",
Expand All @@ -600,5 +596,17 @@
"Is this a new machine?": "",
"Or, have you installed new firmware?": "",
"Selecting \"yes\" will reset (erase) and apply reccomended settings.": "",
"Welcome": ""
"Welcome": "",
"Could not download from the community catalog.": "",
"You will need to create a new machine, below.": "",
"Not sure what settings to use?": "",
"Can't find your machine?": "",
"Search the Community Catalog": "",
"Create a New Machine": "",
"Connect to a New Machine": "",
"Accuracy is unusual (defines minimum travel distance on axis).": "",
"Precision is unusual (defines number of digits for rounding).": "",
"Remember me (I consent to cookies)": "",
"I understand \"guest mode\" is hazardous. ": "",
"Continue as Guest": ""
}
18 changes: 13 additions & 5 deletions src/app/i18n/en/resource.json
Original file line number Diff line number Diff line change
Expand Up @@ -570,11 +570,7 @@
"Contribute": "Contribute",
"Unable to detect firmware version.": "Unable to detect firmware version.",
"Icon": "Icon",
"Could not download machine profiles.": "Could not download machine profiles.",
"You will need to use \"manual connection mode,\" below.": "You will need to use \"manual connection mode,\" below.",
"{{ axis }}-Axis": "{{ axis }}-Axis",
"Accuracy is unusual": "Accuracy is unusual",
"Precision is unusual.": "Precision is unusual.",
"Axes have been set by your machine profile.": "Axes have been set by your machine profile.",
"Choose an icon": "Choose an icon",
"Prefer inches?": "Prefer inches?",
Expand All @@ -600,5 +596,17 @@
"Is this a new machine?": "Is this a new machine?",
"Or, have you installed new firmware?": "Or, have you installed new firmware?",
"Selecting \"yes\" will reset (erase) and apply reccomended settings.": "Selecting \"yes\" will reset (erase) and apply reccomended settings.",
"Welcome": "Welcome"
"Welcome": "Welcome",
"Could not download from the community catalog.": "Could not download from the community catalog.",
"You will need to create a new machine, below.": "You will need to create a new machine, below.",
"Not sure what settings to use?": "Not sure what settings to use?",
"Can't find your machine?": "Can't find your machine?",
"Search the Community Catalog": "Search the Community Catalog",
"Create a New Machine": "Create a New Machine",
"Connect to a New Machine": "Connect to a New Machine",
"Accuracy is unusual (defines minimum travel distance on axis).": "Accuracy is unusual (defines minimum travel distance on axis).",
"Precision is unusual (defines number of digits for rounding).": "Precision is unusual (defines number of digits for rounding).",
"Remember me (I consent to cookies)": "Remember me (I consent to cookies)",
"I understand \"guest mode\" is hazardous. ": "I understand \"guest mode\" is hazardous. ",
"Continue as Guest": "Continue as Guest"
}
18 changes: 13 additions & 5 deletions src/app/i18n/es/resource.json
Original file line number Diff line number Diff line change
Expand Up @@ -570,11 +570,7 @@
"Contribute": "",
"Unable to detect firmware version.": "",
"Icon": "",
"Could not download machine profiles.": "",
"You will need to use \"manual connection mode,\" below.": "",
"{{ axis }}-Axis": "",
"Accuracy is unusual": "",
"Precision is unusual.": "",
"Axes have been set by your machine profile.": "",
"Choose an icon": "",
"Prefer inches?": "",
Expand All @@ -600,5 +596,17 @@
"Is this a new machine?": "",
"Or, have you installed new firmware?": "",
"Selecting \"yes\" will reset (erase) and apply reccomended settings.": "",
"Welcome": ""
"Welcome": "",
"Could not download from the community catalog.": "",
"You will need to create a new machine, below.": "",
"Not sure what settings to use?": "",
"Can't find your machine?": "",
"Search the Community Catalog": "",
"Create a New Machine": "",
"Connect to a New Machine": "",
"Accuracy is unusual (defines minimum travel distance on axis).": "",
"Precision is unusual (defines number of digits for rounding).": "",
"Remember me (I consent to cookies)": "",
"I understand \"guest mode\" is hazardous. ": "",
"Continue as Guest": ""
}
18 changes: 13 additions & 5 deletions src/app/i18n/fr/resource.json
Original file line number Diff line number Diff line change
Expand Up @@ -570,11 +570,7 @@
"Contribute": "",
"Unable to detect firmware version.": "",
"Icon": "",
"Could not download machine profiles.": "",
"You will need to use \"manual connection mode,\" below.": "",
"{{ axis }}-Axis": "",
"Accuracy is unusual": "",
"Precision is unusual.": "",
"Axes have been set by your machine profile.": "",
"Choose an icon": "",
"Prefer inches?": "",
Expand All @@ -600,5 +596,17 @@
"Is this a new machine?": "",
"Or, have you installed new firmware?": "",
"Selecting \"yes\" will reset (erase) and apply reccomended settings.": "",
"Welcome": ""
"Welcome": "",
"Could not download from the community catalog.": "",
"You will need to create a new machine, below.": "",
"Not sure what settings to use?": "",
"Can't find your machine?": "",
"Search the Community Catalog": "",
"Create a New Machine": "",
"Connect to a New Machine": "",
"Accuracy is unusual (defines minimum travel distance on axis).": "",
"Precision is unusual (defines number of digits for rounding).": "",
"Remember me (I consent to cookies)": "",
"I understand \"guest mode\" is hazardous. ": "",
"Continue as Guest": ""
}
Loading

0 comments on commit 6d621f7

Please sign in to comment.