kopia lustrzana https://github.com/micropython/micropython-lib
github/workflows: Add workflow to build all packages.
Signed-off-by: Damien George <damien@micropython.org>pull/603/head
rodzic
e3059a9b58
commit
c1526d2d1e
|
@ -0,0 +1,16 @@
|
||||||
|
name: Build all packages
|
||||||
|
|
||||||
|
on: [push, pull_request]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- uses: actions/setup-python@v1
|
||||||
|
- name: Setup environment
|
||||||
|
run: source tools/ci.sh && ci_build_packages_setup
|
||||||
|
- name: Check manifest files
|
||||||
|
run: source tools/ci.sh && ci_build_packages_check_manifest
|
||||||
|
- name: Compile package index
|
||||||
|
run: source tools/ci.sh && ci_build_packages_compile_index
|
26
tools/ci.sh
26
tools/ci.sh
|
@ -14,3 +14,29 @@ function ci_code_formatting_setup {
|
||||||
function ci_code_formatting_run {
|
function ci_code_formatting_run {
|
||||||
tools/codeformat.py -v
|
tools/codeformat.py -v
|
||||||
}
|
}
|
||||||
|
|
||||||
|
########################################################################################
|
||||||
|
# build packages
|
||||||
|
|
||||||
|
function ci_build_packages_setup {
|
||||||
|
git clone https://github.com/micropython/micropython.git /tmp/micropython
|
||||||
|
|
||||||
|
# build mpy-cross (use -O0 to speed up the build)
|
||||||
|
make -C /tmp/micropython/mpy-cross -j CFLAGS_EXTRA=-O0
|
||||||
|
|
||||||
|
# check the required programs run
|
||||||
|
/tmp/micropython/mpy-cross/build/mpy-cross --version
|
||||||
|
python3 /tmp/micropython/tools/manifestfile.py --help
|
||||||
|
}
|
||||||
|
|
||||||
|
function ci_build_packages_check_manifest {
|
||||||
|
for file in $(find -name manifest.py); do
|
||||||
|
echo "##################################################"
|
||||||
|
echo "# Testing $file"
|
||||||
|
python3 /tmp/micropython/tools/manifestfile.py --lib . --compile $file
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
|
function ci_build_packages_compile_index {
|
||||||
|
python3 tools/build.py --micropython /tmp/micropython --output /tmp/micropython-lib-deploy
|
||||||
|
}
|
||||||
|
|
Ładowanie…
Reference in New Issue