Skip to content

Commit

Permalink
Update scripts to work with 1.39 and earlier Theia releases #170
Browse files Browse the repository at this point in the history
* rebuild needs to be run performed before build
  • Loading branch information
jfaltermeier committed Jul 17, 2023
1 parent 0309304 commit 5a8859d
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 10 deletions.
6 changes: 4 additions & 2 deletions templates/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,12 @@ Please install all necessary [prerequisites](https://github.com/eclipse-theia/th

## Running the browser example

yarn build:browser
yarn start:browser

*or:*

yarn rebuild:browser
yarn build:browser
cd browser-app
yarn start

Expand All @@ -21,11 +22,12 @@ Open http://localhost:3000 in the browser.

## Running the Electron example

yarn build:electron
yarn start:electron

*or:*

yarn rebuild:electron
yarn build:electron
cd electron-app
yarn start

Expand Down
5 changes: 3 additions & 2 deletions templates/app-browser-package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,10 @@
"@theia/cli": "<%= params.theiaVersion %>"<% if (params.browserDevDependencies) { %><%- params.browserDevDependencies %><% } %>
},
"scripts": {
"prepare": "theia build --mode development",
"bundle": "yarn rebuild && theia build --mode development",
"rebuild": "theia rebuild:browser",
"start": "theia start",
"watch": "theia build --watch --mode development"
"watch": "yarn rebuild && theia build --watch --mode development"
},
"theia": {
"target": "<%= appMode %>"
Expand Down
5 changes: 3 additions & 2 deletions templates/app-electron-package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,10 @@
"electron": "^23.2.4"
},
"scripts": {
"prepare": "theia build --mode development",
"bundle": "yarn rebuild && theia build --mode development",
"rebuild": "theia rebuild:electron",
"start": "theia start",
"watch": "theia build --watch --mode development"
"watch": "yarn rebuild && theia build --watch --mode development"
},
"theia": {
"target": "<%= appMode %>"
Expand Down
8 changes: 4 additions & 4 deletions templates/root-package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
"node": ">=14.18.0"
},
"scripts": {
"build:browser": "yarn --cwd browser-app bundle",
"build:electron": "yarn --cwd electron-app bundle",
"prepare": "lerna run prepare",
"postinstall": "theia check:theia-version",
"rebuild:browser": "theia rebuild:browser",
"rebuild:electron": "theia rebuild:electron",
"start:browser": "yarn rebuild:browser && yarn --cwd browser-app start",
"start:electron": "yarn rebuild:electron && yarn --cwd electron-app start",
"start:browser": "yarn --cwd browser-app start",
"start:electron": "yarn --cwd electron-app start",
"watch": "lerna run --parallel watch"<% if (params.rootscripts) { %><%- params.rootscripts %><% } %>
},
"devDependencies": {
Expand Down

0 comments on commit 5a8859d

Please sign in to comment.