mirror of
https://github.com/RGBCube/uutils-coreutils
synced 2025-07-28 11:37:44 +00:00
Fix master by removing extra crate,
and using max method for comparing floats
This commit is contained in:
parent
a75e42d4db
commit
786b39019b
21 changed files with 1 additions and 23 deletions
|
@ -10,7 +10,6 @@
|
||||||
* file that was distributed with this source code.
|
* file that was distributed with this source code.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
extern crate extra;
|
|
||||||
extern crate getopts;
|
extern crate getopts;
|
||||||
|
|
||||||
use std::io::{print, println};
|
use std::io::{print, println};
|
||||||
|
|
|
@ -12,7 +12,6 @@
|
||||||
|
|
||||||
/* last synced with: cat (GNU coreutils) 8.13 */
|
/* last synced with: cat (GNU coreutils) 8.13 */
|
||||||
|
|
||||||
extern crate extra;
|
|
||||||
extern crate getopts;
|
extern crate getopts;
|
||||||
|
|
||||||
use std::os;
|
use std::os;
|
||||||
|
|
|
@ -9,7 +9,6 @@
|
||||||
* file that was distributed with this source code.
|
* file that was distributed with this source code.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
extern crate extra;
|
|
||||||
extern crate getopts;
|
extern crate getopts;
|
||||||
|
|
||||||
use std::os;
|
use std::os;
|
||||||
|
|
|
@ -10,7 +10,6 @@
|
||||||
* file that was distributed with this source code.
|
* file that was distributed with this source code.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
extern crate extra;
|
|
||||||
extern crate getopts;
|
extern crate getopts;
|
||||||
|
|
||||||
use std::os;
|
use std::os;
|
||||||
|
|
|
@ -10,7 +10,6 @@
|
||||||
* Synced with: https://raw.github.com/avsm/src/master/usr.bin/head/head.c
|
* Synced with: https://raw.github.com/avsm/src/master/usr.bin/head/head.c
|
||||||
*/
|
*/
|
||||||
|
|
||||||
extern crate extra;
|
|
||||||
extern crate getopts;
|
extern crate getopts;
|
||||||
|
|
||||||
use std::os;
|
use std::os;
|
||||||
|
|
|
@ -12,7 +12,6 @@
|
||||||
* https://www.opensource.apple.com/source/shell_cmds/shell_cmds-170/hostname/hostname.c?txt
|
* https://www.opensource.apple.com/source/shell_cmds/shell_cmds-170/hostname/hostname.c?txt
|
||||||
*/
|
*/
|
||||||
|
|
||||||
extern crate extra;
|
|
||||||
extern crate getopts;
|
extern crate getopts;
|
||||||
|
|
||||||
use std::{os,libc,vec,str};
|
use std::{os,libc,vec,str};
|
||||||
|
|
|
@ -15,7 +15,6 @@
|
||||||
|
|
||||||
#[feature(macro_rules)];
|
#[feature(macro_rules)];
|
||||||
|
|
||||||
extern crate extra;
|
|
||||||
extern crate getopts;
|
extern crate getopts;
|
||||||
|
|
||||||
use std::io::{print, println};
|
use std::io::{print, println};
|
||||||
|
|
|
@ -11,7 +11,6 @@
|
||||||
|
|
||||||
#[feature(macro_rules)];
|
#[feature(macro_rules)];
|
||||||
|
|
||||||
extern crate extra;
|
|
||||||
extern crate getopts;
|
extern crate getopts;
|
||||||
|
|
||||||
use std::os;
|
use std::os;
|
||||||
|
|
|
@ -13,7 +13,6 @@
|
||||||
|
|
||||||
#[feature(macro_rules)];
|
#[feature(macro_rules)];
|
||||||
|
|
||||||
extern crate extra;
|
|
||||||
extern crate getopts;
|
extern crate getopts;
|
||||||
|
|
||||||
use std::os;
|
use std::os;
|
||||||
|
|
|
@ -11,7 +11,6 @@
|
||||||
|
|
||||||
#[feature(macro_rules)];
|
#[feature(macro_rules)];
|
||||||
|
|
||||||
extern crate extra;
|
|
||||||
extern crate getopts;
|
extern crate getopts;
|
||||||
|
|
||||||
use std::os;
|
use std::os;
|
||||||
|
|
1
rm/rm.rs
1
rm/rm.rs
|
@ -11,7 +11,6 @@
|
||||||
|
|
||||||
#[feature(macro_rules)];
|
#[feature(macro_rules)];
|
||||||
|
|
||||||
extern crate extra;
|
|
||||||
extern crate getopts;
|
extern crate getopts;
|
||||||
|
|
||||||
use std::os;
|
use std::os;
|
||||||
|
|
|
@ -11,7 +11,6 @@
|
||||||
|
|
||||||
#[feature(macro_rules)];
|
#[feature(macro_rules)];
|
||||||
|
|
||||||
extern crate extra;
|
|
||||||
extern crate getopts;
|
extern crate getopts;
|
||||||
|
|
||||||
use std::os;
|
use std::os;
|
||||||
|
|
|
@ -5,11 +5,9 @@
|
||||||
// TODO: Make -w flag work with decimals
|
// TODO: Make -w flag work with decimals
|
||||||
// TODO: Support -f flag
|
// TODO: Support -f flag
|
||||||
|
|
||||||
extern crate extra;
|
|
||||||
extern crate getopts;
|
extern crate getopts;
|
||||||
|
|
||||||
use std::os;
|
use std::os;
|
||||||
use std::cmp::max;
|
|
||||||
|
|
||||||
#[path = "../common/util.rs"]
|
#[path = "../common/util.rs"]
|
||||||
mod util;
|
mod util;
|
||||||
|
@ -99,7 +97,7 @@ fn done_printing(next: f32, step: f32, last: f32) -> bool {
|
||||||
|
|
||||||
fn print_seq(first: f32, step: f32, last: f32, separator: ~str, terminator: ~str, pad: bool) {
|
fn print_seq(first: f32, step: f32, last: f32, separator: ~str, terminator: ~str, pad: bool) {
|
||||||
let mut i = first;
|
let mut i = first;
|
||||||
let maxlen = max(first, last).to_str().len();
|
let maxlen = first.max(last).to_str().len();
|
||||||
while !done_printing(i, step, last) {
|
while !done_printing(i, step, last) {
|
||||||
let ilen = i.to_str().len();
|
let ilen = i.to_str().len();
|
||||||
if pad && ilen < maxlen {
|
if pad && ilen < maxlen {
|
||||||
|
|
|
@ -11,7 +11,6 @@
|
||||||
|
|
||||||
#[feature(macro_rules)];
|
#[feature(macro_rules)];
|
||||||
|
|
||||||
extern crate extra;
|
|
||||||
extern crate getopts;
|
extern crate getopts;
|
||||||
|
|
||||||
use std::num;
|
use std::num;
|
||||||
|
|
|
@ -10,7 +10,6 @@
|
||||||
* file that was distributed with this source code.
|
* file that was distributed with this source code.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
extern crate extra;
|
|
||||||
extern crate getopts;
|
extern crate getopts;
|
||||||
|
|
||||||
use std::io::{println, stdin, stdout, Append, File, Truncate, Write};
|
use std::io::{println, stdin, stdout, Append, File, Truncate, Write};
|
||||||
|
|
|
@ -11,7 +11,6 @@
|
||||||
|
|
||||||
#[feature(macro_rules)];
|
#[feature(macro_rules)];
|
||||||
|
|
||||||
extern crate extra;
|
|
||||||
extern crate getopts;
|
extern crate getopts;
|
||||||
|
|
||||||
use std::io::{File, Open, ReadWrite, fs};
|
use std::io::{File, Open, ReadWrite, fs};
|
||||||
|
|
|
@ -16,7 +16,6 @@
|
||||||
|
|
||||||
#[feature(macro_rules)];
|
#[feature(macro_rules)];
|
||||||
|
|
||||||
extern crate extra;
|
|
||||||
extern crate getopts;
|
extern crate getopts;
|
||||||
|
|
||||||
use std::{libc,str,os};
|
use std::{libc,str,os};
|
||||||
|
|
|
@ -16,7 +16,6 @@
|
||||||
|
|
||||||
#[feature(macro_rules, globs)];
|
#[feature(macro_rules, globs)];
|
||||||
|
|
||||||
extern crate extra;
|
|
||||||
extern crate getopts;
|
extern crate getopts;
|
||||||
|
|
||||||
use std::io::print;
|
use std::io::print;
|
||||||
|
|
1
wc/wc.rs
1
wc/wc.rs
|
@ -11,7 +11,6 @@
|
||||||
|
|
||||||
#[feature(macro_rules)];
|
#[feature(macro_rules)];
|
||||||
|
|
||||||
extern crate extra;
|
|
||||||
extern crate getopts;
|
extern crate getopts;
|
||||||
|
|
||||||
use std::os;
|
use std::os;
|
||||||
|
|
|
@ -15,7 +15,6 @@
|
||||||
|
|
||||||
#[feature(macro_rules)];
|
#[feature(macro_rules)];
|
||||||
|
|
||||||
extern crate extra;
|
|
||||||
extern crate getopts;
|
extern crate getopts;
|
||||||
|
|
||||||
use std::io::print;
|
use std::io::print;
|
||||||
|
|
|
@ -13,7 +13,6 @@
|
||||||
|
|
||||||
#[feature(macro_rules)];
|
#[feature(macro_rules)];
|
||||||
|
|
||||||
extern crate extra;
|
|
||||||
extern crate getopts;
|
extern crate getopts;
|
||||||
|
|
||||||
use std::os;
|
use std::os;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue