Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add package.json for MIP package manager #94

Merged
merged 2 commits into from
Sep 6, 2023

Conversation

wnienhaus
Copy link
Collaborator

@wnienhaus wnienhaus commented Sep 4, 2023

This PR adds a package.json file to allow installing micropython-esp32-ulp with the mip package manager on modern MicroPythons.

To install with mip, one would run:

import mip
mip.install('github:micropython/micropython-esp32-ulp')

# note: while this PR is not merged, this command can be used for testing instead
mip.install('https://raw.githubusercontent.com/wnienhaus/micropython-esp32-ulp/mip_support/package.json')

This PR also adds a tool for generating the contents of package.json, so it doesn't have to be handcrafted whenever files are added/removed.

To generate/update package.json, run from repo root as follows:

python3 tools/genpkgjson.py > package.json

(instead of python3, micropython can also be used)

Note: at present MIP does not support any way to specify repo-relative urls, so at present the generated json will point to gituhub:micropython/micropython-esp32-ulp, and when working with forks of this repo, that url would need to be adjusted to point to the fork instead of this repo.

Closes #93

Also add a tool for generating package.json, so it doesn't have
to be handcrafted when files are added/removed.

To generate/update package.json, run from repo root as follows:

python3 tools/genpkgjson.py > package.json

(instead of python3, micropython can also be used)

Note: at present MIP does not support any way to specify repo-relative
urls, so at present the generated json will point to
gituhub:micropython/micropython-esp32-ulp, which would need to be
adapted in any forks of this repo.
Add documentation for installing with `mip`. Keep the instructions
for installing using `upip` for now, as we still intend to publish
to PyPI for now, and thereby keep supporting installing on older
MicroPython versions, which do not yet have `mip`.
@wnienhaus wnienhaus changed the title WIP: Add package.json for MIP package manager Add package.json for MIP package manager Sep 4, 2023
@wnienhaus wnienhaus merged commit 74d2f79 into micropython:master Sep 6, 2023
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update quickstart to use mip instead of upip
1 participant