Skip to content

Commit c17fda2

Browse files
authored
Bump MSRV to 1.56.0 and update windows-sys to 0.52 (#194)
1 parent 9d16b40 commit c17fda2

File tree

8 files changed

+23
-23
lines changed

8 files changed

+23
-23
lines changed

.github/workflows/ci.yml

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -6,17 +6,17 @@ on:
66
branches: [master]
77
jobs:
88
build-msrv:
9-
name: Build on MSRV (1.48)
9+
name: Build on MSRV (1.56)
1010
strategy:
1111
fail-fast: false
1212
matrix:
1313
include:
1414
- os: ubuntu-latest
1515
target: x86_64-unknown-linux-gnu
16-
rust: 1.48.0
16+
rust: 1.56.0
1717
- os: windows-latest
1818
target: i686-pc-windows-msvc
19-
rust: 1.48.0
19+
rust: 1.56.0
2020
runs-on: ${{ matrix.os }}
2121
steps:
2222
- name: Install rust
@@ -46,16 +46,16 @@ jobs:
4646
rust: stable
4747
- os: ubuntu-latest
4848
target: x86_64-unknown-linux-gnu
49-
rust: 1.51.0
49+
rust: 1.56.0
5050
- os: ubuntu-latest
5151
target: i686-unknown-linux-gnu
52-
rust: 1.51.0
52+
rust: 1.56.0
5353
- os: windows-latest
5454
target: i686-pc-windows-msvc
55-
rust: 1.51.0
55+
rust: 1.56.0
5656
- os: windows-latest
5757
target: x86_64-pc-windows-msvc
58-
rust: 1.51.0
58+
rust: 1.56.0
5959
- os: ubuntu-latest
6060
target: x86_64-unknown-linux-gnu
6161
rust: stable
@@ -72,7 +72,7 @@ jobs:
7272
target: ${{ matrix.target }}
7373
override: true
7474
- name: Checkout
75-
uses: actions/checkout@v3
75+
uses: actions/checkout@v4
7676
- name: Install linker
7777
if: matrix.target == 'i686-unknown-linux-gnu'
7878
run: |
@@ -108,7 +108,7 @@ jobs:
108108
target: ${{ matrix.target }}
109109
override: true
110110
- name: Checkout
111-
uses: actions/checkout@v3
111+
uses: actions/checkout@v4
112112
- name: Check
113113
env:
114114
CARGO_BUILD_TARGET: ${{ matrix.target }}
@@ -129,7 +129,7 @@ jobs:
129129
target: ${{ matrix.target }}
130130
override: true
131131
- name: Checkout
132-
uses: actions/checkout@v3
132+
uses: actions/checkout@v4
133133
- name: Install WasmTime
134134
run: |
135135
curl https://wasmtime.dev/install.sh -sSf | bash
@@ -152,6 +152,6 @@ jobs:
152152
toolchain: nightly
153153
override: true
154154
- name: Checkout
155-
uses: actions/checkout@v3
155+
uses: actions/checkout@v4
156156
- name: Test
157157
run: make test

.github/workflows/clippy.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ jobs:
77
runs-on: ubuntu-latest
88

99
steps:
10-
- uses: actions/checkout@v3
10+
- uses: actions/checkout@v4
1111
- uses: actions-rs/toolchain@v1
1212
with:
1313
toolchain: stable

.github/workflows/minver.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ jobs:
99
continue-on-error: true
1010

1111
steps:
12-
- uses: actions/checkout@v3
12+
- uses: actions/checkout@v4
1313
- uses: actions-rs/toolchain@v1
1414
with:
1515
toolchain: nightly

.github/workflows/rustfmt.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ jobs:
77
runs-on: ubuntu-latest
88

99
steps:
10-
- uses: actions/checkout@v3
10+
- uses: actions/checkout@v4
1111
- uses: actions-rs/toolchain@v1
1212
with:
1313
toolchain: stable

Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ homepage = "https://github.com/console-rs/console"
1010
repository = "https://github.com/console-rs/console"
1111
documentation = "https://docs.rs/console"
1212
readme = "README.md"
13-
rust-version = "1.48.0"
13+
rust-version = "1.56.0"
1414

1515
[features]
1616
default = ["unicode-width", "ansi-parsing"]
@@ -26,7 +26,7 @@ lazy_static = "1.4.0"
2626
encode_unicode = "0.3"
2727

2828
[target.'cfg(windows)'.dependencies.windows-sys]
29-
version = "0.48.0"
29+
version = "0.52.0"
3030
features = [
3131
"Win32_Foundation",
3232
"Win32_System_Console",

Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,5 +35,6 @@ lint:
3535

3636
msrv-lock:
3737
@cargo update -p proptest --precise=1.0.0
38+
@cargo update -p byteorder --precise=1.4.0
3839

3940
.PHONY: all doc build check test format format-check lint check-minver msrv-lock

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
[![Build Status](https://github.com/console-rs/console/workflows/CI/badge.svg?branch=master)](https://github.com/console-rs/console/actions?query=workflow%3ACI)
44
[![Crates.io](https://img.shields.io/crates/d/console.svg)](https://crates.io/crates/console)
55
[![License](https://img.shields.io/github/license/console-rs/console)](https://github.com/console-rs/console/blob/master/LICENSE)
6-
[![rustc 1.48.0](https://img.shields.io/badge/rust-1.48%2B-orange.svg)](https://img.shields.io/badge/rust-1.48%2B-orange.svg)
6+
[![rustc 1.56.0](https://img.shields.io/badge/rust-1.56%2B-orange.svg)](https://img.shields.io/badge/rust-1.56%2B-orange.svg)
77
[![Documentation](https://docs.rs/console/badge.svg)](https://docs.rs/console)
88

99
**console** is a library for Rust that provides access to various terminal

src/unix_term.rs

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ use std::io;
55
use std::io::{BufRead, BufReader};
66
use std::mem;
77
use std::os::unix::io::AsRawFd;
8-
use std::ptr;
98
use std::str;
109

1110
use crate::kb::Key;
@@ -50,7 +49,7 @@ pub fn terminal_size(out: &Term) -> Option<(u16, u16)> {
5049
return None;
5150
}
5251

53-
let mut winsize: libc::winsize = std::mem::zeroed();
52+
let mut winsize: libc::winsize = mem::zeroed();
5453

5554
// FIXME: ".into()" used as a temporary fix for a libc bug
5655
// https://github.com/rust-lang/libc/pull/704
@@ -81,7 +80,7 @@ pub fn read_secure() -> io::Result<String> {
8180
}
8281
};
8382

84-
let mut termios = core::mem::MaybeUninit::uninit();
83+
let mut termios = mem::MaybeUninit::uninit();
8584
c_result(|| unsafe { libc::tcgetattr(fd, termios.as_mut_ptr()) })?;
8685
let mut termios = unsafe { termios.assume_init() };
8786
let original = termios;
@@ -125,7 +124,7 @@ fn select_fd(fd: i32, timeout: i32) -> io::Result<bool> {
125124

126125
let mut timeout_val;
127126
let timeout = if timeout < 0 {
128-
ptr::null_mut()
127+
std::ptr::null_mut()
129128
} else {
130129
timeout_val = libc::timeval {
131130
tv_sec: (timeout / 1000) as _,
@@ -139,8 +138,8 @@ fn select_fd(fd: i32, timeout: i32) -> io::Result<bool> {
139138
let ret = libc::select(
140139
fd + 1,
141140
&mut read_fd_set,
142-
ptr::null_mut(),
143-
ptr::null_mut(),
141+
std::ptr::null_mut(),
142+
std::ptr::null_mut(),
144143
timeout,
145144
);
146145
if ret < 0 {

0 commit comments

Comments
 (0)