Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 21 additions & 25 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,14 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- uses: pnpm/action-setup@v2
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
with:
version: 8.5.1
version: 9
- name: Setup Node.js
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: 20.10.x
node-version: 22.x
cache: pnpm
- name: Install
run: pnpm install
Expand All @@ -39,7 +39,7 @@ jobs:
outputs:
config: ${{ steps.filter.outputs.config }}
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
if: ${{ github.event_name == 'push' }}
- uses: dorny/paths-filter@v2
id: filter
Expand All @@ -58,29 +58,25 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ macOS-latest, macOS-12, ubuntu-latest, windows-latest ]
arch: [ x64, arm64 ]
# Publishing artifacts for multiple Windows architectures has
# a bug which can cause the wrong architecture to be downloaded
# for an update, so until that is fixed, only build Windows x64
exclude:
- os: windows-latest
arch: arm64
# Only build arm64 builds on M1 and x86 builds on Intel Mac
- os: macOS-latest
arch: x64
- os: macOS-12
arch: arm64
include:
- os: macos-latest
arch: arm64
- os: ubuntu-latest
arch: x64
- os: ubuntu-latest
arch: arm64
- os: windows-latest
arch: x64

steps:
- uses: actions/checkout@v3
- uses: pnpm/action-setup@v2
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
with:
version: 8.5.1
version: 9
- name: Setup Node.js
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: 20.10.x
node-version: 22.x
cache: pnpm
- name: Setup Python
uses: actions/setup-python@v5
Expand All @@ -96,7 +92,7 @@ jobs:
fileName: 'windows-certificate.pfx'
encodedString: ${{ secrets.WINDOWS_CODESIGN_CERTIFICATE }}
- name: Generate MacOS code signing certificate
if: matrix.os == 'macOS-latest' || matrix.os == 'macOS-12'
if: matrix.os == 'macos-latest'
run: ./scripts/add-macos-cert.sh
env:
MACOS_CERT_P12: ${{ secrets.MACOS_CERT_P12 }}
Expand Down
34 changes: 15 additions & 19 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,29 +10,25 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ macOS-latest, macOS-12, ubuntu-latest, windows-latest ]
arch: [ x64, arm64 ]
# Publishing artifacts for multiple Windows architectures has
# a bug which can cause the wrong architecture to be downloaded
# for an update, so until that is fixed, only build Windows x64
exclude:
- os: windows-latest
arch: arm64
# Only build arm64 builds on M1 and x86 builds on Intel Mac
- os: macOS-latest
arch: x64
- os: macOS-12
arch: arm64
include:
- os: macos-latest
arch: arm64
- os: ubuntu-latest
arch: x64
- os: ubuntu-latest
arch: arm64
- os: windows-latest
arch: x64

steps:
- uses: actions/checkout@v3
- uses: pnpm/action-setup@v2
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
with:
version: 8.5.1
version: 9
- name: Setup Node.js
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: 20.10.x
node-version: 22.x
cache: pnpm
- name: Setup Python
uses: actions/setup-python@v5
Expand All @@ -50,7 +46,7 @@ jobs:
fileName: 'windows-certificate.pfx'
encodedString: ${{ secrets.WINDOWS_CODESIGN_CERTIFICATE }}
- name: Generate MacOS code signing certificate
if: matrix.os == 'macOS-latest' || matrix.os == 'macOS-12'
if: matrix.os == 'macos-latest'
run: ./scripts/add-macos-cert.sh
env:
MACOS_CERT_P12: ${{ secrets.MACOS_CERT_P12 }}
Expand Down
4 changes: 1 addition & 3 deletions forge.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -83,9 +83,7 @@ module.exports = {
config: {
name: 'Replit',
icon: './assets/logo.icns',
overwrite: false,
// Set a different path for each architecture to avoid conflicts when uploading
dmgPath: process.arch === 'arm64' ? 'Replit.dmg' : 'Replit-Intel.dmg',
overwrite: true,
additionalDMGOptions: {
'background-color': '#0E1525',
},
Expand Down
55 changes: 31 additions & 24 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"description": "Replit Desktop App",
"productName": "Replit",
"scripts": {
"build": "rimraf dist && esbuild src/main.ts src/preload.ts --target=es2015 --platform=node --format=cjs --packages=external --minify --bundle --outdir=dist",
"build": "rimraf dist && esbuild src/main.ts src/preload.ts --target=es2020 --platform=node --format=cjs --packages=external --minify --bundle --outdir=dist",
"ts:check": "tsc --noEmit",
"ts:watch": "tsc --noEmit -w",
"lint": "eslint -c .eslintrc.js --ext .ts ./src",
Expand All @@ -22,40 +22,47 @@
"main": "./dist/main.js",
"engines": {
"pnpm": ">=8.5.1",
"node": "^20.10.0"
"node": ">=20.10.0"
},
"pnpm": {
"onlyBuiltDependencies": [
"electron",
"electron-winstaller",
"esbuild"
]
},
"prettier": {
"trailingComma": "all",
"singleQuote": true
},
"devDependencies": {
"@electron-forge/cli": "^7.4.0",
"@electron-forge/maker-deb": "^7.4.0",
"@electron-forge/maker-dmg": "^7.4.0",
"@electron-forge/maker-squirrel": "^7.4.0",
"@electron-forge/maker-zip": "^7.4.0",
"@electron-forge/publisher-github": "^7.4.0",
"@types/eslint": "^8.44.2",
"@types/node": "^20.10.0",
"@typescript-eslint/eslint-plugin": "^6.4.1",
"@typescript-eslint/parser": "^4.33.0",
"@electron-forge/cli": "^7.11.0",
"@electron-forge/maker-deb": "^7.11.0",
"@electron-forge/maker-dmg": "^7.11.0",
"@electron-forge/maker-squirrel": "^7.11.0",
"@electron-forge/maker-zip": "^7.11.0",
"@electron-forge/publisher-github": "^7.11.0",
"@types/eslint": "^8.56.10",
"@types/node": "^22.0.0",
"@typescript-eslint/eslint-plugin": "^7.0.0",
"@typescript-eslint/parser": "^7.0.0",
"cpy": "^9.0.1",
"cross-env": "^7.0.3",
"electron": "^30.0.3",
"electron-winstaller": "^5.3.1",
"esbuild": "^0.18.6",
"eslint": "^8.47.0",
"eslint-config-prettier": "^9.0.0",
"eslint-plugin-prettier": "^5.0.0",
"electron": "~35.7.5",
"electron-winstaller": "^5.4.0",
"esbuild": "^0.25.0",
"eslint": "^8.57.0",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-prettier": "^5.5.0",
"npm-run-all": "^4.1.5",
"prettier": "^3.0.2",
"rimraf": "^5.0.1",
"typescript": "^4.9.5"
"prettier": "^3.8.0",
"rimraf": "^6.0.0",
"typescript": "^5.8.0"
},
"dependencies": {
"@sentry/electron": "^4.5.0",
"electron-log": "5.1.4",
"@sentry/electron": "^5.0.0",
"electron-log": "^5.4.0",
"electron-squirrel-startup": "^1.0.0",
"electron-store": "^8.1.0"
"electron-store": "^8.2.0"
}
}
Loading
Loading