Skip to content

Commit

Permalink
Remove warning
Browse files Browse the repository at this point in the history
  • Loading branch information
ryuichiueda committed Oct 18, 2024
1 parent 7f16744 commit cc86e20
Show file tree
Hide file tree
Showing 9 changed files with 475 additions and 333 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[dependencies]
nix = { version = "0.28.0", features = ["fs", "process", "signal", "term", "user"]}
nix = { version = "0.28.0", features = ["fs", "process", "signal", "term", "user", "hostname"]}
termion = "4.0.3"
unicode-width = "0.1.11"
signal-hook = "0.3.17"
Expand Down
2 changes: 1 addition & 1 deletion src/elements/word.rs
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ impl Word {
.collect()
}

fn make_unquoted_word(&mut self) -> Option<String> {
pub fn make_unquoted_word(&mut self) -> Option<String> {
let sw: Vec<Option<String>> = self.subwords.iter_mut()
.map(|s| s.make_unquoted_string()) //""や''はNoneにならずに空文字として残る
.filter(|s| *s != None)
Expand Down
8 changes: 3 additions & 5 deletions src/feeder.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
//SPDX-FileCopyrightText: 2022 Ryuichi Ueda ryuichiueda@gmail.com
//SPDX-License-Identifier: BSD-3-Clause

mod term;
mod terminal;
mod scanner;

use std::io;
Expand Down Expand Up @@ -78,8 +78,7 @@ impl Feeder {
}

let line = if core.has_flag('i') {
let len_prompt = term::prompt_additional();
term::read_line_terminal(len_prompt, core)
terminal::read_line(core, "PS2")
}else{
Self::read_line_stdin()
};
Expand Down Expand Up @@ -111,8 +110,7 @@ impl Feeder {

pub fn feed_line(&mut self, core: &mut ShellCore) -> Result<(), InputError> {
let line = if core.has_flag('i') {
let len_prompt = term::prompt_normal(core);
term::read_line_terminal(len_prompt, core)
terminal::read_line(core, "PS1")
}else{
Self::read_line_stdin()
};
Expand Down
326 changes: 0 additions & 326 deletions src/feeder/term.rs

This file was deleted.

Loading

0 comments on commit cc86e20

Please sign in to comment.