diff --git a/.github/workflows/tools.yml b/.github/workflows/tools.yml index 1159677..c785b37 100644 --- a/.github/workflows/tools.yml +++ b/.github/workflows/tools.yml @@ -53,7 +53,16 @@ jobs: - run: sudo apt-get install -y cloc jq - name: Print source lines of code run: cloc --by-file-by-lang flix + - name: Checkout previous revision + uses: actions/checkout@v4 + with: + ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.base.sha || github.event.before }} + path: prev - name: Annotate total source lines run: | - sloc=$(cloc flix --json | jq -r '.SUM.code') - echo "::notice title=SLOC::Current SLOC = $sloc" + SLOC=$(cloc flix --json | jq -r '.SUM.code') + PREV_SLOC=$(cloc prev/flix --json | jq -r '.SUM.code') + DIFF=$(printf '%+d' "$((SLOC - PREV_SLOC))") + echo "* Current SLOC: $SLOC" >> $GITHUB_STEP_SUMMARY + echo "* Previous SLOC: $PREV_SLOC" >> $GITHUB_STEP_SUMMARY + echo "* Diff: $DIFF" >> $GITHUB_STEP_SUMMARY diff --git a/flix/config.h b/flix/config.h index badea19..a139ec6 100644 --- a/flix/config.h +++ b/flix/config.h @@ -8,6 +8,8 @@ void setDefaults() { // Set defaults here + int __x = 0; + #if defined(CONFIG_IDF_TARGET_ESP32S3) || defined(CONFIG_IDF_TARGET_ESP32C3) pwmFrequency = 38000; #endif