Commit graph

63 commits

Author SHA1 Message Date
John Wiegley
9ec9cdf41e Started writing Python unit tests 2012-03-01 05:50:07 -06:00
John Wiegley
e2afc783db Increased file copyrights to 2012 2012-02-29 22:32:23 -06:00
John Wiegley
36922c5945 Whitespace fixes 2012-02-21 03:44:34 -06:00
John Wiegley
8388baafd3 Support Boost 1.46 and Boost.Filesystem v3 2011-02-28 16:24:15 -05:00
John Wiegley
968a6f3c0a Changes for building with Visual Studio 2008 2010-06-15 05:14:00 -04:00
John Wiegley
dea2aed0b5 Untabified all source files 2010-06-11 17:02:25 -04:00
John Wiegley
ab416f759f Updated copyrights to 2003-2010 2010-03-05 22:14:10 -05:00
John Wiegley
a51b7ec4fa Construct global_scope object within the exception handler 2009-10-31 04:07:41 -04:00
John Wiegley
feff681f44 Improved argument parsing logic used by the REPL
It now handles quoted strings, although it doesn't understand escape
sequences yet.
2009-10-26 17:17:01 -04:00
John Wiegley
110f0b8023 Enabled use of pre-compiled headers by default 2009-03-10 17:02:03 -04:00
John Wiegley
c99ab20853 Fixed a few minor cases of uninitialized variables 2009-03-08 02:07:49 -04:00
John Wiegley
c11d325712 Reduced the #include dependency tree to a minimum 2009-03-04 23:53:43 -04:00
John Wiegley
dcac306467 Corrected a build error if Python support missing 2009-03-03 22:13:36 -04:00
John Wiegley
edf1ccd6ab Added a "python" command, which invokes Py_Main 2009-03-03 14:39:07 -04:00
John Wiegley
238bd7f8a5 Marked all strings needing internationalization
These strings are now collected automagically in the file po/ledger.pot.
If you'd like to produce a translation, just run this command after
building Ledger:

    msginit -l LOCALE -o LANG.po -i po/ledger.pot

Where LOCALE is a string like de or en_GB, and LANG is a short
descriptive word for your language.

Then send me this .po file so I can commit it to the Ledger sources
(alternatively, you could maintain the file in a fork on GitHub), and
setup the build script to format and install your new message catalog
during a "make install".
2009-02-25 03:51:42 -04:00
John Wiegley
72a5e972c7 Always free memory at the end of a run
It turns out this is needed in order to properly close the pager
subprocess.
2009-02-23 17:28:13 -04:00
John Wiegley
3c5b5fbc0a Fix for systems that don't build with gettext 2009-02-22 01:40:45 -04:00
John Wiegley
b902894284 Added support for using GNU gettext 2009-02-21 20:21:13 -04:00
John Wiegley
bc2983928d Compilation verification code only with debugging
Previously, --verify would work even if the sources were built with
default options.  However, in the interests of performance, --verify is
now only available if --enable-debug was passed to configure.
2009-02-16 17:15:52 -04:00
John Wiegley
d0a664d102 Fixed several unused value and param warnings 2009-02-16 16:55:18 -04:00
John Wiegley
70344b82e7 Added a "reload" command, for use at the REPL
Created a new function, session_t::reread_journal_files, which throws
away all previous state data and reads in the same files again.  This is
needed to allow Emacs to communicate with Ledger via the REPL, so that
it tell Ledger when it has made changes to the user's data file.
2009-02-13 05:24:28 -04:00
John Wiegley
4f5799c216 If a ledger file is specified in .ledgerrc, ignore the environment. 2009-02-08 19:54:39 -04:00
John Wiegley
cf6babcf90 Restored all the option handlers from 2.6.2, but not the options themselves. 2009-02-06 03:31:41 -04:00
John Wiegley
408b819c6e Greatly simplified the way option and command handlers are defined. 2009-02-05 21:20:09 -04:00
John Wiegley
edb9cff4a2 Moved work.cc and global_scope_t into a new global.cc file. 2009-02-05 04:20:49 -04:00
John Wiegley
0e2a3a9c00 Moved much of the main.cc code into a new global_scope_t class. 2009-02-05 04:06:58 -04:00
John Wiegley
37006741d6 Support using Ledger as a script interpretor.
The file must begin with '#!/usr/bin/env ledger --script'.  You can add a -f
option to the options, but it must come before --script.
2009-02-05 03:49:49 -04:00
John Wiegley
c58cd88299 Reworked how the REPL is handled. 2009-02-05 02:45:26 -04:00
John Wiegley
863b5d8144 Added proper handling of SIGINT (C-c) and SIGPIPE (pager quits). 2009-02-04 20:46:08 -04:00
John Wiegley
796feb2634 Added code to quit more gracefully. Ctrl-C still needs work. 2009-02-04 20:11:27 -04:00
John Wiegley
ea1e898eec Minor fixes to the REPL when using libedit. 2009-02-04 19:58:56 -04:00
John Wiegley
73cf3b01fb Added structural support in main() for using a REPL. 2009-02-04 19:55:08 -04:00
John Wiegley
43c4636d9d Removed the global references to session->report. 2009-02-03 13:03:10 -04:00
John Wiegley
3434650848 Removed the binary caching code, and the XML, QIF and Gnucash parsers. 2009-02-03 12:22:10 -04:00
John Wiegley
177b5adc98 Added a comment. 2009-02-03 00:48:01 -04:00
John Wiegley
ad34a71646 Corrected a display error when showing error context. 2009-02-03 00:45:14 -04:00
John Wiegley
c1cb06e009 Updated some internal documentation. 2009-02-02 15:54:28 -04:00
John Wiegley
cf9b4a3873 Removed report_error() function and reordered context for parsing errors. 2009-02-02 15:16:18 -04:00
John Wiegley
9540406af1 Simplified error context handling. 2009-02-02 00:24:26 -04:00
John Wiegley
559a76ac2b Fixed the way the pager process was being handled. 2009-02-01 01:47:06 -04:00
John Wiegley
9d267fa133 Inspired by Omari Norman, I've rewritten main.cc so it's easy to approach. 2009-01-31 18:52:34 -04:00
John Wiegley
b027961b96 Removed unnecessary #ifdef block. pyinterp.h now guards itself. 2009-01-31 16:04:21 -04:00
John Wiegley
cdb123974c Created a new stream.h file for dealing with output streaming. 2009-01-30 00:40:46 -04:00
John Wiegley
a69649fb7f Switched over to using irrxml for parsing XML, rather than expat. 2009-01-24 04:49:58 -04:00
John Wiegley
59a71e7d74 Changed grammatical tense in two tracing statements. 2009-01-23 15:45:17 -04:00
John Wiegley
617dd0c261 When Python support is present, use a session_t object which is derived from
python_interpreter_t, so that Python can provide value expression definitions.
2009-01-23 01:53:19 -04:00
John Wiegley
c2761f4e90 Moved the occurance of "Error:" when reporting context. 2009-01-22 21:17:16 -04:00
John Wiegley
6fbf5c551e Made the output from parse/compile commands more consistent. 2009-01-22 21:16:57 -04:00
John Wiegley
2332896810 Changed some debug strings when parsing/compiling valexprs. 2009-01-22 18:51:33 -04:00
John Wiegley
0b9f22b4d2 Redid the way command-line arguments are processed. Before, Ledger used - and
-- to mean special things after the command verb was seen.  But now, what used
to be specified as this:

  ledger -n reg cash -payable -- shell

Is now specified as this:

  ledger reg -n cash not payable @shell

It could also be specified as:

  ledger -n reg \(cash and not payable\) and @shell
2009-01-22 16:27:24 -04:00