Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
de759ab
upgrade node and electron version.
Andrii727 Dec 4, 2024
cb01e86
fix build logic
Andrii727 Dec 9, 2024
9f83683
build on linux
Andrii727 Dec 13, 2024
5859830
Update package.json
Andrii727 Dec 13, 2024
ebaccad
Update package.json
Andrii727 Dec 14, 2024
bef10ef
Merge branch 'upgrade-vite' of https://github.com/ituob/itu-ob-editor…
Andrii727 Dec 15, 2024
e51b043
fix nvm
Andrii727 Dec 15, 2024
5abf2f4
chore(ops): enable GHA on PR
Andrii727 Dec 14, 2024
92e3621
chore(ops): enable ubuntu-latest on GHA
strogonoff Dec 15, 2024
815287a
chore(ops): bump Node version
strogonoff Dec 16, 2024
6916cc2
chore(ops): pin Node version
strogonoff Dec 16, 2024
bfb3258
chore(ops): pin Node version
strogonoff Dec 16, 2024
5a8aad1
chore(ops): make it upload artifacts
strogonoff Dec 16, 2024
ee22804
chore(ops): fix upload artifacts step
strogonoff Dec 16, 2024
903f0d0
chore(ops): upload artifacts separately
strogonoff Dec 16, 2024
7b75bd8
fix(ops): conditional artifact uploads
strogonoff Dec 16, 2024
d0db796
chore(deps): switch to dev coulomb
strogonoff Dec 17, 2024
8aa0cff
fix style
Andrii727 Dec 23, 2024
1b6ac03
Merge branch 'upgrade-vite' of github.com:ituob/itu-ob-editor into up…
Andrii727 Dec 23, 2024
c2fea5e
chore(ops): add workflow_dispatch for release
strogonoff Apr 10, 2025
a6ea6be
chore(ops): bump upload-artifact action version
strogonoff Apr 11, 2025
31b1886
ci: Update actions versions
ribose-jeffreylau Dec 18, 2024
e05cc90
ci: Try to fix build for mac
ribose-jeffreylau Apr 11, 2025
bd6cf53
fix: Bring back icons
ribose-jeffreylau Apr 11, 2025
65bf35d
fix: Try to bring back notarization
ribose-jeffreylau Apr 11, 2025
7a55672
Revert "fix: Try to bring back notarization"
ribose-jeffreylau Apr 11, 2025
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
6 changes: 3 additions & 3 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@ jobs:

steps:
- name: Check out Git repository
uses: actions/checkout@v2
uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v1
uses: actions/setup-node@v4
with:
node-version: 14
node-version: 18.19.0

- name: Install dependencies
if: steps.yarn-cache.outputs.cache-hit != 'true'
Expand Down
43 changes: 38 additions & 5 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
name: Build/release

on:
pull_request:
workflow_dispatch:
push:
tags:
- v*
Expand All @@ -13,17 +15,16 @@ jobs:
# Platforms to build on/for
strategy:
matrix:
# ubuntu-latest,
os: [macos-latest, windows-latest]
os: [ubuntu-latest, macos-latest, windows-latest]

steps:
- name: Check out Git repository
uses: actions/checkout@v2
uses: actions/checkout@v4

- name: Install Node.js, NPM and Yarn
uses: actions/setup-node@v1
uses: actions/setup-node@v4
with:
node-version: 12
node-version: 18.19.0

# - name: Install Snapcraft
# uses: samuelmeuli/action-snapcraft@v1
Expand Down Expand Up @@ -61,3 +62,35 @@ jobs:
# macOS notarization API key
API_KEY_ID: ${{ secrets.APPLE_API_KEY_ID }}
API_KEY_ISSUER_ID: ${{ secrets.APPLE_API_KEY_ISSUER_ID }}

- name: Upload DMG
uses: actions/upload-artifact@v4
if: startsWith(matrix.os, 'macos')
with:
name: DMG
path: dist/*.dmg
if-no-files-found: error

- name: Upload AppImage
uses: actions/upload-artifact@v4
if: startsWith(matrix.os, 'ubuntu')
with:
name: AppImage
path: dist/*.AppImage
if-no-files-found: error

- name: Upload .deb
uses: actions/upload-artifact@v4
if: startsWith(matrix.os, 'ubuntu')
with:
name: DEB
path: dist/*.deb
if-no-files-found: error

- name: Upload .exe
uses: actions/upload-artifact@v4
if: startsWith(matrix.os, 'windows')
with:
name: EXE
path: dist/*.exe
if-no-files-found: error
6 changes: 3 additions & 3 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,12 @@ jobs:

steps:
- name: Check out Git repository
uses: actions/checkout@v2
uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v1
uses: actions/setup-node@v4
with:
node-version: 12
node-version: 18.19.0

- name: Install dependencies
if: steps.yarn-cache.outputs.cache-hit != 'true'
Expand Down
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
11.14.0
18.19.0
10 changes: 0 additions & 10 deletions build/entitlements.mas.inherit.plist

This file was deleted.

10 changes: 0 additions & 10 deletions build/entitlements.mas.plist

This file was deleted.

24 changes: 13 additions & 11 deletions main.webpack.js
Original file line number Diff line number Diff line change
@@ -1,28 +1,30 @@
const path = require('path');
const ThreadsPlugin = require('threads-plugin');
const path = require("path");
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

'const' is available in ES6 (use 'esversion: 6') or Mozilla JS extensions (use moz).

const ThreadsPlugin = require("threads-plugin");
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

'const' is available in ES6 (use 'esversion: 6') or Mozilla JS extensions (use moz).


module.exports = function (config) {
config.resolve.modules = [path.resolve(__dirname, './src'), 'node_modules'];
config.resolve.modules = [path.resolve(__dirname, "./src"), "node_modules"];

config.optimization = {
...config.optimization,
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Expected '}' to match '{' from line 7 and instead saw '...'.
Missing semicolon.

moduleIds: "named",
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Expected '}' to match '{' from line 4 and instead saw ':'.
Expected an assignment or function call and instead saw an expression.
Missing semicolon.
Unrecoverable syntax error. (29% scanned).

};
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unexpected '}'.


config.module.rules = config.module.rules.filter(r => {
return (r.use !== 'node-loader');
config.module.rules = config.module.rules.filter((r) => {
return r.use !== "node-loader";
});

config.module.rules.unshift({
test: /\.node$/,
use: {
loader: 'native-ext-loader',
loader: "native-ext-loader",
options: {
rewritePath: undefined,
name: '[path][name].[ext]',
name: "[path][name].[ext]",
},
},
});

config.plugins.unshift(
new ThreadsPlugin({ target: 'electron-node-worker' })
);
config.plugins.unshift(new ThreadsPlugin({ target: "electron-node-worker" }));

return config;
}
};
97 changes: 45 additions & 52 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,20 @@
"repository": "github:ituob/itu-ob-editor",
"homepage": "https://www.ituob.org",
"license": "MIT",
"type": "commonjs",
"engines": {
"node": "18.19.0"
},
"scripts": {
"postinstall": "electron-builder install-app-deps",
"dev": "electron-webpack dev",
"compile": "electron-webpack",
"clean": "rm -rf ./bundle ./dist",
"dist": "cross-env DEBUG=electron-builder electron-builder",
"dist:win": "electron-builder -w",
"dist:win": "electron-builder -w --config.win.target=portable",
"dist:linux": "electron-builder -l",
"dist:mac": "electron-builder -m",
"dist:linux": "electron-builder -l",
"pack": "electron-builder --dir",
"release": "electron-builder --publish always",
"cdist": "yarn compile && electron-builder -mlw",
Expand Down Expand Up @@ -47,35 +53,45 @@
"productName": "ITU OB Editor",
"appId": "org.ituob.editor",
"afterPack": "./scripts/after-pack.js",
"afterSign": "electron-builder-notarize",
"asarUnpack": [
"**/*.node",
"node_modules/source-map/**/*",
"node_modules/source-map-support/**/*",
"node_modules/buffer-from/**/*",
"dist/main/*.worker.js*"
],
"directories": {
"output": "dist",
"buildResources": "build"
},
"mac": {
"target": [
"dmg",
"mas",
"zip"
],
"category": "public.app-category.productivity",
"darkModeSupport": true,
"icon": "build/icon.icns",
"gatekeeperAssess": false,
"hardenedRuntime": true,
"gatekeeperAssess": false,
"entitlements": "./build/entitlements.mac.plist",
"entitlementsInherit": "./build/entitlements.mac.plist"
},
"mas": {
"entitlements": "./build/entitlements.mas.plist",
"entitlementsInherit": "./build/entitlements.mas.inherit.plist",
"hardenedRuntime": false
},
"linux": {
"category": "Utility"
"target": [
"AppImage",
"deb"
],
"category": "Utility",
"icon": "build/icon.png"
},
"win": {
"target": "portable",
"icon": "build/icon.ico",
"artifactName": "itu-ob-editor.exe"
},
"portable": {
"artifactName": "itu-ob-editor.exe"
},
"dmg": {
"contents": [
Expand All @@ -92,33 +108,6 @@
],
"artifactName": "itu-ob-editor-${version}.${ext}"
},
"win": {
"target": [
{
"target": "nsis",
"arch": [
"x64"
]
},
{
"target": "portable"
}
],
"icon": "build/icon.ico"
},
"nsis": {
"runAfterFinish": true,
"installerIcon": "build/icon.ico",
"artifactName": "itu-ob-editor-${version}.${ext}"
},
"portable": {
"artifactName": "itu-ob-editor.exe"
},
"appx": {
"backgroundColor": "#464646",
"publisherDisplayName": "ituob",
"artifactName": "itu-ob-editor-${version}.${ext}"
},
"publish": [
{
"provider": "github",
Expand Down Expand Up @@ -187,7 +176,8 @@
"@blueprintjs/datetime": "^3.18.2",
"@blueprintjs/icons": "^3.18.1",
"@blueprintjs/select": "^3.13.3",
"@riboseinc/coulomb": "^0.9.7",
"@electron/remote": "^2.1.2",
"@riboseinc/coulomb": "dev",
"@types/react-window": "^1.8.2",
"async-lock": "^1.2.2",
"electron-log": "^4.2.2",
Expand All @@ -202,57 +192,60 @@
"react-dom": "^16.11.0",
"react-transition-group": "^4.3.0",
"react-window": "^1.8.5",
"source-map-support": "^0.5.19",
"sass": "1.35.1",
"source-map-support": "^0.5.21",
"throttle-debounce": "^2.1.0"
},
"resolutions": {
"*/**/prosemirror-model": "https://github.com/strogonoff/prosemirror-model.git#prosemirror-model-v1.7.5-gitpkg",
"js-yaml": "3.14.0",
"acorn": "6.4.1",
"minimist": "1.2.5",
"kind-of": "6.0.3"
"kind-of": "6.0.3",
"node-abi": "^3.47.0",
"keytar": "7.9.0",
"*/**/keytar": "7.9.0",
"@types/react": "^16.14.0"
},
"devDependencies": {
"@types/async-lock": "^1.1.1",
"@types/fs-extra": "^8.0.0",
"@types/node": "^12.12.7",
"@types/react": "^16.9.11",
"@types/node": "~18.19.0",
"@types/react": "^16.14.0",
"@types/react-dom": "^16.9.4",
"@types/react-transition-group": "^4.2.3",
"@types/react-transition-group": "^4.4.11",
"@types/throttle-debounce": "^2.1.0",
"@typescript-eslint/eslint-plugin": "^4.0.1",
"@typescript-eslint/parser": "^4.0.1",
"commitizen": "^4.2.1",
"cross-env": "^7.0.0",
"electron": "^9.1.1",
"electron-builder": "^22.7.0",
"electron": "^22.3.27",
"electron-builder": "23.6.0",
"electron-builder-notarize": "^1.1.2",
"electron-react-devtools": "^0.5.3",
"electron-rebuild": "^3.2.9",
"electron-webpack": "^2.8.2",
"electron-webpack-ts": "^4.0.1",
"eslint": "^7.8.1",
"husky": "^4.2.5",
"native-ext-loader": "^2.3.0",
"node-sass": "^4.12.0",
"npm-run-all": "^4.1.5",
"prettifier": "^0.4.0",
"sass-loader": "^8.0.2",
"stylelint": "^13.7.0",
"stylelint-config-standard": "^20.0.0",
"threads-plugin": "^1.3.3",
"typescript": "^3.9.7",
"ts-loader": "~8.4.0",
"typescript": "~5.0.4",
"typescript-plugin-css-modules": "^2.2.0",
"webpack": "~4.44.0"
"webpack": "^4.44.0"
},
"config": {
"commitizen": {
"path": "./node_modules/cz-conventional-changelog"
}
},
"husky": {
"hooks": {
"prepare-commit-msg": "exec < /dev/tty && git cz --hook || true",
"pre-push": "yarn lint:ts && yarn lint:css && yarn compile"
}
"hooks": {}
}
}
34 changes: 25 additions & 9 deletions renderer.webpack.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,27 @@
const path = require('path');
const path = require("path");
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

'const' is available in ES6 (use 'esversion: 6') or Mozilla JS extensions (use moz).


module.exports = {
resolve: {
modules: [path.resolve(__dirname, './src'), 'node_modules']
},
externals: [
'react',
'react-dom',
],
module.exports = function (config) {
// Create a fresh config object
const newConfig = {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

'const' is available in ES6 (use 'esversion: 6') or Mozilla JS extensions (use moz).

...config,
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Expected '}' to match '{' from line 5 and instead saw '...'.
Missing semicolon.

resolve: {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Expected '}' to match '{' from line 3 and instead saw ':'.
Expected an assignment or function call and instead saw an expression.
Missing semicolon.

modules: [path.resolve(__dirname, "./src"), "node_modules"],
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Label 'modules' on [ statement.

extensions: [".ts", ".tsx", ".js", ".jsx"],
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Expected '}' to match '{' from line 7 and instead saw ':'.
Expected an assignment or function call and instead saw an expression.
Missing semicolon.

alias: {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Expected an assignment or function call and instead saw an expression.
Missing semicolon.
Unrecoverable syntax error. (35% scanned).

"@app": path.resolve(__dirname, "./src/app"),
"@renderer": path.resolve(__dirname, "./src/renderer"),
},
},
externals: ["react", "react-dom"],
optimization: {
moduleIds: "named",
chunkIds: "named",
},
};

// Remove any Webpack 4 specific configurations
delete newConfig.optimization.namedModules;
delete newConfig.optimization.namedChunks;

return newConfig;
};
Loading
Loading