Bootstrap a CODAL-based project from a single Python script.
An example of creating a microbit-v2 project from just one initial build file:
./build.py
( curl/wget/download link ) from this repository and put in a new folder for your project./build.py
to retrieve a list of valid targets./build.py codal-microbit-v2
(replace codal-microbit-v2
with your selected target)source/
directoryAny further runs of ./build.py
will now use the latest downloaded version of the build tools, and will take the same arguments as traditional builds (see ./build.py --help
for deatils).
Some additional targets can be included by including new URLs to build.py
's TARGET_LIST
variable, by default this is as follows:
TARGET_LIST = [
"https://raw.githubusercontent.com/lancaster-university/codal/master/utils/targets.json"
]
To add the beta-targets list, include the URL: https://raw.githubusercontent.com/lancaster-university/codal-bootstrap/main/beta-targets.json
like so:
TARGET_LIST = [
"https://raw.githubusercontent.com/lancaster-university/codal/master/utils/targets.json",
"https://raw.githubusercontent.com/lancaster-university/codal-bootstrap/main/beta-targets.json"
]
To force bootstrap mode to run again, simply remove the codal.json
file in your project directory, and follow the installation steps above.
You may also want to remove your libraries
folder entirely to force all libraries to be re-downloaded.