Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion src/uu/stdbuf/locales/en-US.ftl
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ stdbuf-value-mode = MODE
stdbuf-error-line-buffering-stdin-meaningless = line buffering stdin is meaningless
stdbuf-error-invalid-mode = invalid mode {$error}
stdbuf-error-value-too-large = invalid mode '{$value}': Value too large for defined data type
stdbuf-error-command-not-supported = Command not supported for this operating system!
stdbuf-error-external-libstdbuf-not-found = External libstdbuf not found at configured path: {$path}
stdbuf-error-permission-denied = failed to execute process: Permission denied
stdbuf-error-no-such-file = failed to execute process: No such file or directory
Expand Down
1 change: 0 additions & 1 deletion src/uu/stdbuf/locales/fr-FR.ftl
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ stdbuf-value-mode = MODE
stdbuf-error-line-buffering-stdin-meaningless = la mise en mémoire tampon par ligne de stdin n'a pas de sens
stdbuf-error-invalid-mode = mode invalide {$error}
stdbuf-error-value-too-large = mode invalide '{$value}' : Valeur trop grande pour le type de données défini
stdbuf-error-command-not-supported = Commande non prise en charge pour ce système d'exploitation !
stdbuf-error-external-libstdbuf-not-found = libstdbuf externe introuvable au chemin configuré : {$path}
stdbuf-error-permission-denied = échec de l'exécution du processus : Permission refusée
stdbuf-error-no-such-file = échec de l'exécution du processus : Aucun fichier ou répertoire de ce type
Expand Down
18 changes: 2 additions & 16 deletions src/uu/stdbuf/src/stdbuf.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
// file that was distributed with this source code.

// spell-checker:ignore (ToDO) tempdir dyld dylib optgrps libstdbuf
#[cfg(not(unix))]
compile_error!("stdbuf is not supported on the target");

use clap::{Arg, ArgAction, ArgMatches, Command};
use std::ffi::OsString;
Expand Down Expand Up @@ -107,22 +109,6 @@ fn preload_strings() -> UResult<(&'static str, &'static str)> {
Ok(("DYLD_LIBRARY_PATH", "dylib"))
}

#[cfg(not(any(
target_os = "linux",
target_os = "android",
target_os = "freebsd",
target_os = "netbsd",
target_os = "openbsd",
target_os = "dragonfly",
target_vendor = "apple"
)))]
fn preload_strings() -> UResult<(&'static str, &'static str)> {
Err(USimpleError::new(
1,
translate!("stdbuf-error-command-not-supported"),
))
}

fn check_option(matches: &ArgMatches, name: &str) -> Result<BufferType, ProgramOptionsError> {
match matches.get_one::<String>(name) {
Some(value) => match value.as_str() {
Expand Down
Loading