#!/usr/bin/perl
# $Id: listos,v 1.6 1994/10/27 12:16:01 cbbrowne Exp $
#  Written by Christopher B. Browne
#
#  Copyright (C) 1994  Christopher B. Browne cbrowne@io.org
#
#  This program is free software; you can redistribute it and/or modify
#  it under the terms of the GNU General Public License as published by
#  the Free Software Foundation; either version 2 of the License, or
#  (at your option) any later version.
#
#  This program is distributed in the hope that it will be useful,
#  but WITHOUT ANY WARRANTY; without even the implied warranty of
#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#  GNU General Public License for more details.
#
#  You should have received a copy of the GNU General Public License
#  along with this program; if not, write to the Free Software
#  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
require "cbbshutils.pl";
$name = shift(@ARGV); $name =~ tr/A-Z/a-z/;

system "buildos $name";
print "Listing Outstanding Transactions for Account [$name]\n";
&need_txn($name);
&need_os($name);
&need_bal($name);

@LIST = &construct_sorted_os_list();

foreach $ky (0..$#LIST) { 
    $v1 = $OSLIST{$LIST[$ky]};
    $v2 = $TXNS{$v1};
    $value = $v2;
    &listtxn($ky, $value);
} 
&list_bals();
