Skip to content

Commit 9424adf

Browse files
bors[bot]passcod
andauthored
Merge #7
7: Add bors r=passcod a=passcod Co-authored-by: Félix Saparelli <felix@passcod.name>
2 parents fd95d64 + e775dbd commit 9424adf

File tree

7 files changed

+156
-98
lines changed

7 files changed

+156
-98
lines changed

.github/workflows/check.yml

Lines changed: 41 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,17 @@
1+
name: PR feedback
12
on:
23
pull_request:
3-
push:
4-
branches:
5-
- main
6-
- try/**
7-
8-
name: Checks & Tests
94

105
jobs:
11-
check:
6+
clippy:
127
strategy:
138
matrix:
14-
platform:
15-
- ubuntu
16-
- windows
17-
- macos
9+
include:
10+
- platform: macos
11+
- platform: ubuntu
12+
- platform: windows
1813

19-
name: Test on ${{ matrix.platform }}
14+
name: Clippy on ${{ matrix.platform }}
2015
runs-on: "${{ matrix.platform }}-latest"
2116

2217
steps:
@@ -25,60 +20,55 @@ jobs:
2520
with:
2621
profile: minimal
2722
toolchain: stable
28-
override: true
23+
default: true
24+
2925
- run: rustup component add clippy
3026
- uses: actions-rs/cargo@v1
3127
with:
32-
command: check
33-
- uses: actions-rs/cargo@v1
34-
with:
35-
command: check
36-
args: --features windows-console
37-
# check to make sure it keeps compiling, but this is unsupported buggy code for now
28+
command: clippy
3829

39-
- uses: actions-rs/cargo@v1
40-
if: matrix.platform != 'windows'
41-
with:
42-
command: test
43-
- if: matrix.platform == 'windows'
44-
shell: powershell
45-
run: cargo test --doc
46-
- if: matrix.platform == 'windows'
47-
shell: powershell
48-
run: cargo test --test platformed terminfo
49-
- if: matrix.platform == 'windows'
50-
shell: powershell
51-
run: cargo test --test platformed xterm
52-
- if: matrix.platform == 'windows'
53-
shell: powershell
54-
run: cargo test --test platformed tput
55-
- if: matrix.platform == 'windows'
56-
shell: powershell
57-
run: cargo test --test platformed windows_cls
58-
# I've absolutely tested the windows_vt things LOCALLY but they DON'T WORK IN CI
59-
# I don't know why and at this point I'm very very tired. If you know, help pls.
60-
- if: matrix.platform == 'windows'
61-
shell: powershell
62-
run: cargo test --test platformed vt_ris
63-
- if: matrix.platform == 'windows'
64-
shell: powershell
65-
run: cd tests/win10; cargo run
30+
fmt-check:
31+
name: Check formatting
32+
runs-on: ubuntu-latest
6633

34+
steps:
35+
- uses: actions/checkout@v2
36+
- uses: actions-rs/toolchain@v1
37+
with:
38+
profile: minimal
39+
toolchain: stable
40+
override: true
6741
- uses: actions-rs/cargo@v1
6842
with:
69-
command: clippy
43+
command: fmt
44+
args: --check
45+
46+
windows-console:
47+
name: Check windows-console feature compiles
48+
runs-on: windows-latest
7049

71-
msrv:
72-
name: Check on MSRV
73-
runs-on: ubuntu-latest
7450
steps:
7551
- uses: actions/checkout@v2
7652
- uses: actions-rs/toolchain@v1
7753
with:
7854
profile: minimal
79-
toolchain: 1.51.0
55+
toolchain: stable
8056
override: true
8157
- uses: actions-rs/cargo@v1
8258
with:
8359
command: check
60+
args: --features windows-console
61+
# check to make sure it keeps compiling, but this is unsupported buggy code for now
8462

63+
windows-tests-msrv:
64+
name: Check windows-10 tests compile on MSRV
65+
runs-on: windows-latest
66+
67+
steps:
68+
- uses: actions/checkout@v2
69+
- uses: actions-rs/toolchain@v1
70+
with:
71+
profile: minimal
72+
toolchain: 1.51.0
73+
override: true
74+
- run: cd tests/win10; cargo check

.github/workflows/main.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: Main branch
2+
on:
3+
push:
4+
branches:
5+
- main
6+
7+
jobs:
8+
check:
9+
strategy:
10+
matrix:
11+
include:
12+
- platform: macos
13+
- platform: ubuntu
14+
- platform: windows
15+
16+
name: Check on ${{ matrix.platform }}
17+
runs-on: "${{ matrix.platform }}-latest"
18+
19+
steps:
20+
- uses: actions/checkout@v2
21+
- uses: actions-rs/toolchain@v1
22+
with:
23+
profile: minimal
24+
toolchain: stable
25+
default: true
26+
- uses: actions-rs/cargo@v1
27+
with:
28+
command: check

.github/workflows/merge.yml

Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
name: Merge (with Bors)
2+
on:
3+
push:
4+
branches:
5+
- staging
6+
- trying
7+
8+
jobs:
9+
check:
10+
strategy:
11+
matrix:
12+
include:
13+
- platform: macos
14+
toolchain: stable
15+
- platform: macos
16+
toolchain: 1.51.0
17+
- platform: ubuntu
18+
toolchain: stable
19+
- platform: ubuntu
20+
toolchain: 1.51.0
21+
- platform: windows
22+
toolchain: stable
23+
- platform: windows
24+
toolchain: 1.51.0
25+
26+
name: Test on ${{ matrix.platform }} with Rust ${{ matrix.toolchain }}
27+
runs-on: "${{ matrix.platform }}-latest"
28+
29+
steps:
30+
- uses: actions/checkout@v2
31+
- uses: actions-rs/toolchain@v1
32+
with:
33+
profile: minimal
34+
toolchain: "${{ matrix.toolchain }}"
35+
default: true
36+
- uses: actions-rs/cargo@v1
37+
if: "matrix.platform != 'windows'"
38+
with:
39+
command: test
40+
- if: "matrix.platform == 'windows'"
41+
shell: powershell
42+
run: cargo test --doc
43+
- if: "matrix.platform == 'windows'"
44+
shell: powershell
45+
run: cargo test --test platformed terminfo
46+
- if: "matrix.platform == 'windows'"
47+
shell: powershell
48+
run: cargo test --test platformed xterm
49+
- if: "matrix.platform == 'windows'"
50+
shell: powershell
51+
run: cargo test --test platformed tput
52+
- if: "matrix.platform == 'windows'"
53+
shell: powershell
54+
run: cargo test --test platformed windows_cls
55+
# I've absolutely tested the windows_vt things LOCALLY but they DON'T WORK IN CI
56+
# I don't know why and at this point I'm very very tired. If you know, help pls.
57+
- if: "matrix.platform == 'windows'"
58+
shell: powershell
59+
run: cargo test --test platformed vt_ris
60+
61+
# remove toolchain restriction when bumping msrv above 1.51
62+
- if: "matrix.platform == 'windows' && matrix.toolchain == 'stable'"
63+
shell: powershell
64+
run: cd tests/win10; cargo run

CARETAKERS.md

Lines changed: 0 additions & 39 deletions
This file was deleted.

README.md

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,17 @@
1-
[![Crate release version](https://flat.badgen.net/crates/v/clearscreen)](https://crates.io/crates/clearscreen)
2-
[![Crate license: Apache 2.0 or MIT](https://flat.badgen.net/badge/license/Apache%202.0%20or%20MIT)][copyright]
3-
![MSRV: 1.51.0 (breaking)](https://flat.badgen.net/badge/MSRV/1.51.0%20%28breaking%29/green)
4-
[![CI status](https://github.com/watchexec/clearscreen/actions/workflows/check.yml/badge.svg)](https://github.com/watchexec/clearscreen/actions/workflows/check.yml)
5-
[![Uses Caretaker Maintainership](https://flat.badgen.net/badge/Caretaker/Maintainership%20👥%20/purple)][caretaker]
1+
[![Crate release version](https://badgen.net/crates/v/clearscreen)](https://crates.io/crates/clearscreen)
2+
[![Crate license: Apache 2.0 or MIT](https://badgen.net/badge/license/Apache%202.0%20or%20MIT)][copyright]
3+
![MSRV: 1.51.0 (breaking)](https://badgen.net/badge/MSRV/1.51.0%20%28breaking%29/green)
4+
[![Bors enabled](https://bors.tech/images/badge_small.svg)](https://app.bors.tech/repositories/45671)
5+
[![CI status on main branch](https://github.com/watchexec/clearscreen/actions/workflows/main.yml/badge.svg)](https://github.com/watchexec/clearscreen/actions/workflows/main.yml)
66

77
# ClearScreen
88

99
_Cross-platform terminal screen clearing library._
1010

1111
- **[API documentation][docs]**.
1212
- [Dual-licensed][copyright] with Apache 2.0 and MIT.
13-
- Uses [Caretaker Maintainership][caretaker].
1413
- Minimum Supported Rust Version: 1.51.0.
1514

16-
[caretaker]: ./CARETAKERS.md
1715
[copyright]: ./COPYRIGHT
1816
[docs]: https://docs.rs/clearscreen
1917

bors.toml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
delete_merged_branches = true
2+
update_base_for_deletes = true
3+
4+
status = [
5+
"Test on macos with Rust stable",
6+
"Test on ubuntu with Rust stable",
7+
"Test on windows with Rust stable",
8+
"Test on macos with Rust 1.51.0",
9+
"Test on ubuntu with Rust 1.51.0",
10+
"Test on windows with Rust 1.51.0",
11+
]
12+
13+
# Disabled until https://github.com/bors-ng/bors-ng/issues/1434 is fixed
14+
#pr_status = [
15+
# "Clippy on macos",
16+
# "Clippy on ubuntu",
17+
# "Clippy on windows",
18+
#]

tests/win10/Cargo.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
[package]
22
name = "clearscreen-test-win10"
33
version = "0.0.0"
4-
edition = "2021"
54

65
[dependencies]
76
clearscreen = { path = "../.." }

0 commit comments

Comments
 (0)