[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [OctDev] Test web-site of new octave-forge web-site including all pa

From: Bill Denney
Subject: Re: [OctDev] Test web-site of new octave-forge web-site including all packages
Date: Tue, 10 Oct 2006 21:48:58 -0400
User-agent: Thunderbird (Windows/20060909)

John W. Eaton wrote:
On 10-Oct-2006, John Swensen wrote:

| If you are not averse to this idea, I would be willing to work on it | (probably using wget or curl, I think most machines have one of these two). | | Suggested commands:
| pkg netlist
| pkg netinstall
| pkg netupgrade

Octave now has urlwrite, which is based on curl, so you could do the
download step directly in Octave.

See also this thread:

A related functionality that I had been thinking about recently is that this modification to fileparts could be helpful. I tried to look up what the "version" output from fileparts was supposed to be so that it could be compatible, but mathworks' own documentation only returns empty. This one will see if the end of the name looks like a version (i.e. anything that's a digit or a decimal point) and return that as the version.

That should make getting something by version a bit easier.



2006-10-10  Bill Denney  <address@hidden>
   *miscellaneous/fileparts.m: make the version output functional.
Index: fileparts.m
RCS file: /cvs/octave/scripts/miscellaneous/fileparts.m,v
retrieving revision 1.11
diff -u -r1.11 fileparts.m
--- fileparts.m 10 Oct 2006 16:10:27 -0000      1.11
+++ fileparts.m 11 Oct 2006 01:43:45 -0000
@@ -42,6 +42,10 @@
        extension = "";
       version = "";
+      vermember = ismember (name, "0123456789.");
+      if vermember(length (vermember))
+       version = name(find (~ vermember, 1, "last")+1:length(name));
+      endif
       error ("fileparts: expecting filename argument to be a string");

reply via email to

[Prev in Thread] Current Thread [Next in Thread]