Skip to content

Commit

Permalink
release: 0.3.1
Browse files Browse the repository at this point in the history
  • Loading branch information
fosskers committed Sep 14, 2024
1 parent db73aae commit 8e7fd3a
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 10 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# `linya` Changelog

## 0.3.1 (2024-09-15)

#### Changed

- Bumped dependencies.

## 0.3.0 (2022-05-18)

#### Added
Expand Down
5 changes: 2 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "linya"
version = "0.3.0"
version = "0.3.1"
authors = ["Colin Woodbury <[email protected]>"]
edition = "2021"
description = "Simple concurrent progress bars."
Expand All @@ -16,10 +16,9 @@ exclude = ["screenshots/*"]
github = { repository = "fosskers/linya", branch = "master", workflow = "Tests" }

[dependencies]
terminal_size = "0.1"
terminal_size = "0.3"

[dev-dependencies]
curl = "0.4"
rand = "0.8"
rayon = "1.5"
version-sync = "0.9"
5 changes: 2 additions & 3 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,6 @@
//! [indicatif]: https://lib.rs/crates/indicatif

#![warn(missing_docs)]
#![doc(html_root_url = "https://docs.rs/linya/0.3.0")]

use std::fmt;
use std::io::{BufWriter, Stderr, Write};
Expand Down Expand Up @@ -205,7 +204,7 @@ impl Progress {
// running in a terminal, and no rerendering can be done.
if let Some((term_width, term_height)) = self.size {
let pos = self.bars.len() - bar.0;
let mut b = &mut self.bars[bar.0];
let b = &mut self.bars[bar.0];
let cur_percent = (100 * b.curr as u64) / (b.total as u64);
// For a newly cancelled bar `diff` is equal to 100.
let diff = cur_percent - b.prev_percent as u64;
Expand Down Expand Up @@ -288,7 +287,7 @@ impl Progress {
/// ownership so that the bar cannot be manipulated again.
pub fn cancel(&mut self, bar: Bar) {
{
let mut b = &mut self.bars[bar.0];
let b = &mut self.bars[bar.0];
b.cancelled = true;
// Force redraw by setting `prev_percent` to 0.
b.prev_percent = 0;
Expand Down
4 changes: 0 additions & 4 deletions tests/version-numbers.rs

This file was deleted.

0 comments on commit 8e7fd3a

Please sign in to comment.