Coder Social home page Coder Social logo

rbchunk's Introduction

BinChunker in Rust

As the title says this is basically bchunk written in Rust, it has all the same features as the original and some improvements. Mainly in some cases it's easier to use and it's slightly faster (noticable only on RAM disk or fast SSD as storage still remains the biggest bottleneck).

This adds support for rbchunk to be a library that can be imported by other projects, based on https://gitlab.com/TheMaxus/rbchunk.git. An example cli tool can be seen in examples/cli.rs

How to use

Basic usage (after building example):

rbchunk [-w] [-s] foo.cue

If only one file is supplied the program will treat it as a CUE file.

This will extract tracks from the .bin file specified in CUE sheet to the current directory with names like foo01.cdr. -w switch will extract files in .wav format and -s flag will switch byte order (use this if you get white noise or otherwise corrupted audio in the output files).

rbchunk [-ws] foo.bin foo.cue [something]

This will do the same as above but you can specify the BIN file and output name.

If two or three files are supplied first will always be treated as BIN file, second as CUE file and third as a filename for the output. Any other arguments will be ignored.

Basic usage as library:

let args = read_args(); // Providing your own rbchunk::Args here
match rbchunk::convert(args) {
    Ok(()) => println!("Conversion complete!"),
    Err(err) => {
        println!("Error on conversion: {}", err);
        process::exit(1);
    }
}

Contribution

Feel free to contribute to the project, but try to avoid any external dependencies, as I try to keep this program rather small.

Compillation

  • git clone https://github.com/luxtorpeda-dev/rbchunk
  • cargo build -r

Releasing a New Version

  • First make sure all pull requests have been merged that are wanted for the release. Then git pull on the master branch.
  • Make sure cargo-release is installed locally cargo install cargo-release (https://github.com/crate-ci/cargo-release)
  • Run cargo release version major to do a dry run of the version update. Can also use minor, patch, etc
  • Run again if dry run successful: cargo release version major --execute. Make sure to commit & push to git if needed.
  • Run cargo release to do a dry run of the release.
  • Run cargo release --execute if dry run successful. This step will push the git tags and a github action will run to publish the new version to crate.

Credits

This program is mostly based on bchunk by Heikki Hannikainen [email protected],
which in turn is based on BinChunker by Bob Marietta [email protected]

Other contributors to bchunk:

rbchunk's People

Contributors

d10sfan avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.