You can subscribe to this list here.
2001 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(28) |
Nov
(58) |
Dec
(85) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2002 |
Jan
(125) |
Feb
(222) |
Mar
(274) |
Apr
(51) |
May
(22) |
Jun
(50) |
Jul
(15) |
Aug
(33) |
Sep
(11) |
Oct
(29) |
Nov
(17) |
Dec
(1) |
2003 |
Jan
(100) |
Feb
(21) |
Mar
(7) |
Apr
(45) |
May
|
Jun
(43) |
Jul
(27) |
Aug
(24) |
Sep
|
Oct
|
Nov
|
Dec
|
2004 |
Jan
(1) |
Feb
|
Mar
(13) |
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
(7) |
Sep
|
Oct
|
Nov
|
Dec
(4) |
2005 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(1) |
From: Nick J. <nje...@us...> - 2002-02-13 07:00:06
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv7802 Modified Files: sandweb.cgi Log Message: * NOW the checkout_commit() is actually executed. But the $repository->checkout() method call isn't working it seems. Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.169 retrieving revision 1.170 diff -U2 -r1.169 -r1.170 --- sandweb.cgi 13 Feb 2002 06:44:13 -0000 1.169 +++ sandweb.cgi 13 Feb 2002 06:59:57 -0000 1.170 @@ -106,4 +106,7 @@ my $submit = CGI::param('Submit'); my $vcs_command = CGI::param('vcs_command'); + my $module_name = CGI::param('module_name'); + + $log->debug("action: $action submit: $submit"); ####################################################### @@ -199,4 +202,6 @@ checkout_commit( ck_auth => $ck_auth, + repo_name => $repo_name, + module_name => $module_name, ); } else { @@ -1250,8 +1255,8 @@ exit 0; } - my $module = $args{'module_name'}; + my $module_name = $args{'module_name'}; my $repo_name = $args{'repo_name'}; - my $repo_server = $user->{'repo'}->{'server'}; + my $repo_server = $user->{'repo'}->{$repo_name}->{'server'}; my $repo_username = $user->{'repo'}->{$repo_name}->{'username'}; my $repo_type = $user->{'repo'}->{$repo_name}->{'type'}; @@ -1259,5 +1264,8 @@ my $repo_root = $user->{'repo'}->{$repo_name}->{'root'}; - my @module_list = @{$user->{'repo'}->{$repo_name}->{'module_list'}}; + my @module_list = (); + if ($user->{'repo'}->{$repo_name}->{'module_list'}) { + @module_list = @{$user->{'repo'}->{$repo_name}->{'module_list'}}; + } my $username = $auth->get_userinfo('username'); @@ -1277,35 +1285,36 @@ } + my $repository = SandWeb::Repository->new( + root => $vcsroot, + repo_type => $repo_type, + sandbox => "$users_dir/$repo_username", + ); + # foreach my $file (@filename) { -# %return = $repository->$vcs_command( -# file => "$location/$file", -# ); -# push (@vcs_output, "$return{'output'}\n"); -# push (@vcs_error, "$return{'error'}\n"); + my %return = $repository->checkout( + file => "$module_name", + ); + push (@vcs_output, "$return{'output'}\n"); + push (@vcs_error, "$return{'error'}\n"); # } -# -# my $repository = SandWeb::Repository->new( -# root => $vcsroot, -# repo_type => $repo_type, -# sandbox => "$users_dir/$username", -# ); - -# my $content = $ui->get_menu( -# MENU => 'vcs_output', -# LOCATION => $location, -# FILENAME => "@filename", -# PROGNAME => $progname, -# VCS_OUTPUT => "@vcs_output", -# VCS_ERROR => "@vcs_error", -# ); -# print CGI::header( -cookie => $ck_auth ); -# $ui->print_screen( -# TITLE=> "SandWeb : VCS $vcs_command", -# MENU_TITLE => 'SandWeb', -# SUBMENU_TITLE => "VCS $vcs_command", -# FOOTER => '', -# CONTENT => $content, -# ERROR => $error, -# ); + + $log->debug('dump', \%return); + + my $content = $ui->get_menu( + MENU => 'vcs_output', + LOCATION => $module_name, #$location, + #FILENAME => "@filename", + PROGNAME => $progname, + VCS_OUTPUT => "@vcs_output", + VCS_ERROR => "@vcs_error", + ); + print CGI::header( -cookie => $ck_auth ); + $ui->print_screen( + TITLE=> "SandWeb : checkout", + MENU_TITLE => 'SandWeb', + SUBMENU_TITLE => "checkout", + FOOTER => '', + CONTENT => $content, + ); exit 0; } |
From: Nick J. <nje...@us...> - 2002-02-13 06:44:16
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv5263 Modified Files: sandweb.cgi Log Message: * fixed up the checkout_commit() menu. It still doesn't actually checkout anything, however it does execute sucessfully, and most code for it is in place. Need to figure out how to use the javascript popup window for the VCS output, and also how to do the checkout at all. :) Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.168 retrieving revision 1.169 diff -U2 -r1.168 -r1.169 --- sandweb.cgi 13 Feb 2002 05:50:34 -0000 1.168 +++ sandweb.cgi 13 Feb 2002 06:44:13 -0000 1.169 @@ -1239,5 +1239,6 @@ # args: # ck_auth - the sessions cookie -# module - module name to checkout +# module_name - module name to checkout +# repo_name - name of repository module is in ############################################################################### @@ -1249,15 +1250,14 @@ exit 0; } - # this is where the Repository object is used - my $server = $user->{'repository'}->{'server'}; - my $vcs_username = $user->{'repository'}->{'username'}; - my $repo_type = $user->{'repository'}->{'repo_type'}; - my $connection = $user->{'repository'}->{'connection'}; - my $root = $user->{'repository'}->{'root'}; + my $module = $args{'module_name'}; + my $repo_name = $args{'repo_name'}; - my $sandbox = $user->{'paths'}->{'users_dir'}; - my @vcs_output = (); - my @vcs_error = (); - my $vcsroot; + my $repo_server = $user->{'repo'}->{'server'}; + my $repo_username = $user->{'repo'}->{$repo_name}->{'username'}; + my $repo_type = $user->{'repo'}->{$repo_name}->{'type'}; + my $repo_connection = $user->{'repo'}->{$repo_name}->{'connection'}; + my $repo_root = $user->{'repo'}->{$repo_name}->{'root'}; + + my @module_list = @{$user->{'repo'}->{$repo_name}->{'module_list'}}; my $username = $auth->get_userinfo('username'); @@ -1265,9 +1265,13 @@ my $users_dir = $config->{'paths'}->{'users_dir'}; + my $vcsroot; + my @vcs_output = (); + my @vcs_error = (); if ( $repo_type eq 'CVS' ) { - if ( $connection eq 'local' ) { - $vcsroot = "$root"; + if ( $repo_connection eq 'local' ) { + $vcsroot = "$repo_root"; } else { - $vcsroot = ":$connection:$vcs_username\@$server:$root"; + $vcsroot = + ":$repo_connection:$repo_username\@$repo_server:$repo_root"; } } @@ -1286,5 +1290,5 @@ # sandbox => "$users_dir/$username", # ); -# + # my $content = $ui->get_menu( # MENU => 'vcs_output', @@ -1304,5 +1308,5 @@ # ERROR => $error, # ); -# exit 0; + exit 0; } |
From: Rob H. <for...@us...> - 2002-02-13 06:16:12
|
Update of /cvsroot/sandweb/sandweb/templates In directory usw-pr-cvs1:/tmp/cvs-serv658 Modified Files: browse_module.html edit_file.html view_file.html Log Message: migrating file actions to browse_file_* Index: browse_module.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/browse_module.html,v retrieving revision 1.13 retrieving revision 1.14 diff -U2 -r1.13 -r1.14 --- browse_module.html 13 Feb 2002 05:42:01 -0000 1.13 +++ browse_module.html 13 Feb 2002 06:16:07 -0000 1.14 @@ -12,4 +12,5 @@ </script> <form method="get" submit="<TMPL_VAR NAME=PROGNAME>" name="browse"> + <input type="hidden" name="module" value="<TMPL_VAR NAME=MODULE>" /> <input type="hidden" name="location" value="<TMPL_VAR NAME=LOCATION>" /> Index: edit_file.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/edit_file.html,v retrieving revision 1.22 retrieving revision 1.23 diff -U2 -r1.22 -r1.23 --- edit_file.html 13 Feb 2002 05:42:01 -0000 1.22 +++ edit_file.html 13 Feb 2002 06:16:07 -0000 1.23 @@ -10,5 +10,5 @@ <input name="location" value="<TMPL_VAR NAME=LOCATION>" type="hidden" /> <input name="filename" value="<TMPL_VAR NAME=FILENAME>" type="hidden" /> - <input type="submit" name="save" value="Save" /> + <input type="submit" name="Submit" value="Save" /> <pre> <textarea name="data" cols="80" rows="24"><TMPL_VAR NAME=CONTENT></textarea> Index: view_file.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/view_file.html,v retrieving revision 1.31 retrieving revision 1.32 diff -U2 -r1.31 -r1.32 --- view_file.html 13 Feb 2002 05:42:01 -0000 1.31 +++ view_file.html 13 Feb 2002 06:16:07 -0000 1.32 @@ -11,7 +11,7 @@ <td width="100%" align="right"> <input type="hidden" name="action" value="browse_file" /> - <a href="<TMPL_VAR NAME=PROGNAME>/<TMPL_VAR NAME=FILENAME>?action=file&file_command=download&location=<TMPL_VAR NAME=LOCATION>&filename=<TMPL_VAR NAME=FILENAME>">download</a> + <a href="<TMPL_VAR NAME=PROGNAME>/<TMPL_VAR NAME=FILENAME>?action=browse_file&file_command=download&location=<TMPL_VAR NAME=LOCATION>&filename=<TMPL_VAR NAME=FILENAME>">download</a> <TMPL_IF NAME=EDIT> - <a href="<TMPL_VAR NAME=PROGNAME>/<TMPL_VAR NAME=FILENAME>?action=file&file_command=edit&location=<TMPL_VAR NAME=LOCATION>&filename=<TMPL_VAR NAME=FILENAME>">edit</a> + <a href="<TMPL_VAR NAME=PROGNAME>/<TMPL_VAR NAME=FILENAME>?action=browse_file&file_command=edit&location=<TMPL_VAR NAME=LOCATION>&filename=<TMPL_VAR NAME=FILENAME>">edit</a> </TMPL_IF> <TMPL_VAR NAME=ERROR> |
From: Nick J. <nje...@us...> - 2002-02-13 05:50:37
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv28596 Modified Files: sandweb.cgi Log Message: * removed depricated functions: main_menu & vcs_prefs Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.167 retrieving revision 1.168 diff -U2 -r1.167 -r1.168 --- sandweb.cgi 13 Feb 2002 05:36:12 -0000 1.167 +++ sandweb.cgi 13 Feb 2002 05:50:34 -0000 1.168 @@ -112,5 +112,5 @@ # unless ($action) { - # with auth cookie, default is main_menu + # with auth cookie, default is sandbox_menu sandbox_menu( ck_auth => $ck_auth ); } @@ -120,9 +120,5 @@ $log->debug("loading prefs"); - if ( $action eq 'main_menu' ) { - # called main menu - main_menu( ck_auth => $ck_auth ); - } - elsif ( $action eq 'debug' ) { + if ( $action eq 'debug' ) { # called test menu debug_menu( ck_auth => $ck_auth ); @@ -295,44 +291,4 @@ } -############################################################################### -# main menu -# -# greet the user -# deprecated -# -# args : -# ck_auth - cookie data. -############################################################################### -sub main_menu { - my %args = @_; - - $log->debug("entering main menu"); - - my $ck_auth = $args{'ck_auth'}; - unless ($ck_auth) { - &login_menu(); - exit 0; - } - - $log->debug("auth cookie: '$ck_auth'"); - - print CGI::header( -cookie => $ck_auth ); - $ui->print_screen( - TITLE=> 'SandWeb : main', - MENU_TITLE => 'SandWeb', - SUBMENU_TITLE => 'main', - FOOTER => '', - CONTENT => "hello " . $auth->get_userinfo('username'), - ERROR => $error, - ); - exit 0; -} - -#put sword bag -#take flail bag -#wield flail -#take meat corpse -#look fido -#kill fido ############################################################################### @@ -750,94 +706,4 @@ } -############################################################################### -# vcs prefs menu -# -# being replaced by reopsitory menu? -# deprecated -# -# args: -# ck_auth - the sessions cookie -############################################################################### -sub vcs_prefs_menu { - my %args = @_; - my $ck_auth = $args{'ck_auth'}; - unless ($ck_auth) { - &login_menu(); - exit 0; - } - - load_config(1); # load prefs and do not log error msg - my $username = $auth->get_userinfo('username'); - my $name = $user->{'repo'}->{'name'}; - my $server = $user->{'repo'}->{'server'}; - my $vcs_username = $user->{'repo'}->{'username'}; - my $root = $user->{'repo'}->{'root'}; - my $users_dir = $config->{'paths'}->{'users_dir'}; - my $repo_type = $user->{'repo'}->{'repo_type'}; - my $connection = $user->{'repo'}->{'connection'}; - my $vcsroot; - - if ( $repo_type eq 'CVS' ) { - $vcsroot = ":$connection:$vcs_username\@$server:$root"; - } else { - $vcsroot = "blah"; - } - - my $repository = SandWeb::Repository->new( - root => "$vcsroot", - repo_type => $repo_type, - sandbox => "$users_dir/$username", - ); - - my @connections = $repository->get_connections(); - my @repo_types = $repository->get_repo_types(); - - my @loop_connection = (); - my @loop_repo_type = (); - - foreach my $connection_loop (@connections) { - my %row_data; - if ($connection_loop eq $connection) { - $row_data{CONNECTION} = "<option selected>$connection_loop</option>"; - } - else { - $row_data{CONNECTION} = "<option>$connection_loop</option>"; - } - push (@loop_connection, \%row_data); - } - - foreach my $repo_type_loop (@repo_types) { - my %row_data; - if ($repo_type_loop eq $repo_type) { - $row_data{REPO_TYPE} = "<option selected>$repo_type_loop</option>"; - } - else { - $row_data{REPO_TYPE} = "<option>$repo_type_loop</option>"; - } - push (@loop_repo_type, \%row_data); - } - - my $content = $ui->get_menu( - MENU => 'vcs_prefs', - PROGNAME => $progname, - NAME => $name, - SERVER => $server, - USERNAME => $vcs_username, - ROOT => $root, - LOOP_CONNECTION => \@loop_connection, - LOOP_REPO_TYPE => \@loop_repo_type, - ); - - print CGI::header( -cookie => $ck_auth ); - $ui->print_screen( - TITLE=> 'SandWeb : preferences', - MENU_TITLE => 'SandWeb', - SUBMENU_TITLE => 'preferences', - FOOTER => '', - CONTENT => $content, - ERROR => $error, - ); - exit 0; -} ############################################################################### @@ -1483,7 +1349,8 @@ preferences_menu( ck_auth => $ck_auth ); } - # when finished go to main menu. (this should be dynamic probably, so it - # returns to whichever menu they wanted to go to in the first place). - main_menu( ck_auth => $ck_auth ); + # when finished go to sandbox menu. (this should be dynamic probably, + # so it returns to whichever menu they wanted to go to in the first + # place). + sandbox_menu( ck_auth => $ck_auth ); } |
From: Nick J. <nje...@us...> - 2002-02-13 05:42:04
|
Update of /cvsroot/sandweb/sandweb/templates In directory usw-pr-cvs1:/tmp/cvs-serv26704 Modified Files: browse_module.html create_file.html create_folder.html edit_file.html menu_bar.html preferences.html repository.html sandbox.html upload_file.html vcs_output.html view_file.html Log Message: * updated templates NOT to refer to *_menu Index: browse_module.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/browse_module.html,v retrieving revision 1.12 retrieving revision 1.13 diff -U2 -r1.12 -r1.13 --- browse_module.html 13 Feb 2002 05:08:47 -0000 1.12 +++ browse_module.html 13 Feb 2002 05:42:01 -0000 1.13 @@ -50,5 +50,5 @@ Current location : <TMPL_LOOP NAME="LOCATION_LOOP"> - <a href="<TMPL_VAR NAME="PROGNAME">?action=browse_module_menu&location=<TMPL_VAR NAME="LOCATION_FULL">"><TMPL_VAR NAME="LOCATION_LINK"></a> + <a href="<TMPL_VAR NAME="PROGNAME">?action=browse_module&location=<TMPL_VAR NAME="LOCATION_FULL">"><TMPL_VAR NAME="LOCATION_LINK"></a> </TMPL_LOOP> </font> Index: create_file.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/create_file.html,v retrieving revision 1.10 retrieving revision 1.11 diff -U2 -r1.10 -r1.11 --- create_file.html 13 Feb 2002 05:08:47 -0000 1.10 +++ create_file.html 13 Feb 2002 05:42:01 -0000 1.11 @@ -6,5 +6,5 @@ <input name="location" value="<TMPL_VAR NAME=LOCATION>" type="hidden" /> Current location: -<a href="<TMPL_VAR NAME=PROGNAME>?action=browse_module_menu&location=<TMPL_VAR NAME=LOCATION>"><TMPL_VAR NAME=LOCATION></a><br /> +<a href="<TMPL_VAR NAME=PROGNAME>?action=browse_module&location=<TMPL_VAR NAME=LOCATION>"><TMPL_VAR NAME=LOCATION></a><br /> <br /> Enter filename : Index: create_folder.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/create_folder.html,v retrieving revision 1.8 retrieving revision 1.9 diff -U2 -r1.8 -r1.9 --- create_folder.html 13 Feb 2002 05:08:47 -0000 1.8 +++ create_folder.html 13 Feb 2002 05:42:01 -0000 1.9 @@ -7,5 +7,5 @@ <input name="fullpath" value="<TMPL_VAR NAME=FULLPATH>" type="hidden" /> Current location: -<a href="<TMPL_VAR NAME=PROGNAME>?action=browse_module_menu&location=<TMPL_VAR NAME=LOCATION>"><TMPL_VAR NAME=LOCATION></a><br /> <br /> +<a href="<TMPL_VAR NAME=PROGNAME>?action=browse_module&location=<TMPL_VAR NAME=LOCATION>"><TMPL_VAR NAME=LOCATION></a><br /> <br /> Enter foldername:<br /> <input name="filename" type="text" /><br /> Index: edit_file.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/edit_file.html,v retrieving revision 1.21 retrieving revision 1.22 diff -U2 -r1.21 -r1.22 --- edit_file.html 13 Feb 2002 05:08:47 -0000 1.21 +++ edit_file.html 13 Feb 2002 05:42:01 -0000 1.22 @@ -1,5 +1,5 @@ <tr> <td width="100%"> - Current location : <a href="<TMPL_VAR NAME=PROGNAME>?action=browse_module_menu&location=<TMPL_VAR NAME=LOCATION>"><TMPL_VAR NAME=LOCATION></a> + Current location : <a href="<TMPL_VAR NAME=PROGNAME>?action=browse_module&location=<TMPL_VAR NAME=LOCATION>"><TMPL_VAR NAME=LOCATION></a> <br /> Current filename : <TMPL_VAR NAME=FILENAME> Index: menu_bar.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/menu_bar.html,v retrieving revision 1.13 retrieving revision 1.14 diff -U2 -r1.13 -r1.14 --- menu_bar.html 31 Jan 2002 23:23:57 -0000 1.13 +++ menu_bar.html 13 Feb 2002 05:42:01 -0000 1.14 @@ -1,10 +1,10 @@ -<!-- <br /> <a href="<TMPL_VAR NAME=CGI_PATH>/<TMPL_VAR NAME=CGI_EXEC>?action=main_menu">main</a><br /> --> -<!-- <b><a href="<TMPL_VAR NAME=CGI_PATH>/<TMPL_VAR NAME=CGI_EXEC>?action=debug_menu">debug</a></b> | --> +<!-- <br /> <a href="<TMPL_VAR NAME=CGI_PATH>/<TMPL_VAR NAME=CGI_EXEC>?action=main">main</a><br /> --> +<!-- <b><a href="<TMPL_VAR NAME=CGI_PATH>/<TMPL_VAR NAME=CGI_EXEC>?action=debug">debug</a></b> | --> -<a href="<TMPL_VAR NAME=CGI_PATH>/<TMPL_VAR NAME=CGI_EXEC>?action=sandbox_menu">sandbox</a> +<a href="<TMPL_VAR NAME=CGI_PATH>/<TMPL_VAR NAME=CGI_EXEC>?action=sandbox">sandbox</a> - <b>|</b> <a href="<TMPL_VAR NAME=CGI_PATH>/<TMPL_VAR NAME=CGI_EXEC>?action=repository_menu">repository</a> + <b>|</b> <a href="<TMPL_VAR NAME=CGI_PATH>/<TMPL_VAR NAME=CGI_EXEC>?action=repository">repository</a> - <b>|</b> <a href="<TMPL_VAR NAME=CGI_PATH>/<TMPL_VAR NAME=CGI_EXEC>?action=preferences_menu">prefs</a> + <b>|</b> <a href="<TMPL_VAR NAME=CGI_PATH>/<TMPL_VAR NAME=CGI_EXEC>?action=preferences">prefs</a> <b>|</b> <a href="<TMPL_VAR NAME=CGI_PATH>/<TMPL_VAR NAME=CGI_EXEC>?action=logout">logout</a><br /> Index: preferences.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/preferences.html,v retrieving revision 1.15 retrieving revision 1.16 diff -U2 -r1.15 -r1.16 --- preferences.html 1 Feb 2002 03:39:36 -0000 1.15 +++ preferences.html 13 Feb 2002 05:42:01 -0000 1.16 @@ -1,4 +1,4 @@ <form submit="<TMPL_VAR NAME=PROGNAME>"> -<input type="hidden" name="action" value="preferences_menu" /> +<input type="hidden" name="action" value="preferences" /> <tr> <td width="20%" align="right"> @@ -23,5 +23,5 @@ </td> <td width="30%" align="center"> - <!-- <a href="<TMPL_VAR NAME=PROGNAME>?action=vcs_prefs_menu">Set Up Repository</a> --> + <!-- <a href="<TMPL_VAR NAME=PROGNAME>?action=vcs_prefs">Set Up Repository</a> --> </td> <td width="65%" align="center"> Index: repository.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/repository.html,v retrieving revision 1.8 retrieving revision 1.9 diff -U2 -r1.8 -r1.9 --- repository.html 11 Feb 2002 02:47:15 -0000 1.8 +++ repository.html 13 Feb 2002 05:42:01 -0000 1.9 @@ -2,12 +2,12 @@ <!-- function submitForm(clicked) { - document.repository_menu.repository_selected.value=clicked; - document.repository_menu.submit(); + document.repository.repository_selected.value=clicked; + document.repository.submit(); } // --> </script> -<form submit="<TMPL_VAR NAME=PROGNAME>" name="repository_menu"> -<input type="hidden" name="action" value="repository_menu"> +<form submit="<TMPL_VAR NAME=PROGNAME>" name="repository"> +<input type="hidden" name="action" value="repository"> <!-- <input type="hidden" name="repository_selected" value="<TMPL_VAR NAME=REPOSITORY_SELECTED>"> --> <input type="hidden" name="new_repository" value="<TMPL_VAR NAME=NEW_REPOSITORY>"> Index: sandbox.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/sandbox.html,v retrieving revision 1.7 retrieving revision 1.8 diff -U2 -r1.7 -r1.8 --- sandbox.html 13 Feb 2002 04:08:34 -0000 1.7 +++ sandbox.html 13 Feb 2002 05:42:01 -0000 1.8 @@ -1,4 +1,4 @@ <form submit="<TMPL_VAR NAME=PROGNAME>"> -<input type="hidden" name="action" value="browse_menu" /> +<input type="hidden" name="action" value="browse" /> <tr> <td width="80%" align="left"> @@ -6,5 +6,5 @@ </td> <td width="20%" align="center"> - [<a href="<TMPL_VAR NAME=PROGNAME>?action=checkout_menu">checkout a module</a>] + [<a href="<TMPL_VAR NAME=PROGNAME>?action=checkout">checkout a module</a>] </td> </tr> @@ -29,5 +29,5 @@ <tr> <td width="20%" align="left"> - <a href="<TMPL_VAR NAME=PROGNAME>?action=browse_module_menu&module_name=<TMPL_VAR NAME="MODULE_NAME">"><TMPL_VAR NAME="MODULE_NAME"></a> + <a href="<TMPL_VAR NAME=PROGNAME>?action=browse_module&module_name=<TMPL_VAR NAME="MODULE_NAME">"><TMPL_VAR NAME="MODULE_NAME"></a> </td> <td width="40%" align="left"> @@ -39,7 +39,7 @@ <td width="15%" align="center"> <font size="2"> - <a href="<TMPL_VAR NAME=PROGNAME>?action=module_update_menu&module_name=<TMPL_VAR NAME="MODULE_NAME">">update</a> + <a href="<TMPL_VAR NAME=PROGNAME>?action=module_update&module_name=<TMPL_VAR NAME="MODULE_NAME">">update</a> | - <a href="<TMPL_VAR NAME=PROGNAME>?action=module_delete_menu&module_name=<TMPL_VAR NAME="MODULE_NAME">">delete</a> + <a href="<TMPL_VAR NAME=PROGNAME>?action=module_delete&module_name=<TMPL_VAR NAME="MODULE_NAME">">delete</a> </font> </td> Index: upload_file.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/upload_file.html,v retrieving revision 1.9 retrieving revision 1.10 diff -U2 -r1.9 -r1.10 --- upload_file.html 13 Feb 2002 05:08:47 -0000 1.9 +++ upload_file.html 13 Feb 2002 05:42:01 -0000 1.10 @@ -8,5 +8,5 @@ <input name="filename" value="<TMPL_VAR NAME=FILENAME>" type="hidden" /> Current location : -<a href="<TMPL_VAR NAME=PROGNAME>?action=browse_module_menu&location=<TMPL_VAR NAME=LOCATION>"><TMPL_VAR NAME=LOCATION></a><br /> <br /> +<a href="<TMPL_VAR NAME=PROGNAME>?action=browse_module&location=<TMPL_VAR NAME=LOCATION>"><TMPL_VAR NAME=LOCATION></a><br /> <br /> Enter a file to upload:<br /> <TMPL_VAR NAME=ERROR> Index: vcs_output.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/vcs_output.html,v retrieving revision 1.12 retrieving revision 1.13 diff -U2 -r1.12 -r1.13 --- vcs_output.html 31 Jan 2002 23:31:58 -0000 1.12 +++ vcs_output.html 13 Feb 2002 05:42:01 -0000 1.13 @@ -1,5 +1,5 @@ <tr> <td width="100%"> - Current location : <a href="<TMPL_VAR NAME=PROGNAME>?action=browse_module_menu&location=/<TMPL_VAR NAME=LOCATION>">/<TMPL_VAR NAME=LOCATION></a> + Current location : <a href="<TMPL_VAR NAME=PROGNAME>?action=browse_module&location=/<TMPL_VAR NAME=LOCATION>">/<TMPL_VAR NAME=LOCATION></a> <br /> Current filename : <TMPL_VAR NAME=FILENAME> Index: view_file.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/view_file.html,v retrieving revision 1.30 retrieving revision 1.31 diff -U2 -r1.30 -r1.31 --- view_file.html 13 Feb 2002 05:08:47 -0000 1.30 +++ view_file.html 13 Feb 2002 05:42:01 -0000 1.31 @@ -4,5 +4,5 @@ <tr> <td width="50%"> - Current location : <a href="<TMPL_VAR NAME=PROGNAME>?action=browse_module_menu&location=<TMPL_VAR NAME=LOCATION>"><TMPL_VAR NAME=LOCATION></a> + Current location : <a href="<TMPL_VAR NAME=PROGNAME>?action=browse_module&location=<TMPL_VAR NAME=LOCATION>"><TMPL_VAR NAME=LOCATION></a> <br /> </td> |
From: Rob H. <for...@us...> - 2002-02-13 05:36:16
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv26216 Modified Files: sandweb.cgi Log Message: cut out *_menu Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.166 retrieving revision 1.167 diff -U2 -r1.166 -r1.167 --- sandweb.cgi 13 Feb 2002 04:33:53 -0000 1.166 +++ sandweb.cgi 13 Feb 2002 05:36:12 -0000 1.167 @@ -68,5 +68,5 @@ # catch file-specific actions if ( CGI::param('action_file') ) { - $action = 'file'; + $action = 'browse_file_commit'; } @@ -124,9 +124,9 @@ main_menu( ck_auth => $ck_auth ); } - elsif ( $action eq 'debug_menu' ) { + elsif ( $action eq 'debug' ) { [...1661 lines suppressed...] + MENU => 'vcs_output', + LOCATION => $location, + FILENAME => "@filename", + PROGNAME => $progname, + VCS_OUTPUT => "@vcs_output", + VCS_ERROR => "@vcs_error", + ); + print CGI::header( -cookie => $ck_auth ); + $ui->print_screen( + TITLE=> "SandWeb : VCS $vcs_command", + MENU_TITLE => 'SandWeb', + SUBMENU_TITLE => "VCS $vcs_command", + FOOTER => '', + CONTENT => $content, + ERROR => $error, + ); + exit 0; +} ############################################################################### |
Update of /cvsroot/sandweb/sandweb/templates In directory usw-pr-cvs1:/tmp/cvs-serv21039 Modified Files: browse_module.html commit.html create_file.html create_folder.html edit_file.html upload_file.html view_file.html Log Message: * modified files from value="file" to value="browse_file" and value="vcsaction" to value="browse_vcs" Index: browse_module.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/browse_module.html,v retrieving revision 1.11 retrieving revision 1.12 diff -U2 -r1.11 -r1.12 --- browse_module.html 5 Feb 2002 05:46:45 -0000 1.11 +++ browse_module.html 13 Feb 2002 05:08:47 -0000 1.12 @@ -33,5 +33,5 @@ </select>     - <input type="submit" name="action" value="vcsaction" /> + <input type="submit" name="action" value="browse_vcs" /> </td> </tr> Index: commit.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/commit.html,v retrieving revision 1.8 retrieving revision 1.9 diff -U2 -r1.8 -r1.9 --- commit.html 2 Feb 2002 09:04:34 -0000 1.8 +++ commit.html 13 Feb 2002 05:08:47 -0000 1.9 @@ -3,5 +3,5 @@ Please enter a commit message for <TMPL_VAR NAME=LOCATION>/<TMPL_VAR NAME=FILENAME> : <form submit="<TMPL_VAR NAME=PROGNAME>" type="get"> - <input type="hidden" name="action" value="vcsaction" /> + <input type="hidden" name="action" value="browse_vcs" /> <input type="hidden" name="vcs_command" value="commit" /> <input type="hidden" name="filename" value="<TMPL_VAR NAME=FILENAME>" /> Index: create_file.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/create_file.html,v retrieving revision 1.9 retrieving revision 1.10 diff -U2 -r1.9 -r1.10 --- create_file.html 2 Feb 2002 09:04:34 -0000 1.9 +++ create_file.html 13 Feb 2002 05:08:47 -0000 1.10 @@ -2,5 +2,5 @@ <td width="100%"> <form action="<TMPL_VAR NAME=PROGNAME>"> -<input name="action" value="file" type="hidden" /> +<input name="action" value="browse_file" type="hidden" /> <input name="file_command" value="create_file" type="hidden" /> <input name="location" value="<TMPL_VAR NAME=LOCATION>" type="hidden" /> Index: create_folder.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/create_folder.html,v retrieving revision 1.7 retrieving revision 1.8 diff -U2 -r1.7 -r1.8 --- create_folder.html 31 Jan 2002 23:31:58 -0000 1.7 +++ create_folder.html 13 Feb 2002 05:08:47 -0000 1.8 @@ -2,5 +2,5 @@ <td width="100%"> <form action="<TMPL_VAR NAME=PROGNAME>"> -<input name="action" value="file" type="hidden" /> +<input name="action" value="browse_file" type="hidden" /> <input name="file_command" value="create_folder" type="hidden" /> <input name="location" value="<TMPL_VAR NAME=LOCATION>" type="hidden" /> Index: edit_file.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/edit_file.html,v retrieving revision 1.20 retrieving revision 1.21 diff -U2 -r1.20 -r1.21 --- edit_file.html 10 Feb 2002 20:50:25 -0000 1.20 +++ edit_file.html 13 Feb 2002 05:08:47 -0000 1.21 @@ -6,5 +6,5 @@ <br /> <form submit="<TMPL_VAR NAME=PROGNAME>" method="POST"> - <input name="action" value="file" type="hidden" /> + <input name="action" value="browse_file" type="hidden" /> <input name="file_command" value="edit" type="hidden" /> <input name="location" value="<TMPL_VAR NAME=LOCATION>" type="hidden" /> Index: upload_file.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/upload_file.html,v retrieving revision 1.8 retrieving revision 1.9 diff -U2 -r1.8 -r1.9 --- upload_file.html 2 Feb 2002 09:04:34 -0000 1.8 +++ upload_file.html 13 Feb 2002 05:08:47 -0000 1.9 @@ -3,5 +3,5 @@ <form method="post" action="<TMPL_VAR NAME=PROGNAME>" enctype="multipart/form-data"> -<input name="action" value="file" type="hidden" /> +<input name="action" value="browse_file" type="hidden" /> <input name="file_command" value="upload" type="hidden" /> <input name="location" value="<TMPL_VAR NAME=LOCATION>" type="hidden" /> Index: view_file.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/view_file.html,v retrieving revision 1.29 retrieving revision 1.30 diff -U2 -r1.29 -r1.30 --- view_file.html 10 Feb 2002 20:46:09 -0000 1.29 +++ view_file.html 13 Feb 2002 05:08:47 -0000 1.30 @@ -10,5 +10,5 @@ <tr> <td width="100%" align="right"> - <input type="hidden" name="action" value="file" /> + <input type="hidden" name="action" value="browse_file" /> <a href="<TMPL_VAR NAME=PROGNAME>/<TMPL_VAR NAME=FILENAME>?action=file&file_command=download&location=<TMPL_VAR NAME=LOCATION>&filename=<TMPL_VAR NAME=FILENAME>">download</a> <TMPL_IF NAME=EDIT> |
From: Nick J. <nje...@us...> - 2002-02-13 04:33:56
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv14945 Modified Files: sandweb.cgi Log Message: * finished checkout_menu() (no checkout_commit() yet) Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.165 retrieving revision 1.166 diff -U2 -r1.165 -r1.166 --- sandweb.cgi 13 Feb 2002 04:26:09 -0000 1.165 +++ sandweb.cgi 13 Feb 2002 04:33:53 -0000 1.166 @@ -225,10 +225,4 @@ ); } - elsif ( $action eq 'module_checkout_menu' ) { - vcsaction( - ck_auth => $ck_auth, - vcs_command => 'checkout', - ); - } elsif ( $action eq 'repository_menu' ) { if ($submit) { @@ -534,5 +528,4 @@ # use the browse object to show user's sandbox - my $content = $browse->browse("$location", "$progname", "@vcs_commands", "@file_commands", $repo_type); @@ -1036,8 +1029,21 @@ my @repos = sort keys %{$user->{'repo'}}; + my @repo_list = (); + + my $i = 0; + foreach my $repo (@repos) { + my %entry; + $entry{'REPO_NAME'} = $repo; + if ($i == 0) { + $entry{'SELECTED'} = 1; + } + push @repo_list, \%entry; + $i++; + } my $content = $ui->get_menu( MENU => 'checkout', PROGNAME => $progname, + REPO_LIST => \@repo_list, ); |
From: Nick J. <nje...@us...> - 2002-02-13 04:33:43
|
Update of /cvsroot/sandweb/sandweb/templates In directory usw-pr-cvs1:/tmp/cvs-serv14853 Modified Files: checkout.html Log Message: * finished checkout_menu() (no checkout_commit() yet) Index: checkout.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/checkout.html,v retrieving revision 1.10 retrieving revision 1.11 diff -U2 -r1.10 -r1.11 --- checkout.html 13 Feb 2002 04:08:34 -0000 1.10 +++ checkout.html 13 Feb 2002 04:33:40 -0000 1.11 @@ -3,5 +3,7 @@ <td width="100%"> Select repository: <select size="1" name="repository_name"> - <option selected>My First Repo(tm)</option> + <TMPL_LOOP NAME="REPO_LIST"> + <option <TMPL_IF NAME="SELECTED">selected</TMPL_IF>><TMPL_VAR NAME="REPO_NAME"></option> + </TMPL_LOOP> </select> <br /> <br /> |
From: Rob H. <for...@us...> - 2002-02-13 04:26:12
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv13511 Modified Files: sandweb.cgi Log Message: making nick's version newest Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.164 retrieving revision 1.165 diff -U2 -r1.164 -r1.165 --- sandweb.cgi 13 Feb 2002 04:24:18 -0000 1.164 +++ sandweb.cgi 13 Feb 2002 04:26:09 -0000 1.165 @@ -1,4 +1,2 @@ -? .sandweb.cgi.swp -? sandweb.cgi.mine #!/usr/bin/perl -w # Sandweb CGI |
From: Rob H. <for...@us...> - 2002-02-13 04:24:20
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv13260 Modified Files: sandweb.cgi Log Message: bad merge, reverting to nick's changes Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.163 retrieving revision 1.164 diff -U2 -r1.163 -r1.164 --- sandweb.cgi 13 Feb 2002 04:14:55 -0000 1.163 +++ sandweb.cgi 13 Feb 2002 04:24:18 -0000 1.164 @@ -1,2 +1,4 @@ +? .sandweb.cgi.swp +? sandweb.cgi.mine #!/usr/bin/perl -w # Sandweb CGI @@ -106,5 +108,4 @@ my $submit = CGI::param('Submit'); my $vcs_command = CGI::param('vcs_command'); - my @file_list = CGI::param('file_list'); ####################################################### @@ -130,5 +131,5 @@ } elsif ( $action eq 'preferences_menu' ) { - if (! $submit ) { + if (! CGI::param('Submit')) { # call preferences menu preferences_menu( ck_auth => $ck_auth ); @@ -165,16 +166,4 @@ ); } - elsif ( $action eq 'browse_vcs_commit' ) { - # called vcs commit from browse - my $location = CGI::param('location'); - unless ($location) { - $location = ""; - } - browse_vcs_commit( - ck_auth => $ck_auth, - location => $location, - vcs_command => $vcs_command, - ); - } elsif ( $action eq 'file' ) { # called file manipulator @@ -890,6 +879,20 @@ } - -sub checkout_menu { +############################################################################### +# vcsaction +# +# all VCS actions are caught by this subroutine, and dealt +# with by calling the appropriate Repository method. +# +# A Repository object is created and used. +# +# args: +# ck_auth - the sessions cookie +# vcs_command - name of the Repository object method to be invoked +# filename - name of the file(s) that the vcs_command should +# be used with. NOTE: this is an array +# location - system path to the file(s) specified by filename +############################################################################### +sub vcsaction { my %args = @_; @@ -941,24 +944,86 @@ sandbox => "$users_dir/$username", ); + if ( $vcs_command eq 'commit' ) { + if ($message) { + # can't give the leading / to the VCS + $location =~ s/\///; + foreach my $file (@filename) { + %return = $repository->commit( + file => "$location/$file", + message => "$message", + ); + push (@vcs_output, "$return{'output'}\n"); + push (@vcs_error, "$return{'error'}\n"); + } - my $content = $ui->get_menu( - MENU => 'checkout', - LOCATION => $location, - PROGNAME => $progname, - ); - - print CGI::header( -cookie => $ck_auth ); - $ui->print_screen( - TITLE=> 'SandWeb : checkout', - MENU_TITLE => 'SandWeb', - SUBMENU_TITLE => 'checkout', - FOOTER => '', - CONTENT => $content, - ERROR => $error, - ); - exit 0; + my $content = $ui->get_menu( + MENU => 'vcs_output', + LOCATION => $location, + PROGNAME => $progname, + VCS_OUTPUT => "@vcs_output", + VCS_ERROR => "@vcs_error", + ); + print CGI::header( -cookie => $ck_auth ); + $ui->print_screen( + TITLE=> "SandWeb : VCS $vcs_command", + MENU_TITLE => 'SandWeb', + SUBMENU_TITLE => "VCS $vcs_command", + FOOTER => '', + CONTENT => $content, + ERROR => $error, + ); + exit 0; + } + my $content = $ui->get_menu( + MENU => 'commit', + LOCATION => $location, + PROGNAME => $progname, + FILENAME => "@filename", + ); + print CGI::header( -cookie => $ck_auth ); + $ui->print_screen( + TITLE=> 'SandWeb : commit file(s)', + MENU_TITLE => 'SandWeb', + SUBMENU_TITLE => 'commit file(s)', + FOOTER => '', + CONTENT => $content, + ERROR => $error, + ); + exit 0; + } + else { + # this is where the Repository object is used + # can't give the leading / to the VCS + $location =~ s/\///; + + foreach my $file (@filename) { + %return = $repository->$vcs_command( + file => "$location/$file", + ); + push (@vcs_output, "$return{'output'}\n"); + push (@vcs_error, "$return{'error'}\n"); + } + } + my $content = $ui->get_menu( + MENU => 'vcs_output', + LOCATION => $location, + FILENAME => "@filename", + PROGNAME => $progname, + VCS_OUTPUT => "@vcs_output", + VCS_ERROR => "@vcs_error", + ); + print CGI::header( -cookie => $ck_auth ); + $ui->print_screen( + TITLE=> "SandWeb : VCS $vcs_command", + MENU_TITLE => 'SandWeb', + SUBMENU_TITLE => "VCS $vcs_command", + FOOTER => '', + CONTENT => $content, + ERROR => $error, + ); + exit 0; } -sub commit_menu { +sub checkout_menu { my %args = @_; my $ck_auth = $args{'ck_auth'}; @@ -971,22 +1036,5 @@ preferences_menu( ck_auth => $ck_auth ); } - - my @file_list = $args{'file_list'}; - my $location = $args{'location'}; - my $message = CGI::param('message'); - my $username = $auth->get_userinfo('username'); - my $template_dir = $config->{'paths'}->{'template_dir'}; - my $users_dir = $config->{'paths'}->{'users_dir'}; - my %return; - my $server = $user->{'repository'}->{'server'}; - my $vcs_username = $user->{'repository'}->{'username'}; - my $repo_type = $user->{'repository'}->{'repo_type'}; - my $connection = $user->{'repository'}->{'connection'}; - my $root = $user->{'repository'}->{'root'}; - my $sandbox = $user->{'paths'}->{'users_dir'}; - my @vcs_output = (); - my @vcs_error = (); - my $vcsroot; - + my @repos = sort keys %{$user->{'repo'}}; @@ -994,11 +1042,11 @@ MENU => 'checkout', PROGNAME => $progname, - FILENAME => "@file_list", ); + print CGI::header( -cookie => $ck_auth ); $ui->print_screen( - TITLE=> 'SandWeb : commit file(s)', + TITLE=> 'SandWeb : checkout', MENU_TITLE => 'SandWeb', - SUBMENU_TITLE => 'commit file(s)', + SUBMENU_TITLE => 'checkout', FOOTER => '', CONTENT => $content, @@ -1006,5 +1054,5 @@ ); exit 0; -} +} ############################################################################### @@ -1326,100 +1374,4 @@ ## -############################################################################### -# browse_vcs_commit -# -# VCS actions from browse_menu are caught by this subroutine, and dealt -# with by calling the appropriate Repository method. -# -# A Repository object is created and used. -# -# args: -# ck_auth - the sessions cookie -# vcs_command - name of the Repository object method to be invoked -# filename - name of the file(s) that the vcs_command should -# be used with. NOTE: this is an array -# location - system path to the file(s) specified by filename -############################################################################### - -sub browse_vcs_commit { - my %args = @_; - - my $ck_auth = $args{'ck_auth'}; - unless ($ck_auth) { - &login_menu(); - exit 0; - } - if (! load_config()) { - # no existing user config, forward to prefs menu - preferences_menu( ck_auth => $ck_auth ); - } - - my $vcs_command = $args{'vcs_command'}; - my @filename = (); - my $count = 0; - while ( $args{'filename'}->[$count] ) { - push (@filename, $args{'filename'}->[$count]); - $count++; - } - my @file_list = $args{'file_list'}; - my $location = $args{'location'}; - my $message = CGI::param('message'); - my $username = $auth->get_userinfo('username'); - my $template_dir = $config->{'paths'}->{'template_dir'}; - my $users_dir = $config->{'paths'}->{'users_dir'}; - my %return; - my $server = $user->{'repository'}->{'server'}; - my $vcs_username = $user->{'repository'}->{'username'}; - my $repo_type = $user->{'repository'}->{'repo_type'}; - my $connection = $user->{'repository'}->{'connection'}; - my $root = $user->{'repository'}->{'root'}; - my $sandbox = $user->{'paths'}->{'users_dir'}; - my @vcs_output = (); - my @vcs_error = (); - my $vcsroot; - - if ( $repo_type eq 'CVS' ) { - if ( $connection eq 'local' ) { - $vcsroot = "$root"; - } else { - $vcsroot = ":$connection:$vcs_username\@$server:$root"; - } - } - - my $repository = SandWeb::Repository->new( - root => $vcsroot, - repo_type => $repo_type, - sandbox => "$users_dir/$username", - ); - - # this is where the Repository object is used - # can't give the leading / to the VCS - $location =~ s/\///; - - foreach my $file (@file_list) { - %return = $repository->$vcs_command( - file => "$location/$file", - ); - push (@vcs_output, "$return{'output'}\n"); - push (@vcs_error, "$return{'error'}\n"); - } - my $content = $ui->get_menu( - MENU => 'vcs_output', - LOCATION => $location, - FILENAME => "@file_list", - PROGNAME => $progname, - VCS_OUTPUT => "@vcs_output", - VCS_ERROR => "@vcs_error", - ); - print CGI::header( -cookie => $ck_auth ); - $ui->print_screen( - TITLE=> "SandWeb : VCS $vcs_command", - MENU_TITLE => 'SandWeb', - SUBMENU_TITLE => "VCS $vcs_command", - FOOTER => '', - CONTENT => $content, - ERROR => $error, - ); -} ############################################################################### @@ -1497,70 +1449,4 @@ # exit 0; } - -sub commit_commit { - my %args = @_; - - my $ck_auth = $args{'ck_auth'}; - unless ($ck_auth) { - &login_menu(); - exit 0; - } - if (! load_config()) { - # no existing user config, forward to prefs menu - preferences_menu( ck_auth => $ck_auth ); - } - my @file_list = $args{'file_list'}; - my $location = $args{'location'}; - my $message = CGI::param('message'); - my $username = $auth->get_userinfo('username'); - my $template_dir = $config->{'paths'}->{'template_dir'}; - my $users_dir = $config->{'paths'}->{'users_dir'}; - my %return; - my $server = $user->{'repository'}->{'server'}; - my $vcs_username = $user->{'repository'}->{'username'}; - my $repo_type = $user->{'repository'}->{'repo_type'}; - my $connection = $user->{'repository'}->{'connection'}; - my $root = $user->{'repository'}->{'root'}; - my $sandbox = $user->{'paths'}->{'users_dir'}; - my @vcs_output = (); - my @vcs_error = (); - my $vcsroot; - - my $repository = SandWeb::Repository->new( - root => $vcsroot, - repo_type => $repo_type, - sandbox => "$users_dir/$username", - ); - - # can't give the leading / to the VCS - $location =~ s/\///; - foreach my $file (@file_list) { - %return = $repository->commit( - file => "$location/$file", - message => "$message", - ); - push (@vcs_output, "$return{'output'}\n"); - push (@vcs_error, "$return{'error'}\n"); - } - - my $content = $ui->get_menu( - MENU => 'vcs_output', - LOCATION => $location, - PROGNAME => $progname, - VCS_OUTPUT => "@vcs_output", - VCS_ERROR => "@vcs_error", - ); - print CGI::header( -cookie => $ck_auth ); - $ui->print_screen( - TITLE=> "SandWeb : VCS commit", - MENU_TITLE => 'SandWeb', - SUBMENU_TITLE => "VCS commit", - FOOTER => '', - CONTENT => $content, - ERROR => $error, - ); - exit 0; -} - ############################################################################### |
From: Rob H. <for...@us...> - 2002-02-13 04:14:59
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv11500 Modified Files: sandweb.cgi Log Message: merging vcsaction split changes Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.162 retrieving revision 1.163 diff -U2 -r1.162 -r1.163 --- sandweb.cgi 13 Feb 2002 04:08:43 -0000 1.162 +++ sandweb.cgi 13 Feb 2002 04:14:55 -0000 1.163 @@ -106,4 +106,5 @@ my $submit = CGI::param('Submit'); my $vcs_command = CGI::param('vcs_command'); + my @file_list = CGI::param('file_list'); ####################################################### @@ -129,5 +130,5 @@ } elsif ( $action eq 'preferences_menu' ) { - if (! CGI::param('Submit')) { + if (! $submit ) { # call preferences menu preferences_menu( ck_auth => $ck_auth ); @@ -164,4 +165,16 @@ ); } + elsif ( $action eq 'browse_vcs_commit' ) { + # called vcs commit from browse + my $location = CGI::param('location'); + unless ($location) { + $location = ""; + } + browse_vcs_commit( + ck_auth => $ck_auth, + location => $location, + vcs_command => $vcs_command, + ); + } elsif ( $action eq 'file' ) { # called file manipulator @@ -877,20 +890,6 @@ } -############################################################################### -# vcsaction -# -# all VCS actions are caught by this subroutine, and dealt -# with by calling the appropriate Repository method. -# -# A Repository object is created and used. -# -# args: -# ck_auth - the sessions cookie -# vcs_command - name of the Repository object method to be invoked -# filename - name of the file(s) that the vcs_command should -# be used with. NOTE: this is an array -# location - system path to the file(s) specified by filename -############################################################################### -sub vcsaction { + +sub checkout_menu { my %args = @_; @@ -942,86 +941,24 @@ sandbox => "$users_dir/$username", ); - if ( $vcs_command eq 'commit' ) { - if ($message) { - # can't give the leading / to the VCS - $location =~ s/\///; - foreach my $file (@filename) { - %return = $repository->commit( - file => "$location/$file", - message => "$message", - ); - push (@vcs_output, "$return{'output'}\n"); - push (@vcs_error, "$return{'error'}\n"); - } - my $content = $ui->get_menu( - MENU => 'vcs_output', - LOCATION => $location, - PROGNAME => $progname, - VCS_OUTPUT => "@vcs_output", - VCS_ERROR => "@vcs_error", - ); - print CGI::header( -cookie => $ck_auth ); - $ui->print_screen( - TITLE=> "SandWeb : VCS $vcs_command", - MENU_TITLE => 'SandWeb', - SUBMENU_TITLE => "VCS $vcs_command", - FOOTER => '', - CONTENT => $content, - ERROR => $error, - ); - exit 0; - } - my $content = $ui->get_menu( - MENU => 'commit', - LOCATION => $location, - PROGNAME => $progname, - FILENAME => "@filename", - ); - print CGI::header( -cookie => $ck_auth ); - $ui->print_screen( - TITLE=> 'SandWeb : commit file(s)', - MENU_TITLE => 'SandWeb', - SUBMENU_TITLE => 'commit file(s)', - FOOTER => '', - CONTENT => $content, - ERROR => $error, - ); - exit 0; - } - else { - # this is where the Repository object is used - # can't give the leading / to the VCS - $location =~ s/\///; - - foreach my $file (@filename) { - %return = $repository->$vcs_command( - file => "$location/$file", - ); - push (@vcs_output, "$return{'output'}\n"); - push (@vcs_error, "$return{'error'}\n"); - } - } - my $content = $ui->get_menu( - MENU => 'vcs_output', - LOCATION => $location, - FILENAME => "@filename", - PROGNAME => $progname, - VCS_OUTPUT => "@vcs_output", - VCS_ERROR => "@vcs_error", - ); - print CGI::header( -cookie => $ck_auth ); - $ui->print_screen( - TITLE=> "SandWeb : VCS $vcs_command", - MENU_TITLE => 'SandWeb', - SUBMENU_TITLE => "VCS $vcs_command", - FOOTER => '', - CONTENT => $content, - ERROR => $error, - ); - exit 0; + my $content = $ui->get_menu( + MENU => 'checkout', + LOCATION => $location, + PROGNAME => $progname, + ); + + print CGI::header( -cookie => $ck_auth ); + $ui->print_screen( + TITLE=> 'SandWeb : checkout', + MENU_TITLE => 'SandWeb', + SUBMENU_TITLE => 'checkout', + FOOTER => '', + CONTENT => $content, + ERROR => $error, + ); + exit 0; } -sub checkout_menu { +sub commit_menu { my %args = @_; my $ck_auth = $args{'ck_auth'}; @@ -1034,5 +971,22 @@ preferences_menu( ck_auth => $ck_auth ); } - + + my @file_list = $args{'file_list'}; + my $location = $args{'location'}; + my $message = CGI::param('message'); + my $username = $auth->get_userinfo('username'); + my $template_dir = $config->{'paths'}->{'template_dir'}; + my $users_dir = $config->{'paths'}->{'users_dir'}; + my %return; + my $server = $user->{'repository'}->{'server'}; + my $vcs_username = $user->{'repository'}->{'username'}; + my $repo_type = $user->{'repository'}->{'repo_type'}; + my $connection = $user->{'repository'}->{'connection'}; + my $root = $user->{'repository'}->{'root'}; + my $sandbox = $user->{'paths'}->{'users_dir'}; + my @vcs_output = (); + my @vcs_error = (); + my $vcsroot; + my @repos = sort keys %{$user->{'repo'}}; @@ -1040,11 +994,11 @@ MENU => 'checkout', PROGNAME => $progname, + FILENAME => "@file_list", ); - print CGI::header( -cookie => $ck_auth ); $ui->print_screen( - TITLE=> 'SandWeb : checkout', + TITLE=> 'SandWeb : commit file(s)', MENU_TITLE => 'SandWeb', - SUBMENU_TITLE => 'checkout', + SUBMENU_TITLE => 'commit file(s)', FOOTER => '', CONTENT => $content, @@ -1052,5 +1006,5 @@ ); exit 0; -} +} ############################################################################### @@ -1372,4 +1326,100 @@ ## +############################################################################### +# browse_vcs_commit +# +# VCS actions from browse_menu are caught by this subroutine, and dealt +# with by calling the appropriate Repository method. +# +# A Repository object is created and used. +# +# args: +# ck_auth - the sessions cookie +# vcs_command - name of the Repository object method to be invoked +# filename - name of the file(s) that the vcs_command should +# be used with. NOTE: this is an array +# location - system path to the file(s) specified by filename +############################################################################### + +sub browse_vcs_commit { + my %args = @_; + + my $ck_auth = $args{'ck_auth'}; + unless ($ck_auth) { + &login_menu(); + exit 0; + } + if (! load_config()) { + # no existing user config, forward to prefs menu + preferences_menu( ck_auth => $ck_auth ); + } + + my $vcs_command = $args{'vcs_command'}; + my @filename = (); + my $count = 0; + while ( $args{'filename'}->[$count] ) { + push (@filename, $args{'filename'}->[$count]); + $count++; + } + my @file_list = $args{'file_list'}; + my $location = $args{'location'}; + my $message = CGI::param('message'); + my $username = $auth->get_userinfo('username'); + my $template_dir = $config->{'paths'}->{'template_dir'}; + my $users_dir = $config->{'paths'}->{'users_dir'}; + my %return; + my $server = $user->{'repository'}->{'server'}; + my $vcs_username = $user->{'repository'}->{'username'}; + my $repo_type = $user->{'repository'}->{'repo_type'}; + my $connection = $user->{'repository'}->{'connection'}; + my $root = $user->{'repository'}->{'root'}; + my $sandbox = $user->{'paths'}->{'users_dir'}; + my @vcs_output = (); + my @vcs_error = (); + my $vcsroot; + + if ( $repo_type eq 'CVS' ) { + if ( $connection eq 'local' ) { + $vcsroot = "$root"; + } else { + $vcsroot = ":$connection:$vcs_username\@$server:$root"; + } + } + + my $repository = SandWeb::Repository->new( + root => $vcsroot, + repo_type => $repo_type, + sandbox => "$users_dir/$username", + ); + + # this is where the Repository object is used + # can't give the leading / to the VCS + $location =~ s/\///; + + foreach my $file (@file_list) { + %return = $repository->$vcs_command( + file => "$location/$file", + ); + push (@vcs_output, "$return{'output'}\n"); + push (@vcs_error, "$return{'error'}\n"); + } + my $content = $ui->get_menu( + MENU => 'vcs_output', + LOCATION => $location, + FILENAME => "@file_list", + PROGNAME => $progname, + VCS_OUTPUT => "@vcs_output", + VCS_ERROR => "@vcs_error", + ); + print CGI::header( -cookie => $ck_auth ); + $ui->print_screen( + TITLE=> "SandWeb : VCS $vcs_command", + MENU_TITLE => 'SandWeb', + SUBMENU_TITLE => "VCS $vcs_command", + FOOTER => '', + CONTENT => $content, + ERROR => $error, + ); +} ############################################################################### @@ -1447,4 +1497,70 @@ # exit 0; } + +sub commit_commit { + my %args = @_; + + my $ck_auth = $args{'ck_auth'}; + unless ($ck_auth) { + &login_menu(); + exit 0; + } + if (! load_config()) { + # no existing user config, forward to prefs menu + preferences_menu( ck_auth => $ck_auth ); + } + my @file_list = $args{'file_list'}; + my $location = $args{'location'}; + my $message = CGI::param('message'); + my $username = $auth->get_userinfo('username'); + my $template_dir = $config->{'paths'}->{'template_dir'}; + my $users_dir = $config->{'paths'}->{'users_dir'}; + my %return; + my $server = $user->{'repository'}->{'server'}; + my $vcs_username = $user->{'repository'}->{'username'}; + my $repo_type = $user->{'repository'}->{'repo_type'}; + my $connection = $user->{'repository'}->{'connection'}; + my $root = $user->{'repository'}->{'root'}; + my $sandbox = $user->{'paths'}->{'users_dir'}; + my @vcs_output = (); + my @vcs_error = (); + my $vcsroot; + + my $repository = SandWeb::Repository->new( + root => $vcsroot, + repo_type => $repo_type, + sandbox => "$users_dir/$username", + ); + + # can't give the leading / to the VCS + $location =~ s/\///; + foreach my $file (@file_list) { + %return = $repository->commit( + file => "$location/$file", + message => "$message", + ); + push (@vcs_output, "$return{'output'}\n"); + push (@vcs_error, "$return{'error'}\n"); + } + + my $content = $ui->get_menu( + MENU => 'vcs_output', + LOCATION => $location, + PROGNAME => $progname, + VCS_OUTPUT => "@vcs_output", + VCS_ERROR => "@vcs_error", + ); + print CGI::header( -cookie => $ck_auth ); + $ui->print_screen( + TITLE=> "SandWeb : VCS commit", + MENU_TITLE => 'SandWeb', + SUBMENU_TITLE => "VCS commit", + FOOTER => '', + CONTENT => $content, + ERROR => $error, + ); + exit 0; +} + ############################################################################### |
From: Nick J. <nje...@us...> - 2002-02-13 04:08:45
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv10487 Modified Files: sandweb.cgi Log Message: * fixing up checkout_menu() (for checking out a module) Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.161 retrieving revision 1.162 diff -U2 -r1.161 -r1.162 --- sandweb.cgi 13 Feb 2002 03:39:36 -0000 1.161 +++ sandweb.cgi 13 Feb 2002 04:08:43 -0000 1.162 @@ -1025,7 +1025,6 @@ sub checkout_menu { my %args = @_; - my $ck_auth = $args{'ck_auth'}; - unless ($ck_auth) { + unless ($ck_auth) { &login_menu(); exit 0; @@ -1036,45 +1035,8 @@ } - my $vcs_command = $args{'vcs_command'}; - my @filename = (); - my $count = 0; - while ( $args{'filename'}->[$count] ) { - push (@filename, $args{'filename'}->[$count]); - $count++; - } - my $location = $args{'location'}; - my $message = CGI::param('message'); - my $username = $auth->get_userinfo('username'); - my $template_dir = $config->{'paths'}->{'template_dir'}; - my $users_dir = $config->{'paths'}->{'users_dir'}; - my %return; - #XXX - not accessing $user->{'repo'}->{$repo_name}* - my $server = $user->{'repository'}->{'server'}; - my $vcs_username = $user->{'repository'}->{'username'}; - my $repo_type = $user->{'repository'}->{'repo_type'}; - my $connection = $user->{'repository'}->{'connection'}; - my $root = $user->{'repository'}->{'root'}; - my $sandbox = $user->{'paths'}->{'users_dir'}; - my @vcs_output = (); - my @vcs_error = (); - my $vcsroot; - - if ( $repo_type eq 'CVS' ) { - if ( $connection eq 'local' ) { - $vcsroot = "$root"; - } else { - $vcsroot = ":$connection:$vcs_username\@$server:$root"; - } - } - - my $repository = SandWeb::Repository->new( - root => $vcsroot, - repo_type => $repo_type, - sandbox => "$users_dir/$username", - ); + my @repos = sort keys %{$user->{'repo'}}; my $content = $ui->get_menu( MENU => 'checkout', - LOCATION => $location, PROGNAME => $progname, ); @@ -1422,12 +1384,34 @@ sub checkout_commit { -# my %args = @_; -# my $ck_auth = $args{'ck_auth'}; -# unless ($ck_auth) { -# &login_menu(); -# exit 0; -# } -# # this is where the Repository object is used -# + my %args = @_; + my $ck_auth = $args{'ck_auth'}; + unless ($ck_auth) { + &login_menu(); + exit 0; + } + # this is where the Repository object is used + my $server = $user->{'repository'}->{'server'}; + my $vcs_username = $user->{'repository'}->{'username'}; + my $repo_type = $user->{'repository'}->{'repo_type'}; + my $connection = $user->{'repository'}->{'connection'}; + my $root = $user->{'repository'}->{'root'}; + + my $sandbox = $user->{'paths'}->{'users_dir'}; + my @vcs_output = (); + my @vcs_error = (); + my $vcsroot; + + my $username = $auth->get_userinfo('username'); + my $template_dir = $config->{'paths'}->{'template_dir'}; + my $users_dir = $config->{'paths'}->{'users_dir'}; + + if ( $repo_type eq 'CVS' ) { + if ( $connection eq 'local' ) { + $vcsroot = "$root"; + } else { + $vcsroot = ":$connection:$vcs_username\@$server:$root"; + } + } + # foreach my $file (@filename) { # %return = $repository->$vcs_command( @@ -1437,4 +1421,10 @@ # push (@vcs_error, "$return{'error'}\n"); # } +# +# my $repository = SandWeb::Repository->new( +# root => $vcsroot, +# repo_type => $repo_type, +# sandbox => "$users_dir/$username", +# ); # # my $content = $ui->get_menu( |
From: Nick J. <nje...@us...> - 2002-02-13 04:08:36
|
Update of /cvsroot/sandweb/sandweb/templates In directory usw-pr-cvs1:/tmp/cvs-serv10424 Modified Files: checkout.html sandbox.html Log Message: * fixing up checkout_menu() (for checking out a module) Index: checkout.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/checkout.html,v retrieving revision 1.9 retrieving revision 1.10 diff -U2 -r1.9 -r1.10 --- checkout.html 2 Feb 2002 09:04:34 -0000 1.9 +++ checkout.html 13 Feb 2002 04:08:34 -0000 1.10 @@ -1,14 +1,13 @@ +<form submit="<TMPL_VAR NAME=PROGNAME>"> <tr> <td width="100%"> - Please enter module name to checkout from repository <select><option>My First Repo(tm)</option></select>: + Select repository: <select size="1" name="repository_name"> + <option selected>My First Repo(tm)</option> + </select> <br /> <br /> - <form submit="<TMPL_VAR NAME=PROGNAME>"> - <input type="hidden" name="action" value="vcsaction" /> - <input type="hidden" name="location" value="<TMPL_VAR NAME=LOCATION>" /> - <input type="hidden" name="vcs_command" value="checkout" /> - <input type="text" name="filename" /> - <input type="submit" name="checkout" value="Done" /> - <TMPL_VAR NAME=ERROR> - </form> + Enter module name to checkout: <input type="text" name="module_name" size="12" maxlength="24" /> + <br /> <br /> + <input type="submit" name="Submit" value="Checkout" /> </td> </tr> +</form> Index: sandbox.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/sandbox.html,v retrieving revision 1.6 retrieving revision 1.7 diff -U2 -r1.6 -r1.7 --- sandbox.html 1 Feb 2002 03:44:03 -0000 1.6 +++ sandbox.html 13 Feb 2002 04:08:34 -0000 1.7 @@ -6,5 +6,5 @@ </td> <td width="20%" align="center"> - [<a href="<TMPL_VAR NAME=PROGNAME>?action=module_checkout_menu">checkout a module</a>] + [<a href="<TMPL_VAR NAME=PROGNAME>?action=checkout_menu">checkout a module</a>] </td> </tr> |
From: Rob H. <for...@us...> - 2002-02-13 03:39:39
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv4962 Modified Files: sandweb.cgi Log Message: moved checkout to checkout_menu and checkout_commit Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.160 retrieving revision 1.161 diff -U2 -r1.160 -r1.161 --- sandweb.cgi 11 Feb 2002 08:55:33 -0000 1.160 +++ sandweb.cgi 13 Feb 2002 03:39:36 -0000 1.161 @@ -96,14 +96,14 @@ } # has valid auth cookie - my $repository_selected = CGI::param('repository_selected'); - my $repo_name = CGI::param('repo_name'); - my $repo_server = CGI::param('repo_server'); - my $repo_username = CGI::param('repo_username'); - my $repo_type = CGI::param('repo_type'); - my $repo_connection = CGI::param('repo_connection'); - my $repo_root = CGI::param('repo_root'); - my $new_repository = CGI::param('new_repository'); - my $submit = CGI::param('Submit'); - + my $repository_selected = CGI::param('repository_selected'); + my $repo_name = CGI::param('repo_name'); + my $repo_server = CGI::param('repo_server'); + my $repo_username = CGI::param('repo_username'); + my $repo_type = CGI::param('repo_type'); + my $repo_connection = CGI::param('repo_connection'); + my $repo_root = CGI::param('repo_root'); + my $new_repository = CGI::param('new_repository'); + my $submit = CGI::param('Submit'); + my $vcs_command = CGI::param('vcs_command'); ####################################################### @@ -198,4 +198,10 @@ ); } + elsif ( $action eq 'checkout_menu' ) { + # called checkout menu + checkout_menu( + ck_auth => $ck_auth, + ); + } elsif ( $action eq 'vcs_prefs_menu' ) { # called VCS preferences @@ -936,22 +942,5 @@ sandbox => "$users_dir/$username", ); - if ( $vcs_command eq 'checkout' ) { - my $content = $ui->get_menu( - MENU => 'checkout', - LOCATION => $location, - PROGNAME => $progname, - ); - print CGI::header( -cookie => $ck_auth ); - $ui->print_screen( - TITLE=> 'SandWeb : checkout', - MENU_TITLE => 'SandWeb', - SUBMENU_TITLE => 'checkout', - FOOTER => '', - CONTENT => $content, - ERROR => $error, - ); - exit 0; - } - elsif ( $vcs_command eq 'commit' ) { + if ( $vcs_command eq 'commit' ) { if ($message) { # can't give the leading / to the VCS @@ -1002,4 +991,5 @@ } else { + # this is where the Repository object is used # can't give the leading / to the VCS $location =~ s/\///; @@ -1033,4 +1023,72 @@ } +sub checkout_menu { + my %args = @_; + + my $ck_auth = $args{'ck_auth'}; + unless ($ck_auth) { + &login_menu(); + exit 0; + } + if (! load_config()) { + # no existing user config, forward to prefs menu + preferences_menu( ck_auth => $ck_auth ); + } + + my $vcs_command = $args{'vcs_command'}; + my @filename = (); + my $count = 0; + while ( $args{'filename'}->[$count] ) { + push (@filename, $args{'filename'}->[$count]); + $count++; + } + my $location = $args{'location'}; + my $message = CGI::param('message'); + my $username = $auth->get_userinfo('username'); + my $template_dir = $config->{'paths'}->{'template_dir'}; + my $users_dir = $config->{'paths'}->{'users_dir'}; + my %return; + #XXX - not accessing $user->{'repo'}->{$repo_name}* + my $server = $user->{'repository'}->{'server'}; + my $vcs_username = $user->{'repository'}->{'username'}; + my $repo_type = $user->{'repository'}->{'repo_type'}; + my $connection = $user->{'repository'}->{'connection'}; + my $root = $user->{'repository'}->{'root'}; + my $sandbox = $user->{'paths'}->{'users_dir'}; + my @vcs_output = (); + my @vcs_error = (); + my $vcsroot; + + if ( $repo_type eq 'CVS' ) { + if ( $connection eq 'local' ) { + $vcsroot = "$root"; + } else { + $vcsroot = ":$connection:$vcs_username\@$server:$root"; + } + } + + my $repository = SandWeb::Repository->new( + root => $vcsroot, + repo_type => $repo_type, + sandbox => "$users_dir/$username", + ); + + my $content = $ui->get_menu( + MENU => 'checkout', + LOCATION => $location, + PROGNAME => $progname, + ); + + print CGI::header( -cookie => $ck_auth ); + $ui->print_screen( + TITLE=> 'SandWeb : checkout', + MENU_TITLE => 'SandWeb', + SUBMENU_TITLE => 'checkout', + FOOTER => '', + CONTENT => $content, + ERROR => $error, + ); + exit 0; +} ############################################################################### @@ -1352,4 +1410,52 @@ ## + +############################################################################### +# checkout commit +# +# Uses the Repository object to do a checkout of specified module +# +# args: +# ck_auth - the sessions cookie +# module - module name to checkout +############################################################################### + +sub checkout_commit { +# my %args = @_; +# my $ck_auth = $args{'ck_auth'}; +# unless ($ck_auth) { +# &login_menu(); +# exit 0; +# } +# # this is where the Repository object is used +# +# foreach my $file (@filename) { +# %return = $repository->$vcs_command( +# file => "$location/$file", +# ); +# push (@vcs_output, "$return{'output'}\n"); +# push (@vcs_error, "$return{'error'}\n"); +# } +# +# my $content = $ui->get_menu( +# MENU => 'vcs_output', +# LOCATION => $location, +# FILENAME => "@filename", +# PROGNAME => $progname, +# VCS_OUTPUT => "@vcs_output", +# VCS_ERROR => "@vcs_error", +# ); +# print CGI::header( -cookie => $ck_auth ); +# $ui->print_screen( +# TITLE=> "SandWeb : VCS $vcs_command", +# MENU_TITLE => 'SandWeb', +# SUBMENU_TITLE => "VCS $vcs_command", +# FOOTER => '', +# CONTENT => $content, +# ERROR => $error, +# ); +# exit 0; +} + ############################################################################### # preferences commit @@ -1455,4 +1561,6 @@ repository_menu( ck_auth => $ck_auth, repository_selected => $repo_name ); } + + |
From: Nick J. <nje...@us...> - 2002-02-11 08:55:37
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv11980/bin Modified Files: sandweb.cgi Log Message: * default menu now sandbox menu Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.159 retrieving revision 1.160 diff -U2 -r1.159 -r1.160 --- sandweb.cgi 11 Feb 2002 02:47:15 -0000 1.159 +++ sandweb.cgi 11 Feb 2002 08:55:33 -0000 1.160 @@ -113,5 +113,5 @@ unless ($action) { # with auth cookie, default is main_menu - main_menu( ck_auth => $ck_auth ); + sandbox_menu( ck_auth => $ck_auth ); } else { @@ -944,7 +944,7 @@ print CGI::header( -cookie => $ck_auth ); $ui->print_screen( - TITLE=> 'SandWeb : checkout file', + TITLE=> 'SandWeb : checkout', MENU_TITLE => 'SandWeb', - SUBMENU_TITLE => 'checkout file', + SUBMENU_TITLE => 'checkout', FOOTER => '', CONTENT => $content, |
From: Nick J. <nje...@us...> - 2002-02-11 02:47:19
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv11648/bin Modified Files: sandweb.cgi Log Message: * repository menu now seems to be fully working. next is to add support to check out a module menu. Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.158 retrieving revision 1.159 diff -U2 -r1.158 -r1.159 --- sandweb.cgi 11 Feb 2002 02:02:53 -0000 1.158 +++ sandweb.cgi 11 Feb 2002 02:47:15 -0000 1.159 @@ -1142,4 +1142,11 @@ # repository selected was 'add new repository' # new repository display + $repo_name = ''; + $repo_server = ''; + $repo_username = ''; + $repo_connection = ''; + $repo_type = ''; + $repo_root = ''; + } elsif ($repository_selected) { # display existing repository @@ -1174,9 +1181,15 @@ my @loop_repo_type = (); + $log->debug('@repos: '. join('-', @repos). "\nrepository_selected: '$repository_selected'\n"); foreach my $repo (@repos) { + chomp $repo; my %entries; - if (($repository_selected eq $repo) && ($repository_selected != $new_string)) { + $log->debug("-- REPO: $repository_selected = $repo && $repository_selected != $new_string\n"); + if ($repository_selected eq $repo) { + # Doesn't seem to work!?? ($repository_selected != $new_string)) { + $log->debug("-- REPO: TRUE\n"); $entries{REPOSITORY_ENTRY} = "<option selected>$repo</option>"; } else { + $log->debug("-- REPO: FALSE\n"); $entries{REPOSITORY_ENTRY} = "<option>$repo</option>"; } |
From: Nick J. <nje...@us...> - 2002-02-11 02:47:18
|
Update of /cvsroot/sandweb/sandweb/templates In directory usw-pr-cvs1:/tmp/cvs-serv11648/templates Modified Files: repository.html Log Message: * repository menu now seems to be fully working. next is to add support to check out a module menu. Index: repository.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/repository.html,v retrieving revision 1.7 retrieving revision 1.8 diff -U2 -r1.7 -r1.8 --- repository.html 5 Feb 2002 06:18:50 -0000 1.7 +++ repository.html 11 Feb 2002 02:47:15 -0000 1.8 @@ -3,5 +3,5 @@ function submitForm(clicked) { document.repository_menu.repository_selected.value=clicked; - document.modify_user.submit(); + document.repository_menu.submit(); } // --> |
From: Nick J. <nje...@us...> - 2002-02-11 02:02:57
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv5035 Modified Files: sandweb.cgi Log Message: * the repository menu now displays relevant info for selected repo Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.157 retrieving revision 1.158 diff -U2 -r1.157 -r1.158 --- sandweb.cgi 11 Feb 2002 00:27:32 -0000 1.157 +++ sandweb.cgi 11 Feb 2002 02:02:53 -0000 1.158 @@ -1120,4 +1120,6 @@ $log->debug("<pre>" . Dumper(\%{$user->{'repo'}}) . "</pre>"); + $repository_selected = $repository_selected || $repos[0] || $new_string; # default for pulldown + if (($repository_selected) && ($repository_selected != $new_string)) { my $valid = 0; @@ -1142,14 +1144,15 @@ } elsif ($repository_selected) { # display existing repository + $repo_name = $repository_selected; $repo_server = - $user->{'repo'}->{$repository_selected}->{'repo_server'}; + $user->{'repo'}->{$repository_selected}->{'server'}; $repo_username = - $user->{'repo'}->{$repository_selected}->{'repo_username'}; + $user->{'repo'}->{$repository_selected}->{'username'}; $repo_connection = - $user->{'repo'}->{$repository_selected}->{'repo_connection'}; + $user->{'repo'}->{$repository_selected}->{'connection'}; $repo_type = - $user->{'repo'}->{$repository_selected}->{'repo_type'}; + $user->{'repo'}->{$repository_selected}->{'type'}; $repo_root = - $user->{'repo'}->{$repository_selected}->{'repo_root'}; + $user->{'repo'}->{$repository_selected}->{'root'}; } @@ -1165,5 +1168,4 @@ my @connections = $repository->get_connections(); my @repo_types = $repository->get_repo_types(); - $repository_selected = ($repository_selected) ? $repository_selected : $repos[0]; # default for pulldown # loop data |
From: Nick J. <nje...@us...> - 2002-02-11 01:34:42
|
Update of /cvsroot/sandweb/sandweb/templates In directory usw-pr-cvs1:/tmp/cvs-serv31938/templates Modified Files: framework.html Log Message: * put the debug statements outside of main table so that their length doesn't stretch the table width Index: framework.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/framework.html,v retrieving revision 1.14 retrieving revision 1.15 diff -U2 -r1.14 -r1.15 --- framework.html 5 Feb 2002 04:25:58 -0000 1.14 +++ framework.html 11 Feb 2002 01:34:38 -0000 1.15 @@ -86,14 +86,10 @@ </tr> <tr> - <td width="100%" align="left"> - <font color="#336633"> - <TMPL_LOOP NAME="DEBUG"> - <b><TMPL_VAR NAME=DEBUG_MSG></b><br /> - </TMPL_LOOP> - </font> - </td> - </tr> - </table> - + </table> + <font color="#336633"> + <TMPL_LOOP NAME="DEBUG"> + <b><TMPL_VAR NAME=DEBUG_MSG></b><br /> + </TMPL_LOOP> + </font> </body> </html> |
From: Nick J. <nje...@us...> - 2002-02-11 00:27:38
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv21160 Modified Files: sandweb.cgi Log Message: * took care of some testing of uninitialized vars Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.156 retrieving revision 1.157 diff -U2 -r1.156 -r1.157 --- sandweb.cgi 10 Feb 2002 09:46:47 -0000 1.156 +++ sandweb.cgi 11 Feb 2002 00:27:32 -0000 1.157 @@ -64,5 +64,5 @@ ############################################################################### sub main { - my $action = CGI::param('action'); + my $action = CGI::param('action') || ''; # catch file-specific actions @@ -82,5 +82,5 @@ else { # if auth cookie exists, this will return it's data - my $ck_auth = CGI::cookie('sandweb_auth'); + my $ck_auth = CGI::cookie('sandweb_auth') || ''; if ($ck_auth) { |
From: Nick J. <nje...@us...> - 2002-02-11 00:19:21
|
Update of /cvsroot/sandweb/sandweb/lib/SandWeb In directory usw-pr-cvs1:/tmp/cvs-serv19486 Modified Files: Browse.pm Log Message: * changed some indenting Index: Browse.pm =================================================================== RCS file: /cvsroot/sandweb/sandweb/lib/SandWeb/Browse.pm,v retrieving revision 1.44 retrieving revision 1.45 diff -U2 -r1.44 -r1.45 --- Browse.pm 10 Feb 2002 09:09:22 -0000 1.44 +++ Browse.pm 11 Feb 2002 00:19:15 -0000 1.45 @@ -71,28 +71,28 @@ my @location_full = (); - unless ($count) { - my %row_data; - $row_data{LOCATION_LINK} = "[root]"; - $row_data{LOCATION_FULL} = "/"; - $row_data{PROGNAME} = "$progname"; - push (@loop_data, \%row_data); - $count++; - } + unless ($count) { + my %row_data; + $row_data{LOCATION_LINK} = "[root]"; + $row_data{LOCATION_FULL} = "/"; + $row_data{PROGNAME} = "$progname"; + push (@loop_data, \%row_data); + $count++; + } - foreach my $link (@location_link) { - my %row_data; + foreach my $link (@location_link) { + my %row_data; - if ( $link ) { - $row_data{LOCATION_LINK} = "[$link]"; - } - my $data = join("/", @location_full); + if ( $link ) { + $row_data{LOCATION_LINK} = "[$link]"; + } + my $data = join("/", @location_full); - if ($location_link[$count]) { - push (@location_full, "/$location_link[$count]"); - } - $row_data{LOCATION_FULL} = "$data"; - $row_data{PROGNAME} = "$progname"; - push (@loop_data, \%row_data); - $count++; + if ($location_link[$count]) { + push (@location_full, "/$location_link[$count]"); + } + $row_data{LOCATION_FULL} = "$data"; + $row_data{PROGNAME} = "$progname"; + push (@loop_data, \%row_data); + $count++; } |
From: Rob H. <for...@us...> - 2002-02-10 21:26:23
|
Update of /cvsroot/sandweb/sandweb/etc In directory usw-pr-cvs1:/tmp/cvs-serv14854/etc Modified Files: sandweb.cfg Log Message: hmm, not sure how it got checked in like this, on all my test systems i use /cgi-bin/sandweb/bin/sandweb.cgi not /sandweb/bin/sandweb.cgi is it just me? Index: sandweb.cfg =================================================================== RCS file: /cvsroot/sandweb/sandweb/etc/sandweb.cfg,v retrieving revision 1.16 retrieving revision 1.17 diff -U2 -r1.16 -r1.17 --- sandweb.cfg 5 Feb 2002 05:58:09 -0000 1.16 +++ sandweb.cfg 10 Feb 2002 21:26:20 -0000 1.17 @@ -16,5 +16,5 @@ <!-- config for cgi related information --> - <cgi-bin cgi_path="/sandweb/bin" + <cgi-bin cgi_path="/cgi-bin/sandweb/bin" cgi_domain="" /> |
From: Rob H. <for...@us...> - 2002-02-10 21:23:56
|
Update of /cvsroot/sandweb/sandweb/lib/SandWeb In directory usw-pr-cvs1:/tmp/cvs-serv14320/lib/SandWeb Modified Files: File.pm Log Message: better regexp loop for IE file upload workaround Index: File.pm =================================================================== RCS file: /cvsroot/sandweb/sandweb/lib/SandWeb/File.pm,v retrieving revision 1.42 retrieving revision 1.43 diff -U2 -r1.42 -r1.43 --- File.pm 10 Feb 2002 21:12:53 -0000 1.42 +++ File.pm 10 Feb 2002 21:23:52 -0000 1.43 @@ -130,12 +130,6 @@ # begin workaround for IE/Windows upload behaviour - $filename =~ /\\/; - - while ( $' =~ /\\/ ) { - $' =~ /\\/; - } - - if ( $filename =~ /\\/ ) { - $filename = $'; + while ( $filename =~ /\\/ ) { + $filename = $'; } # end workaround for IE/Windows upload behaviour |
From: Rob H. <for...@us...> - 2002-02-10 21:12:55
|
Update of /cvsroot/sandweb/sandweb/lib/SandWeb In directory usw-pr-cvs1:/tmp/cvs-serv11885/lib/SandWeb Modified Files: File.pm Log Message: put in some regexps in an attempt to workaround IE/Windows behaviour when uploading files ( it gives us the whole path starting from the drive letter, we just want the filename ) Index: File.pm =================================================================== RCS file: /cvsroot/sandweb/sandweb/lib/SandWeb/File.pm,v retrieving revision 1.41 retrieving revision 1.42 diff -U2 -r1.41 -r1.42 --- File.pm 10 Feb 2002 20:53:07 -0000 1.41 +++ File.pm 10 Feb 2002 21:12:53 -0000 1.42 @@ -129,4 +129,16 @@ my $log = $self->{'log_obj'}; +# begin workaround for IE/Windows upload behaviour + $filename =~ /\\/; + + while ( $' =~ /\\/ ) { + $' =~ /\\/; + } + + if ( $filename =~ /\\/ ) { + $filename = $'; + } +# end workaround for IE/Windows upload behaviour + my $filehandle = $args{'filehandle'}; |