Skip to content

Commit 5411fe9

Browse files
authored
Merge branch 'develop' into order
2 parents b5baff6 + a5b85c4 commit 5411fe9

File tree

16 files changed

+126
-79
lines changed

16 files changed

+126
-79
lines changed

.github/CONTRIBUTING.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,31 +8,31 @@ We hold our code to standard, and these standards are documented below.
88

99
We use [prettier](https://prettier.io/) for automatic formatting a lot all our files. The configuration is in our `prettier.config.mjs` file.
1010

11-
To run prettier, use `npm run lint:prettier`.
11+
To run prettier, use `node --run lint:prettier`.
1212

1313
### JavaScript: Run ESLint
1414

1515
We use [ESLint](https://eslint.org) to lint our JavaScript files. The configuration is in our `eslint.config.mjs` file.
1616

17-
To run ESLint, use `npm run lint:js`.
17+
To run ESLint, use `node --run lint:js`.
1818

1919
### CSS: Run StyleLint
2020

2121
We use [StyleLint](https://stylelint.io) to lint our CSS. The configuration is in our `.stylelintrc.json` file.
2222

23-
To run StyleLint, use `npm run lint:css`.
23+
To run StyleLint, use `node --run lint:css`.
2424

2525
### Markdown: Run markdownlint
2626

2727
We use [markdownlint-cli2](https://github.com/DavidAnson/markdownlint-cli2) to lint our markdown files. The configuration is in our `.markdownlint.json` file.
2828

29-
To run markdownlint, use `npm run markdownlint:css`.
29+
To run markdownlint, use `node --run markdownlint:css`.
3030

3131
## Testing
3232

3333
We use [Jest](https://jestjs.io) for JavaScript testing.
3434

35-
To run all tests, use `npm run test`.
35+
To run all tests, use `node --run test`.
3636

3737
The specific test commands are defined in `package.json`.
38-
So you can also run the specific tests with other commands, e.g. `npm run test:unit` or `npx jest tests/e2e/env_spec.js`.
38+
So you can also run the specific tests with other commands, e.g. `node --run test:unit` or `npx jest tests/e2e/env_spec.js`.

.github/ISSUE_TEMPLATE/bug_report.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -44,11 +44,11 @@ body:
4444
description: |
4545
Please keep in mind that some problems are specific to certain start options.
4646
options:
47-
- "npm run start"
48-
- "npm run start:wayland"
49-
- "npm run start:windows"
50-
- "npm run start:x11"
51-
- "npm run server"
47+
- "node --run start"
48+
- "node --run start:wayland"
49+
- "node --run start:windows"
50+
- "node --run start:x11"
51+
- "node --run server"
5252
- "node clientonly --address ... --port ..."
5353
validations:
5454
required: true

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ Hello and thank you for wanting to contribute to the MagicMirror² project!
1010
> - What does the pull request accomplish? Use a list if needed.
1111
> - If it includes major visual changes please add screenshots.
1212
>
13-
> 3. Please run `npm run lint:prettier` before submitting so that
13+
> 3. Please run `node --run lint:prettier` before submitting so that
1414
> style issues are fixed.
1515
> 4. Don't forget to add an entry about your changes to
1616
> the CHANGELOG.md file.

.github/workflows/automated-tests.yaml

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -22,17 +22,17 @@ jobs:
2222
- name: "Use Node.js"
2323
uses: actions/setup-node@v4
2424
with:
25-
node-version: 23
25+
node-version: lts/*
2626
cache: "npm"
2727
- name: "Install dependencies"
2828
run: |
29-
npm run install-mm:dev
29+
node --run install-mm:dev
3030
- name: "Run linter tests"
3131
run: |
32-
npm run test:prettier
33-
npm run test:js
34-
npm run test:css
35-
npm run test:markdown
32+
node --run test:prettier
33+
node --run test:js
34+
node --run test:css
35+
node --run test:markdown
3636
test:
3737
runs-on: ubuntu-24.04
3838
timeout-minutes: 30
@@ -54,14 +54,16 @@ jobs:
5454
cache: "npm"
5555
- name: "Install MagicMirror²"
5656
run: |
57-
npm run install-mm:dev
58-
- name: "Run tests"
57+
node --run install-mm:dev
58+
- name: "Prepare environment for tests"
5959
run: |
6060
# Fix chrome-sandbox permissions:
6161
sudo chown root:root ./node_modules/electron/dist/chrome-sandbox
6262
sudo chmod 4755 ./node_modules/electron/dist/chrome-sandbox
6363
# Start labwc
6464
WLR_BACKENDS=headless WLR_LIBINPUT_NO_DEVICES=1 WLR_RENDERER=pixman labwc &
65-
export WAYLAND_DISPLAY=wayland-0
6665
touch css/custom.css
67-
npm run test
66+
- name: "Run tests"
67+
run: |
68+
export WAYLAND_DISPLAY=wayland-0
69+
node --run test

.github/workflows/electron-rebuild.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ jobs:
1818
node-version: ${{ matrix.node-version }}
1919
check-latest: true
2020
- name: Install MagicMirror
21-
run: npm run install-mm
21+
run: node --run install-mm
2222
- name: Install @electron/rebuild
2323
run: npm install @electron/rebuild
2424
- name: Install node-libgpiod deps

.github/workflows/spellcheck.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,11 @@ jobs:
2121
- name: Set up Node.js
2222
uses: actions/setup-node@v4
2323
with:
24-
node-version: "22"
24+
node-version: lts/*
2525
check-latest: true
2626
cache: "npm"
2727
- name: Install dependencies
2828
run: |
29-
npm run install-mm:dev
29+
node --run install-mm:dev
3030
- name: Run Spellcheck
31-
run: npm run test:spelling
31+
run: node --run test:spelling

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,3 +84,7 @@ Temporary Items
8484

8585
# Ignore positions file (#3518)
8686
js/positions.js
87+
88+
# Ignore lock files other than package-lock.json
89+
pnpm-lock.yaml
90+
yarn.lock

CHANGELOG.md

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,16 @@ planned for 2025-07-01
1515

1616
- [config] Allow to change module order for final renderer (or dynamicaly with CSS): Feature `order` in config. (#3762)
1717

18-
### Changed
18+
### Fixed
1919

20-
### Removed
20+
- [clock] Added option 'disableNextEvent' to hide next sun event.
2121

22-
### Updated
22+
### Changed
2323

24-
### Fixed
24+
- [refactor] Simplify module loading process (#3766)
25+
- Use "node --run" instead of "npm run" (#3764)
26+
- [workflow] Run linter und spellcheck with LTS node version (#3767)
27+
- [workflow] Split "Run test" step into two steps for more clarity (#3767)
2528

2629
## [2.31.0] - 2025-04-01
2730

@@ -42,7 +45,7 @@ Thanks to: @Developer-Incoming, @eltociear, @geraki, @khassel, @KristjanESPERANT
4245

4346
### Changed
4447

45-
- [core] starting clientonly now checks for needed env var `WAYLAND_DISPLAY` or `DISPLAY` and starts electron with needed parameters (if both are set wayland is used) (#3677)
48+
- [core] Starting clientonly now checks for needed env var `WAYLAND_DISPLAY` or `DISPLAY` and starts electron with needed parameters (if both are set wayland is used) (#3677)
4649
- [core] Optimize systeminformation calls and output (#3689)
4750
- [core] Add issue templates for feature requests and bug reports (#3695)
4851
- [core] Adapt `start:x11:dev` script

js/defaults.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ const defaults = {
6262
position: "middle_center",
6363
classes: "xsmall",
6464
config: {
65-
text: "If you get this message while your config file is already created,<br>" + "it probably contains an error. To validate your config file run in your MagicMirror² directory<br>" + "<pre>npm run config:check</pre>"
65+
text: "If you get this message while your config file is already created,<br>" + "it probably contains an error. To validate your config file run in your MagicMirror² directory<br>" + "<pre>node --run config:check</pre>"
6666
}
6767
},
6868
{

js/electron.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ function createWindow () {
112112
const port = process.env.MM_PORT || config.port;
113113
mainWindow.loadURL(`${prefix}${address}:${port}`);
114114

115-
// Open the DevTools if run with "npm start dev"
115+
// Open the DevTools if run with "node --run start:dev"
116116
if (process.argv.includes("dev")) {
117117
if (process.env.JEST_WORKER_ID !== undefined) {
118118
// if we are running with jest

0 commit comments

Comments
 (0)