Building CP within a Github-codspace

CircuitPython on hardware including Adafruit's boards, and CircuitPython libraries using Blinka on host computers.

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
picofun
 
Posts: 23
Joined: Fri Jul 29, 2022 9:22 am

Building CP within a Github-codspace

Post by picofun »

I have been experimenting with Github's new feature called codespaces. The goal would be to clone the repo to a codespace and then have a working environment for building CP.

For now, this is more of a proof-of-concept. I created a script which does all the necessary steps as described in the guide. With this script, setting up the codespace takes a few minutes, but afterwards the build of a pico-board worked fine (about 180s for first build).

Ultimately, part of the setup (tools and so on) should go to a docker-image, the rest should execute during creation of the codespace.

If you want to try it: my repo is https://github.com/bablokb/circuitpython/tree/tufty2040. Press the green code-button, select "clone into codespace". After the clone is done, open a terminal and execute the script

Code: Select all

.devcontainer/prepare.sh
This again takes some time, but is a one time task. Afterwards, update your PATH with

Code: Select all

. .devcontainer/.arm-update-path.sh
and start the build:

Code: Select all

cd ports/raspberrypi
time make -j $(nproc) BOARD=pimoroni_tufty2040 TRANSLATION=de_DE

Locked
Please be positive and constructive with your questions and comments.

Return to “Adafruit CircuitPython”