Skip to content

Commit

Permalink
Merge branch 'master' into master
Browse files Browse the repository at this point in the history
  • Loading branch information
Abeeujah authored Nov 4, 2024
2 parents 930f542 + 431eab1 commit 121accd
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 6 deletions.
1 change: 0 additions & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,6 @@ ansi_term = "0.12"
anyhow = "1.0"
assert-json-diff = "2.0"
async-trait = "0.1"
atty = "0.2"
aws-config = "1.5"
aws-sdk-kms = "1.44"
byte-unit = "5.1"
Expand Down
1 change: 0 additions & 1 deletion forc-plugins/forc-crypto/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ repository.workspace = true
[dependencies]
anyhow.workspace = true
async-trait.workspace = true
atty.workspace = true
clap = { workspace = true, features = ["derive", "env"] }
forc-tracing.workspace = true
forc-util.workspace = true
Expand Down
5 changes: 2 additions & 3 deletions forc-plugins/forc-crypto/src/main.rs
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
//! A `forc` plugin for converting a given string or path to their hash.
use anyhow::Result;
use atty::Stream;
use clap::Parser;
use forc_crypto::{address, keccak256, keys, sha256, Command};
use forc_tracing::{init_tracing_subscriber, println_error};
use std::{
default::Default,
io::{stdin, stdout, Read, Write},
io::{stdin, stdout, IsTerminal, Read, Write},
};
use termion::screen::IntoAlternateScreen;

Expand Down Expand Up @@ -53,7 +52,7 @@ pub fn display_output<T>(message: T) -> anyhow::Result<()>
where
T: serde::Serialize,
{
if atty::is(Stream::Stdout) {
if stdout().is_terminal() {
let text = serde_yaml::to_string(&message).expect("valid string");
if has_sensible_info(&message) {
let mut screen = stdout().into_alternate_screen()?;
Expand Down

0 comments on commit 121accd

Please sign in to comment.