Release 0.1.0

This commit is contained in:
Luke Street 2021-08-23 11:11:56 -04:00
parent d7279f50de
commit 1e60c551e1
3 changed files with 4 additions and 9 deletions

View File

@ -10,14 +10,13 @@ readme = "README.md"
description = """ description = """
Rust library and CLI tool for reading GameCube and Wii disc images. Rust library and CLI tool for reading GameCube and Wii disc images.
""" """
keywords = ["gamecube", "wii", "iso", "nfs", "gcm"]
categories = ["command-line-utilities", "parser-implementations"]
[[bin]] [[bin]]
name = "nodtool" name = "nodtool"
path = "src/bin.rs" path = "src/bin.rs"
[profile.release]
lto = true
[dependencies] [dependencies]
aes = "0.7.4" aes = "0.7.4"
binread = "2.1.1" binread = "2.1.1"

View File

@ -1,4 +1,4 @@
# nod-rs [![Build Status]][actions] [![Latest Version]][crates.io] [![Api Rustdoc]][rustdoc] [![Rust](https://img.shields.io/badge/rust-1.51%2B-blue.svg?maxAge=3600)](https://github.com/eqrion/cbindgen) # nod-rs [![Build Status]][actions] [![Latest Version]][crates.io] [![Api Rustdoc]][rustdoc] [![Rust](https://img.shields.io/badge/rust-1.51%2B-blue.svg?maxAge=3600)](https://github.com/encounter/nod-rs)
[Build Status]: https://github.com/encounter/nod-rs/workflows/build/badge.svg [Build Status]: https://github.com/encounter/nod-rs/workflows/build/badge.svg
[actions]: https://github.com/encounter/nod-rs/actions [actions]: https://github.com/encounter/nod-rs/actions

View File

@ -1,7 +1,6 @@
use std::{env, fs, io}; use std::{env, fs, io};
use std::io::BufWriter; use std::io::BufWriter;
use std::path::{Path, PathBuf}; use std::path::{Path, PathBuf};
use std::time::Instant;
use clap::{AppSettings, clap_app}; use clap::{AppSettings, clap_app};
use file_size; use file_size;
@ -67,13 +66,10 @@ fn extract_node(node: &NodeType, partition: &mut dyn PartReadStream, base_path:
NodeType::File(v) => { NodeType::File(v) => {
let mut file_path = base_path.to_owned(); let mut file_path = base_path.to_owned();
file_path.push(v.name.as_ref()); file_path.push(v.name.as_ref());
print!("Extracted {}", file_path.to_string_lossy()); println!("Extracting {} (size: {})", file_path.to_string_lossy(), file_size::fit_4(v.length as u64));
let now = Instant::now();
let file = fs::File::create(file_path)?; let file = fs::File::create(file_path)?;
let mut buf_writer = BufWriter::with_capacity(partition.ideal_buffer_size(), file); let mut buf_writer = BufWriter::with_capacity(partition.ideal_buffer_size(), file);
io::copy(&mut partition.begin_file_stream(v)?, &mut buf_writer)?; io::copy(&mut partition.begin_file_stream(v)?, &mut buf_writer)?;
let elapsed = now.elapsed();
println!(" (time: {:.2?}, size: {})", elapsed, file_size::fit_4(v.length as u64));
} }
NodeType::Directory(v, c) => { NodeType::Directory(v, c) => {
if v.name.is_empty() { if v.name.is_empty() {