From 03c04e77ae5f94750408009cfa91f06b96a5898d Mon Sep 17 00:00:00 2001 From: Jeff Epler Date: Sun, 14 Jun 2020 18:54:05 -0500 Subject: [PATCH] actions: Try checkout v2.2.0 This version is supposed to > Fetch all history for all tags and branches when fetch-depth=0 We leave the tags fetch in place so that actions _in cloned repos_ work. Cloned repos' tags do not necessarily match adafruit/circuitpython, but we want version reporting to be able to use adafruit/circuitpython tags when they are most relevant according to "git describe"'s heuristics. Submodules are different, as they always point to the repo specified in .gitmodules, so they don't need special handling to get the most relevant tags. --- .github/workflows/build.yml | 25 +++++-------------------- .github/workflows/create_website_pr.yml | 3 +-- 2 files changed, 6 insertions(+), 22 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 00454cc2da..ae73b3a655 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -16,14 +16,11 @@ jobs: env: GITHUB_CONTEXT: ${{ toJson(github) }} run: echo "$GITHUB_CONTEXT" - - uses: actions/checkout@v2 + - uses: actions/checkout@v2.2.0 with: submodules: true fetch-depth: 0 - run: git fetch --recurse-submodules=no https://github.com/adafruit/circuitpython refs/tags/*:refs/tags/* - - run: git submodule sync - - run: git submodule foreach git remote -v - - run: git submodule foreach git fetch --recurse-submodules=no origin +refs/tags/*:refs/tags/* - name: CircuitPython version run: git describe --dirty --tags - name: Set up Python 3.8 @@ -110,14 +107,11 @@ jobs: gcc --version python3 --version msgfmt --version - - uses: actions/checkout@v2 + - uses: actions/checkout@v2.2.0 with: submodules: true fetch-depth: 0 - run: git fetch --recurse-submodules=no https://github.com/adafruit/circuitpython refs/tags/*:refs/tags/* - - run: git submodule sync - - run: git submodule foreach git remote -v - - run: git submodule foreach git fetch --recurse-submodules=no origin +refs/tags/*:refs/tags/* - name: CircuitPython version run: git describe --dirty --tags - name: Build mpy-cross @@ -286,14 +280,11 @@ jobs: gcc --version arm-none-eabi-gcc --version python3 --version - - uses: actions/checkout@v2 + - uses: actions/checkout@v2.2.0 with: submodules: true fetch-depth: 0 - run: git fetch --recurse-submodules=no https://github.com/adafruit/circuitpython refs/tags/*:refs/tags/* - - run: git submodule sync - - run: git submodule foreach git remote -v - - run: git submodule foreach git fetch --recurse-submodules=no origin +refs/tags/*:refs/tags/* - name: mpy-cross run: make -C mpy-cross -j2 - name: build @@ -337,14 +328,11 @@ jobs: gcc --version riscv64-unknown-elf-gcc --version python3 --version - - uses: actions/checkout@v2 + - uses: actions/checkout@v2.2.0 with: submodules: true fetch-depth: 0 - run: git fetch --recurse-submodules=no https://github.com/adafruit/circuitpython refs/tags/*:refs/tags/* - - run: git submodule sync - - run: git submodule foreach git remote -v - - run: git submodule foreach git fetch --recurse-submodules=no origin +refs/tags/*:refs/tags/* - name: mpy-cross run: make -C mpy-cross -j2 - name: build @@ -377,14 +365,11 @@ jobs: uses: actions/setup-python@v1 with: python-version: 3.8 - - uses: actions/checkout@v2 + - uses: actions/checkout@v2.2.0 with: submodules: true fetch-depth: 0 - run: git fetch --recurse-submodules=no https://github.com/adafruit/circuitpython refs/tags/*:refs/tags/* - - run: git submodule sync - - run: git submodule foreach git remote -v - - run: git submodule foreach git fetch --recurse-submodules=no origin +refs/tags/*:refs/tags/* - name: CircuitPython version run: git describe --dirty --tags - uses: actions/cache@v1 diff --git a/.github/workflows/create_website_pr.yml b/.github/workflows/create_website_pr.yml index 79a6c68a75..9907c08ae6 100644 --- a/.github/workflows/create_website_pr.yml +++ b/.github/workflows/create_website_pr.yml @@ -23,12 +23,11 @@ jobs: run: | gcc --version python3 --version - - uses: actions/checkout@v2 + - uses: actions/checkout@v2.2.0 with: submodules: true fetch-depth: 0 - run: git fetch --recurse-submodules=no https://github.com/adafruit/circuitpython refs/tags/*:refs/tags/* - - run: git submodule foreach git fetch --recurse-submodules=no origin +refs/tags/*:refs/tags/* - name: CircuitPython version run: git describe --dirty --tags - name: Website