[LON-CAPA-cvs] cvs: loncom /lonnet/perl lonnet.pm

albertel lon-capa-cvs@mail.lon-capa.org
Mon, 28 Jun 2004 15:59:50 -0000


albertel		Mon Jun 28 11:59:50 2004 EDT

  Modified files:              
    /loncom/lonnet/perl	lonnet.pm 
  Log:
  - retabinate, adn annotate things that need to get changed.
  
  
Index: loncom/lonnet/perl/lonnet.pm
diff -u loncom/lonnet/perl/lonnet.pm:1.513 loncom/lonnet/perl/lonnet.pm:1.514
--- loncom/lonnet/perl/lonnet.pm:1.513	Mon Jun 21 18:01:39 2004
+++ loncom/lonnet/perl/lonnet.pm	Mon Jun 28 11:59:50 2004
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # TCP networking package
 #
-# $Id: lonnet.pm,v 1.513 2004/06/21 22:01:39 banghart Exp $
+# $Id: lonnet.pm,v 1.514 2004/06/28 15:59:50 albertel Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -3578,25 +3578,33 @@
 
 # ------------------------------------------------------------ Portfolio Director Lister
 sub portfoliolist {
-	# returns listing of contents of user's /userfiles/portfolio/ directory
-	# 
-	my ($udom, $uname, $uhome);
-	$uname=$ENV{'user.name'};
-        $udom=$ENV{'user.domain'};
-        $uhome=$ENV{'user.home'};
-	my $listing = reply('portls:'.$uname.':'.$udom, $uhome);
-	return $listing;
+#FIXME us the ls: command instead please
+#FIXME uhome should never be an argument to any lonnet functions
+    # returns listing of contents of user's /userfiles/portfolio/ directory
+    # 
+    my ($udom,$uname,$uhome);
+    $uname=$ENV{'user.name'};
+    $udom=$ENV{'user.domain'};
+    $uhome=$ENV{'user.home'};
+    my $listing = &reply('portls:'.$uname.':'.$udom, $uhome);
+    return $listing;
 }
+
 sub portfoliomanage {
-	# handles deleting and renaming files in user's userfiles/portfolio/ directory
-	# 
-	my ($filename, $fileaction, $filenewname) = @_;
-	my ($udom, $uname, $uhome);
-	$uname=$ENV{'user.name'};
-        $udom=$ENV{'user.domain'};
-        $uhome=$ENV{'user.home'};
-	my $listing = reply('portfoliomanage:'.$uname.':'.$udom.':'.$filename.':'.$fileaction.':'.$filenewname, $uhome);
-	return $listing;
+
+#FIXME please user the existing remove userfile function instead and
+#add a userfilerename functions.
+#FIXME uhome should never be an argument to any lonnet functions
+
+    # handles deleting and renaming files in user's userfiles/portfolio/ directory
+    # 
+    my ($filename, $fileaction, $filenewname) = @_;
+    my ($udom, $uname, $uhome);
+    $uname=$ENV{'user.name'};
+    $udom=$ENV{'user.domain'};
+    $uhome=$ENV{'user.home'};
+    my $listing = reply('portfoliomanage:'.$uname.':'.$udom.':'.$filename.':'.$fileaction.':'.$filenewname, $uhome);
+    return $listing;
 }