@@ -10,78 +10,78 @@ jobs:
1010 runs-on : ubuntu-latest
1111 strategy :
1212 matrix :
13- python-version : [ '3.11' ]
14- tmux-version : [ '2.6', '2.7', '2.8', '3.0a', '3.1b', '3.2a', '3.3a', 'master' ]
13+ python-version : ['3.11']
14+ tmux-version : ['2.6', '2.7', '2.8', '3.0a', '3.1b', '3.2a', '3.3a', 'master']
1515 # balance ci coverage across supported python/tmux versions with CI speed
1616 include :
1717 - python-version : ' 3.8'
1818 tmux-version : ' 2.6'
1919 - python-version : ' 3.8'
2020 tmux-version : ' master'
2121 steps :
22- - uses : actions/checkout@v3
23-
24- - name : Install poetry
25- run : pipx install "poetry==1.6.1"
26-
27- - name : Set up Python ${{ matrix.python-version }}
28- uses : actions/setup-python@v4
29- with :
30- python-version : ${{ matrix.python-version }}
31- cache : ' poetry'
32-
33- - name : Setup tmux build cache for tmux ${{ matrix.tmux-version }}
34- id : tmux-build-cache
35- uses : actions/cache@v3
36- with :
37- path : ~/tmux-builds/tmux-${{ matrix.tmux-version }}
38- key : tmux-${{ matrix.tmux-version }}
39-
40- - name : Build tmux ${{ matrix.tmux-version }}
41- if : steps.tmux-build-cache.outputs.cache-hit != 'true'
42- run : |
43- sudo apt install libevent-dev libncurses5-dev libtinfo-dev libutempter-dev bison
44- mkdir ~/tmux-builds
45- mkdir ~/tmux-src
46- git clone https://github.com/tmux/tmux.git ~/tmux-src/tmux-${{ matrix.tmux-version }}
47- cd ~/tmux-src/tmux-${{ matrix.tmux-version }}
48- git checkout ${{ matrix.tmux-version }}
49- sh autogen.sh
50- ./configure --prefix=$HOME/tmux-builds/tmux-${{ matrix.tmux-version }} && make && make install
51- export PATH=$HOME/tmux-builds/tmux-${{ matrix.tmux-version }}/bin:$PATH
52- cd ~
53- tmux -V
54-
55- - name : Install python dependencies
56- run : |
57- poetry install -E "test coverage lint"
58-
59- - name : Lint with black . --check
60- run : poetry run black . --check
61-
62- - name : Lint with ruff .
63- run : poetry run ruff .
64-
65- - name : Lint with mypy
66- run : poetry run mypy .
67-
68- - name : Print python versions
69- run : |
70- python -V
71- poetry run python -V
72-
73- - name : Test with pytest
74- continue-on-error : ${{ matrix.tmux-version == 'master' }}
75- run : |
76- sudo apt install libevent-2.1-7
77- export PATH=$HOME/tmux-builds/tmux-${{ matrix.tmux-version }}/bin:$PATH
78- ls $HOME/tmux-builds/tmux-${{ matrix.tmux-version }}/bin
79- tmux -V
80- poetry run py.test --cov=./ --cov-report=xml
81-
82- - uses : codecov/codecov-action@v3
83- with :
84- token : ${{ secrets.CODECOV_TOKEN }}
22+ - uses : actions/checkout@v3
23+
24+ - name : Install poetry
25+ run : pipx install "poetry==1.6.1"
26+
27+ - name : Set up Python ${{ matrix.python-version }}
28+ uses : actions/setup-python@v4
29+ with :
30+ python-version : ${{ matrix.python-version }}
31+ cache : ' poetry'
32+
33+ - name : Setup tmux build cache for tmux ${{ matrix.tmux-version }}
34+ id : tmux-build-cache
35+ uses : actions/cache@v3
36+ with :
37+ path : ~/tmux-builds/tmux-${{ matrix.tmux-version }}
38+ key : tmux-${{ matrix.tmux-version }}
39+
40+ - name : Build tmux ${{ matrix.tmux-version }}
41+ if : steps.tmux-build-cache.outputs.cache-hit != 'true'
42+ run : |
43+ sudo apt install libevent-dev libncurses5-dev libtinfo-dev libutempter-dev bison
44+ mkdir ~/tmux-builds
45+ mkdir ~/tmux-src
46+ git clone https://github.com/tmux/tmux.git ~/tmux-src/tmux-${{ matrix.tmux-version }}
47+ cd ~/tmux-src/tmux-${{ matrix.tmux-version }}
48+ git checkout ${{ matrix.tmux-version }}
49+ sh autogen.sh
50+ ./configure --prefix=$HOME/tmux-builds/tmux-${{ matrix.tmux-version }} && make && make install
51+ export PATH=$HOME/tmux-builds/tmux-${{ matrix.tmux-version }}/bin:$PATH
52+ cd ~
53+ tmux -V
54+
55+ - name : Install python dependencies
56+ run : |
57+ poetry install -E "test coverage lint"
58+
59+ - name : Lint with black . --check
60+ run : poetry run black . --check
61+
62+ - name : Lint with ruff .
63+ run : poetry run ruff .
64+
65+ - name : Lint with mypy
66+ run : poetry run mypy .
67+
68+ - name : Print python versions
69+ run : |
70+ python -V
71+ poetry run python -V
72+
73+ - name : Test with pytest
74+ continue-on-error : ${{ matrix.tmux-version == 'master' }}
75+ run : |
76+ sudo apt install libevent-2.1-7
77+ export PATH=$HOME/tmux-builds/tmux-${{ matrix.tmux-version }}/bin:$PATH
78+ ls $HOME/tmux-builds/tmux-${{ matrix.tmux-version }}/bin
79+ tmux -V
80+ poetry run py.test --cov=./ --cov-report=xml
81+
82+ - uses : codecov/codecov-action@v3
83+ with :
84+ token : ${{ secrets.CODECOV_TOKEN }}
8585
8686 release :
8787 runs-on : ubuntu-latest
9090
9191 strategy :
9292 matrix :
93- python-version : [" 3.11" ]
93+ python-version : [' 3.11' ]
9494
9595 steps :
9696 - uses : actions/checkout@v3
0 commit comments