Install Go 1.18 on CI

This commit is contained in:
Kovid Goyal 2022-09-21 10:46:58 +05:30
parent 2cacd7a64a
commit d0e133885c
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -5,6 +5,7 @@ env:
ASAN_OPTIONS: leak_check_at_exit=0 ASAN_OPTIONS: leak_check_at_exit=0
LC_ALL: en_US.UTF-8 LC_ALL: en_US.UTF-8
LANG: en_US.UTF-8 LANG: en_US.UTF-8
GO_INSTALL_VERSION: ">=1.18.0"
permissions: permissions:
contents: read # to fetch code (actions/checkout) contents: read # to fetch code (actions/checkout)
@ -44,20 +45,26 @@ jobs:
cc: gcc cc: gcc
steps: steps:
- name: Checkout source code - name: Checkout source code
uses: actions/checkout@v3 uses: actions/checkout@v3
with: with:
fetch-depth: 10 fetch-depth: 10
- name: Set up Python ${{ matrix.pyver }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.pyver }}
- name: Build kitty - name: Set up Python ${{ matrix.pyver }}
run: python .github/workflows/ci.py build uses: actions/setup-python@v3
with:
python-version: ${{ matrix.pyver }}
- name: Test kitty - name: Install Go
run: python .github/workflows/ci.py test uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_INSTALL_VERSION }}
- name: Build kitty
run: python .github/workflows/ci.py build
- name: Test kitty
run: python .github/workflows/ci.py test
linux-package: linux-package:
name: Linux package name: Linux package
@ -65,42 +72,54 @@ jobs:
env: env:
CFLAGS: -funsigned-char CFLAGS: -funsigned-char
steps: steps:
- name: Checkout source code - name: Checkout source code
uses: actions/checkout@v3 uses: actions/checkout@v3
with: with:
fetch-depth: 0 # needed for :commit: docs role fetch-depth: 0 # needed for :commit: docs role
- name: Test for trailing whitespace - name: Test for trailing whitespace
run: if grep -Inr '\s$' kitty kitty_tests kittens docs *.py *.asciidoc *.rst *.go .gitattributes .gitignore; then echo Trailing whitespace found, aborting.; exit 1; fi run: if grep -Inr '\s$' kitty kitty_tests kittens docs *.py *.asciidoc *.rst *.go .gitattributes .gitignore; then echo Trailing whitespace found, aborting.; exit 1; fi
<<<<<<< HEAD
- name: Set up Python - name: Set up Python
uses: actions/setup-python@v3 uses: actions/setup-python@v3
with: with:
python-version: "3.10" python-version: "3.10"
=======
- name: Set up Python
uses: actions/setup-python@v3
with:
python-version: 3.9
>>>>>>> 359bf535d (Install Go 1.18 on CI)
- name: Install build-only deps - name: Install Go
run: python -m pip install -r docs/requirements.txt flake8 mypy types-requests types-docutils uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_INSTALL_VERSION }}
- name: Run pyflakes - name: Install build-only deps
run: python -m flake8 --count . run: python -m pip install -r docs/requirements.txt flake8 mypy types-requests types-docutils
- name: Run gofmt - name: Run pyflakes
run: go version && python .github/workflows/ci.py gofmt run: python -m flake8 --count .
- name: Build kitty package - name: Run gofmt
run: python .github/workflows/ci.py package run: go version && python .github/workflows/ci.py gofmt
- name: Build kitty - name: Build kitty package
run: python setup.py build --debug run: python .github/workflows/ci.py package
- name: Run mypy - name: Build kitty
run: which python && python -m mypy --version && ./test.py mypy run: python setup.py build --debug
- name: Build man page - name: Run mypy
run: make FAIL_WARN=1 man run: which python && python -m mypy --version && ./test.py mypy
- name: Build HTML docs - name: Build man page
run: make FAIL_WARN=1 html run: make FAIL_WARN=1 man
- name: Build HTML docs
run: make FAIL_WARN=1 html
bundle: bundle:
name: Bundle test (${{ matrix.os }}) name: Bundle test (${{ matrix.os }})
@ -111,42 +130,52 @@ jobs:
env: env:
KITTY_BUNDLE: 1 KITTY_BUNDLE: 1
steps: steps:
- name: Checkout source code - name: Checkout source code
uses: actions/checkout@master uses: actions/checkout@master
with: with:
fetch-depth: 10 fetch-depth: 10
- name: Build kitty - name: Install Go
run: which python3 && python3 .github/workflows/ci.py build uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_INSTALL_VERSION }}
- name: Test kitty - name: Build kitty
run: python3 .github/workflows/ci.py test run: which python3 && python3 .github/workflows/ci.py build
- name: Test kitty
run: python3 .github/workflows/ci.py test
brew: brew:
name: macOS Brew name: macOS Brew
runs-on: macos-latest runs-on: macos-latest
steps: steps:
- name: Checkout source code - name: Checkout source code
uses: actions/checkout@master uses: actions/checkout@master
with: with:
fetch-depth: 0 # needed for :commit: docs role fetch-depth: 0 # needed for :commit: docs role
- name: Set up Python - name: Set up Python
uses: actions/setup-python@v3 uses: actions/setup-python@v3
with: with:
python-version: "3.10" python-version: "3.10"
- name: Build kitty - name: Install Go
run: python3 .github/workflows/ci.py build uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_INSTALL_VERSION }}
- name: Test kitty - name: Build kitty
run: python3 .github/workflows/ci.py test run: python3 .github/workflows/ci.py build
- name: Install deps for docs - name: Test kitty
run: python3 -m pip install -r docs/requirements.txt run: python3 .github/workflows/ci.py test
- name: Builds docs - name: Install deps for docs
run: make FAIL_WARN=1 docs run: python3 -m pip install -r docs/requirements.txt
- name: Build kitty package - name: Builds docs
run: python3 .github/workflows/ci.py package run: make FAIL_WARN=1 docs
- name: Build kitty package
run: python3 .github/workflows/ci.py package