summaryrefslogtreecommitdiffstats
path: root/Lib/os.py
Commit message (Collapse)AuthorAgeFilesLines
* Added os.popen2() and os.popen3() for non-Windows platforms.Fred Drake2000-08-281-0/+13
|
* makedirs(), removedirs(): If the tail of the path is empty, do a secondFred Drake2000-07-251-0/+4
| | | | | | split so the logic does not fail in corner cases. This closes bug #407.
* Spelling fixes supplied by Rob W. W. Hooft. All these are fixes in eitherThomas Wouters2000-07-161-2/+2
| | | | | | | | | | comments, docstrings or error messages. I fixed two minor things in test_winreg.py ("didn't" -> "Didn't" and "Didnt" -> "Didn't"). There is a minor style issue involved: Guido seems to have preferred English grammar (behaviour, honour) in a couple places. This patch changes that to American, which is the more prominent style in the source. I prefer English myself, so if English is preferred, I'd be happy to supply a patch myself ;)
* Michael Hudson fixes a case where execv() is called (for a test) withGuido van Rossum2000-04-261-1/+1
| | | | | an empty argument list -- another patch he's checking in will make this illegal (the first argument should always be the program name).
* Michael Hudson:Guido van Rossum2000-04-251-1/+29
| | | | | | | | I think that after this patch, all objects in the os module (with names that don't start with "_") that can have docstrings, do, on Linux at least. Also fix a nit in one of my spawn* docstrings.
* Doc strings for the spawn* functions, by Michael Hudson.Guido van Rossum2000-04-211-0/+56
|
* Patch by Fred Gansevles.Guido van Rossum2000-04-041-9/+15
| | | | | | | | | | | This patch solves 2 problems of the os module. 1) Bug ID #50 (case-mismatch wiht "environ.get(..,..)" and "del environ[..]") 2) os.environ.update (dict) doesn't propagate changes to the 'real' environment (i.e doesn't call putenv) This patches also has minor changes specific for 1.6a The string module isn't used anymore, instead the strings own methods are used.
* Actually, the previous batch's comment should have been different;Guido van Rossum2000-02-041-5/+6
| | | | | | | | | | *this* set of patches is Ka-Ping's final sweep: The attached patches update the standard library so that all modules have docstrings beginning with one-line summaries. A new docstring was added to formatter. The docstring for os.py was updated to mention nt, os2, ce in addition to posix, dos, mac.
* More trivial comment -> docstring transformations by Ka-Ping Yee,Guido van Rossum2000-02-041-18/+19
| | | | | | | | | | | | | | | | | | who writes: Here is batch 2, as a big collection of CVS context diffs. Along with moving comments into docstrings, i've added a couple of missing docstrings and attempted to make sure more module docstrings begin with a one-line summary. I did not add docstrings to the methods in profile.py for fear of upsetting any careful optimizations there, though i did move class documentation into class docstrings. The convention i'm using is to leave credits/version/copyright type of stuff in # comments, and move the rest of the descriptive stuff about module usage into module docstrings. Hope this is okay.
* Oops. spawnl() and spawnle() should be implemented on Windows too.Guido van Rossum1999-11-021-7/+14
| | | | | Also added a comment that the 'p' variants (spawnvp() etc.) are *not* supported on Windows. (They could be by adding them to posixmodule.c)
* Checking in a bunch of spawn functions. These are only defined if weGuido van Rossum1999-11-021-2/+80
| | | | | | | | have fork and execv (and friends) but not spawnv. They operate exactly like the spawn functions on Windows. A limited set of needed constants is also defined (P_WAIT, P_NOWAIT etc.). Also add getenv() as a familiar alias for environ.get().
* Mark Hammond: patch for Windows/CE.Guido van Rossum1999-06-111-0/+15
|
* The case-insensitive _Environ class was lacking a case-insensitive has_key().Guido van Rossum1999-05-031-0/+2
|
* As Finn Bock points out, _P_WAIT etc. don't have a leading underscoreGuido van Rossum1999-02-221-3/+1
| | | | so they don't need to be treated specially here.
* Special-case _P_WAIT etc. for NT.Guido van Rossum1999-02-011-4/+7
|
* Enable os.path as a mostly-normal submodule, including "from os.pathFred Drake1999-01-191-0/+2
| | | | import isfile" and "import os.path".
* Support case insensitive treatment of os.environ keys on Windows andGuido van Rossum1998-08-041-8/+7
| | | | | | | | | | | DOS (as well as OS/2). I presume that making a call to putenv() with a lowercase key will actually do the right thing. I know this is so on Windows/DOS, and I expect it is so OS/2 -- but the old OS/2 code didn't assume this. (I don't know if the person who provided the OS/2 patch was clueless or just didn't care about DOS and Windows.) Also ripped out the support for pickling -- as of 1.5, this is no longer needed to make pickling work.
* Add makedirs(), removedirs(), renames() -- ESR-inspired super-versionsGuido van Rossum1998-07-241-0/+63
| | | | | of mkdir(), rmdir() and rename() that make or remove intermediate directories as well.
* introduce a new platform-specific variable: os.linesep is theGuido van Rossum1998-05-221-0/+5
| | | | | platform's line separator. \n on Unix, \r\n on DOS, OS/2 and Windows, \r on Macs.
* Reindented according to new standard, without tabs.Guido van Rossum1997-12-051-117/+131
| | | | Also added one more os2 specific piece of code, by Jeff Rush.
* _Environ(): Added __getinitargs__() method so os.environ.copy() works,Barry Warsaw1997-12-011-0/+5
| | | | | | as does unpickling, as in: pickle.loads(pickle.dumps(os.environ)). Hope this is right! Don't shoot me Guido. :-)
* os2 patch by Jeff RushGuido van Rossum1997-11-221-0/+12
|
* Write out the dynamic OS choice, to avoid exec statements.Guido van Rossum1997-08-291-51/+66
| | | | | Adding support for a new OS is now a bit more work, but I bet that 'dos' or 'nt' will cover most situations...
* Added hook to os.environ to call putenv(), if it exists.Guido van Rossum1996-07-241-0/+19
|
* make sure os.environ exists (maybe empty)Guido van Rossum1995-08-071-0/+4
|
* set mac path separator to newlineGuido van Rossum1995-03-141-1/+1
|
* add execvpe -- mix of execvp and execveGuido van Rossum1995-03-141-6/+22
|
* Import posixpath for freeze scriptGuido van Rossum1994-10-051-0/+1
|
* do fake "import posix" for freeze.py scriptGuido van Rossum1994-08-171-0/+4
|
* Merge changesGuido van Rossum1994-08-011-39/+57
|
* Some minute changes.Guido van Rossum1993-12-291-10/+20
|
* * string.py: added rindex(), rfind(); changed index() to interpretGuido van Rossum1993-11-081-0/+30
| | | | | | | | | | | negative start indices starting from the right. * ftplib.py: debug() -> set_debuglevel(); change demo to use __init__(). * os.py: added execl, execlp, and execvp. * lambda.py: removed (now that we have built-in map, reduce, bagof, lambda) * test_b{1,2}.py, testall.out: added tests for bagof, lambda, map, reduce * commands.py: use os, not posix * test_grammar.py: make it easy to disable non-portable int overflow tests * dis.py: don't abuse range()
* * os.py: _exit doesn't exist in all variations of posixGuido van Rossum1993-01-261-1/+4
| | | | * Added fcmp() to test_support.py and use it in test*.py
* New module regsub contains sub(), gsub() and split() as in nawk.Guido van Rossum1992-09-201-0/+1
| | | | | string.splitfields(s, '') now returns [s] as split() in nawk. Added _exit to exported functions of os.
* Add separatorGuido van Rossum1992-04-061-0/+3
|
* Added definition for pardir ('..')Guido van Rossum1992-03-311-2/+9
|
* Initial revisionGuido van Rossum1992-01-141-0/+26