You are viewing a plain text version of this content. The canonical link for it is here.
Posted to rivet-dev@tcl.apache.org by mx...@apache.org on 2011/12/27 01:20:36 UTC
svn commit: r1224843 - in /tcl/rivet/trunk: ChangeLog
rivet/rivet-tcl/putsnnl.tcl rivet/rivet-tcl/tclIndex
Author: mxmanghi
Date: Tue Dec 27 00:20:36 2011
New Revision: 1224843
URL: http://svn.apache.org/viewvc?rev=1224843&view=rev
Log:
2011-12-26 Massimo Manghi <mx...@apache.org>
* rivet/rivet-tcl/putsnnl.tcl: Add new command 'putsnnl', a wrapper for
'puts -nonewline' with the extra optional feature of prepending the output
with a definite number of spaces (it helps pretty printing of HTML)
Added:
tcl/rivet/trunk/rivet/rivet-tcl/putsnnl.tcl
Modified:
tcl/rivet/trunk/ChangeLog
tcl/rivet/trunk/rivet/rivet-tcl/tclIndex
Modified: tcl/rivet/trunk/ChangeLog
URL: http://svn.apache.org/viewvc/tcl/rivet/trunk/ChangeLog?rev=1224843&r1=1224842&r2=1224843&view=diff
==============================================================================
--- tcl/rivet/trunk/ChangeLog (original)
+++ tcl/rivet/trunk/ChangeLog Tue Dec 27 00:20:36 2011
@@ -1,3 +1,8 @@
+2011-12-26 Massimo Manghi <mx...@apache.org>
+ * rivet/rivet-tcl/putsnnl.tcl: Add new command 'putsnnl', a wrapper for
+ 'puts -nonewline' with the extra optional feature of prepending the output
+ with a definite number of spaces (it helps pretty printing of HTML)
+
2011-12-09 Massimo Manghi <mx...@apache.org>
* src/rivetPkgInit.c,src/parserPkgInit.c: libs now are fully based on stubs and
the tcl version parameter passed with Tcl_InitStubs is the same Tcl version their
Added: tcl/rivet/trunk/rivet/rivet-tcl/putsnnl.tcl
URL: http://svn.apache.org/viewvc/tcl/rivet/trunk/rivet/rivet-tcl/putsnnl.tcl?rev=1224843&view=auto
==============================================================================
--- tcl/rivet/trunk/rivet/rivet-tcl/putsnnl.tcl (added)
+++ tcl/rivet/trunk/rivet/rivet-tcl/putsnnl.tcl Tue Dec 27 00:20:36 2011
@@ -0,0 +1,18 @@
+##
+## putsnnl <string> <nspaces>
+##
+## Shorthand for 'puts -nonewline' with the extra feature
+## of being able to output a string prepended with <nspaces>
+##
+## $Id: $
+##
+
+namespace eval ::rivet {
+ proc putsnnl {s {spaces 0}} {
+
+ puts -nonewline [string repeat " " $spaces]
+ puts -nonewline $s
+
+ }
+}
+##
Modified: tcl/rivet/trunk/rivet/rivet-tcl/tclIndex
URL: http://svn.apache.org/viewvc/tcl/rivet/trunk/rivet/rivet-tcl/tclIndex?rev=1224843&r1=1224842&r2=1224843&view=diff
==============================================================================
--- tcl/rivet/trunk/rivet/rivet-tcl/tclIndex (original)
+++ tcl/rivet/trunk/rivet/rivet-tcl/tclIndex Tue Dec 27 00:20:36 2011
@@ -6,22 +6,23 @@
# element name is the name of a command and the value is
# a script that loads the command.
-set auto_index(::rivet::html) [list source [file join $dir html.tcl]]
-set auto_index(::rivet::lassign) [list source [file join $dir lassign.tcl]]
+set auto_index(::rivet::lempty) [list source [file join $dir lempty.tcl]]
+set auto_index(::rivet::load_response) [list source [file join $dir load_response.tcl]]
set auto_index(::rivet::random) [list source [file join $dir random.tcl]]
+set auto_index(::rivet::import_switch_args) [list source [file join $dir import_switch_args.tcl]]
set auto_index(::rivet::rivet_command_document) [list source [file join $dir rivet_command_document.tcl]]
-set auto_index(::rivet::load_response) [list source [file join $dir load_response.tcl]]
+set auto_index(::rivet::html) [list source [file join $dir html.tcl]]
+set auto_index(::rivet::load_cookies) [list source [file join $dir load_cookies.tcl]]
set auto_index(::rivet::debug) [list source [file join $dir debug.tcl]]
+set auto_index(::rivet::lassign) [list source [file join $dir lassign.tcl]]
+set auto_index(::rivet::import_keyvalue_pairs) [list source [file join $dir import_keyvalue_pairs.tcl]]
+set auto_index(::rivet::read_file) [list source [file join $dir read_file.tcl]]
+set auto_index(::rivet::lmatch) [list source [file join $dir lmatch.tcl]]
set auto_index(::rivet::clock_to_rfc850_gmt) [list source [file join $dir cookie.tcl]]
set auto_index(::rivet::make_cookie_attributes) [list source [file join $dir cookie.tcl]]
set auto_index(::rivet::cookie) [list source [file join $dir cookie.tcl]]
-set auto_index(::rivet::lempty) [list source [file join $dir lempty.tcl]]
-set auto_index(::rivet::import_switch_args) [list source [file join $dir import_switch_args.tcl]]
-set auto_index(::rivet::lmatch) [list source [file join $dir lmatch.tcl]]
-set auto_index(::rivet::read_file) [list source [file join $dir read_file.tcl]]
-set auto_index(::rivet::import_keyvalue_pairs) [list source [file join $dir import_keyvalue_pairs.tcl]]
-set auto_index(::rivet::parray) [list source [file join $dir parray.tcl]]
-set auto_index(::rivet::tablearray) [list source [file join $dir tablearray.tcl]]
set auto_index(::rivet::wrap) [list source [file join $dir wrap.tcl]]
set auto_index(::rivet::wrapline) [list source [file join $dir wrap.tcl]]
-set auto_index(::rivet::load_cookies) [list source [file join $dir load_cookies.tcl]]
+set auto_index(::rivet::putsnnl) [list source [file join $dir putsnnl.tcl]]
+set auto_index(::rivet::tablearray) [list source [file join $dir tablearray.tcl]]
+set auto_index(::rivet::parray) [list source [file join $dir parray.tcl]]
---------------------------------------------------------------------
To unsubscribe, e-mail: rivet-cvs-unsubscribe@tcl.apache.org
For additional commands, e-mail: rivet-cvs-help@tcl.apache.org