@@ -53,7 +53,7 @@ can be downloaded by specifying the path to their ``package.json``.
53
53
If no json file is specified, then "package.json" is implicitly added::
54
54
55
55
>>> mip.install("http://example.com/x/")
56
- >>> mip.install("github:org/repo")
56
+ >>> mip.install("github:org/repo") # Uses default branch of that repo
57
57
>>> mip.install("github:org/repo", version="branch-or-tag")
58
58
59
59
@@ -108,9 +108,9 @@ https://github.com/micropython/micropython-lib for more information.
108
108
109
109
To write a "self-hosted" package that can be downloaded by ``mip `` or
110
110
``mpremote ``, you need a static webserver (or GitHub) to host either a
111
- single .py file, or a package.json file alongside your .py files.
111
+ single .py file, or a `` package.json `` file alongside your .py files.
112
112
113
- A typical package.json for an example ``mlx90640 `` library looks like::
113
+ A typical `` package.json `` for an example ``mlx90640 `` library looks like::
114
114
115
115
{
116
116
"urls": [
@@ -119,15 +119,18 @@ A typical package.json for an example ``mlx90640`` library looks like::
119
119
],
120
120
"deps": [
121
121
["collections-defaultdict", "latest"],
122
- ["os-path", "latest"]
122
+ ["os-path", "latest"],
123
+ ["github:org/micropython-additions", "main"]
123
124
],
124
125
"version": "0.2"
125
126
}
126
127
127
128
This includes two files, hosted at a GitHub repo named
128
129
``org/micropython-mlx90640 ``, which install into the ``mlx90640 `` directory on
129
130
the device. It depends on ``collections-defaultdict `` and ``os-path `` which will
130
- be installed automatically.
131
+ be installed automatically from the :term: `micropython-lib `. The third
132
+ dependency installs the content as defined by the ``package.json `` file of the
133
+ ``main `` branch of the GitHub repo ``org/micropython-additions ``.
131
134
132
135
Freezing packages
133
136
-----------------
0 commit comments