Code Monkey home page Code Monkey logo

binasc's Issues

CLI flag documentation slightly confusing/contradictory

./binasc and ./binasc --help show inaccurate information

For converting/compiling a binary file to/from an ASCII listing of
individual bytes of the file.

Usage: ./binasc [-a | -b | -c output] input(s)

Options:
   -a = output only non-space printable ASCII words
   -b = output only hexadecimal ASCII numbers for each byte
   -c output = compiled binary file using ASCII number of input
   -m = display the man page for the program
   no options = combination of -a and -b options.
   --options  = list of all options, aliases and defaults

At least the -m option here is wrong.

./binasc --HELP displays the correct information

a|ascii=b	Display only printable ASCII characters.
b|binary|bytes=b	Display only byte hex codes.
c|compile=s:	Compile ASCII file into binary form.
h|man|manual=b	Print the manual.
m|midi=b	Display MIDI files in ASCII form.
M|MIDI=b	Display MIDI files with comments.
mod=i:25	Number of hex codes on a line.
wrap=i:75	Number of characters on line for -a option
author=b	Author of the program.
version=b	Version of the program.
example=b	Example usage of the program.
help=b

Also, the wiki page doesn't document --MIDI

New Line character, on windows, will result in New Line and Carriege Return

Follow those steps:
1. Put in an input text file the <New Line> character, in hex (0x0A) or dec 
(10);
2. Run the following "binasc input -c output";
3. Each <New Line> char, will result in a <New Line> + <Carriage Return>;

Should be only the <New Line> char, not <New Line> and <Carriage Return>

Version:
Windows version from revision "fa1f0aec6e41".

The solution is to open the "ouput" file in binary mode, not in text mode.

Original issue reported on code.google.com by g.gabriel88 on 2 Feb 2015 at 8:19

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.