name: Check code size

on:
  push:
  pull_request:
    paths:
      - '.github/workflows/*.yml'
      - 'tools/**'
      - 'py/**'
      - 'extmod/**'
      - 'lib/**'
      - 'ports/bare-arm/**'
      - 'ports/minimal/**'

jobs:
  build:
    runs-on: ubuntu-latest
    steps:
    - uses: actions/checkout@v2
    - name: Install packages
      run: source tools/ci.sh && ci_code_size_setup
    - name: Build
      run: source tools/ci.sh && ci_code_size_build
    - name: Compute code size difference
      run: tools/metrics.py diff --error-threshold 0 ~/size0 ~/size1

name: Check code size

on:
  push:
  pull_request:
    paths:
      - '.github/workflows/*.yml'
      - 'tools/**'
      - 'py/**'
      - 'extmod/**'
      - 'lib/**'
      - 'ports/bare-arm/**'
      - 'ports/minimal/**'

jobs:
  build:
    runs-on: ubuntu-latest
    steps:
    - uses: actions/checkout@v2
    - name: Update package list
      run: sudo apt-get update -qq || true
    - name: Install packages
      run: source tools/ci.sh && ci_code_size_setup
    - name: Build
      run: source tools/ci.sh && ci_code_size_build
    - name: Compute code size difference
      run: tools/metrics.py diff --error-threshold 0 ~/size0 ~/size1

Update package list before install packages.
.github/workflows: Update package list before install packages.

Change-Id: Ie4f9e803a0aefc15430841347cadf8c16f9cfaaf
Signed-off-by: Paul Sokolovsky <9dc5061f178bb11813e14f1ed02ba27eaf21fa5d@users.sourceforge.net>
