()
| 408 | # Returns the list of paths which are used by the operating system |
| 409 | # for looking up programs |
| 410 | def programs_path (): |
| 411 | raw = [] |
| 412 | names = ['PATH', 'Path', 'path'] |
| 413 | |
| 414 | for name in names: |
| 415 | raw.append(os.environ.get (name, '')) |
| 416 | |
| 417 | result = [] |
| 418 | for elem in raw: |
| 419 | if elem: |
| 420 | for p in elem.split(os.path.pathsep): |
| 421 | result.append(make(p)) |
| 422 | |
| 423 | return result |
| 424 | |
| 425 | # rule make-NT ( native ) |
| 426 | # { |