You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+15-9
Original file line number
Diff line number
Diff line change
@@ -5,7 +5,8 @@
5
5
6
6
ioBroker dev-server is a simple command line tool running on Windows, Linux and macOS that allows you to quickly develop and test ioBroker adapters and their admin interface.
7
7
8
-
**Note:** dev-server requires at least Node.js 14.
8
+
> [!NOTE]
9
+
> dev-server requires at least Node.js 14.
9
10
10
11
## Installation
11
12
@@ -16,8 +17,8 @@ dev-server watch
16
17
```
17
18
(a local installation as dev-dependency is also possible)
18
19
19
-
**Note for Windows users:**
20
-
If dev-server command is not found, check that the npm directory (typically `C:\Users\%username%\AppData\Roaming\npm`) is included in the `PATH` variable.
20
+
> [!TIP]
21
+
> If the `dev-server` command is not found**under Windows**, check that the npm directory (typically `C:\Users\%username%\AppData\Roaming\npm`) is included in the `PATH` variable.
21
22
22
23
## Features
23
24
@@ -45,27 +46,30 @@ You need to install the `dev-server` package as well as set it up it in the adap
45
46
*Before installing, please check the following what is the best way or recommended:*
46
47
47
48
48
-
1. Linux
49
+
####Linux
49
50
* install it as a dev-dependency of your adapter (recommended)
50
51
* install this tool as a global tool
51
52
52
53
Under Linux, it is sometimes useful to install this tool as global, BUT best practice for developing an own adapter it is better to install it as dev-dependency
53
54
54
-
2. MacOS
55
+
####MacOS
55
56
* Under macOS, be careful with installation as global. This is not recommended so better to install it as a dev-dependency
56
57
57
-
3. Windows
58
+
####Windows
58
59
59
60
* Under Windows, a global installation is no problem.
60
61
61
-
**Note:** dev-server requires at least Node.js 14.
62
+
> [!NOTE]
63
+
> dev-server requires at least Node.js 14.
62
64
63
65
How to install it globally:
64
66
65
67
```bash
66
68
npm install --global @iobroker/dev-server
67
69
```
68
70
71
+
#### Installation as a development dependency
72
+
69
73
Some more explanation, especially when a **global installation** is problematic **because of permission** issues (e.g., on **macOS**), you can add the dev-server to your adapter's `devDependencies` and add it e.g., as a script to your package.json.
70
74
71
75
```json
@@ -91,7 +95,8 @@ dev-server setup
91
95
92
96
For additional command line arguments, see below.
93
97
94
-
_Note:_ the executable can either be called with the short name `dev-server` or its full name `iobroker-dev-server`. We will use the first way in this document.
98
+
> [!NOTE]
99
+
> The executable can either be called with the short name `dev-server` or its full name `iobroker-dev-server`. We will use the first way in this document.
95
100
96
101
### Exclude temporary folder
97
102
@@ -159,7 +164,8 @@ Run dev-server and start the adapter in "watch" mode.
159
164
160
165
The adapter will automatically restart when its source code changes (with a 2-seconds delay).
161
166
162
-
**DO NOT** start the adapter manually in `ioBroker.admin`! If you see errors like `ADAPTER_ALREADY_RUNNING` then most likely you ignored this info :-)
167
+
> [!IMPORTANT]
168
+
> **DO NOT** start the adapter manually in `ioBroker.admin`! If you see errors like `ADAPTER_ALREADY_RUNNING` then most likely you ignored this info :-)
163
169
164
170
You may attach a debugger to the running adapter. Keep in mind that the debugger will be detached when you change your source code, you need to manually attach again to the new process. Watch the console output for the correct process id to attach to.
0 commit comments