Fetching latest commit…
Cannot retrieve the latest commit at this time
|Failed to load latest commit information.|
================================================================================ Cecho - An ncurses library for Erlang ================================================================================ This README file sucks because there is virtually nothing here. Please find the github page on: http://... Contact: blog: http://mazenharake.wordpress.com IRC: #erlang on freenode ML: www.erlang.org/faq.html License: Copyright (c) 2010, Mazen Harake All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. * Neither the name of the <ORGANIZATION> nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. Compiling: Before you compile you have to set a few values in the Makefile. Currently there are no automatic detection of the Erlang erts or the include files. This is planned in future releases. I'm not _very_ familiar with Makefiles yet but I'm sure this can be achieved in some otherway. For now just do the following: 1) Change ERLDIR variable to point to the erlang directory E.g. "/usr/local/lib/erlang/" 2) Change the version numbers for the erts-xxx and erl_interface-xxx 3) make Note: Make sure you have ncurses dev libraries installed (you should already have them if you compiled erlang on the same machine). Note2: The file cecho_commands.hrl is _generated_ it is not suppose to exist in the include directory. Usage: The intention of this library is to have an API as close as possible to the ncurses library. Something things can't be translated and other things return values instead of taking pointer arguments etc. Documentation is planned ASAP. Examples: There are several ways to run the examples but the easiest would be to run erl from the root directory of cecho and then invoke the M:F(A). from the shell. When possible the application should be run with -noshell. If you want to read key input then use io:get_chars("",X) where X is the number of characters you want to read (usually 1). Oh and don't use -noinput if you want to read input ;) NOTE: The '../cecho/ebin' is necessary for the code:priv_dir/1 to work because it needs to do some fancy stuff on any path you enter. When ever this library is used the path has to include at least "SOMEPATH/cecho/ebin". E.g: $> erl -pa ../cecho/ebin Erlang (BEAM) emulator version 5.6.5 [source] [async-threads:0] [kernel-poll:false] Eshell V5.6.5 (abort with ^G) 1> cecho_example:simple(). =INFO REPORT==== 15-Feb-2010::17:22:46 === application: cecho exited: stopped type: temporary ok 2> OR even better: $> erl -pa ../cecho/ebin/ -noshell -eval 'cecho_example:input(),halt().'