Path: csiph.com!fu-berlin.de!uni-berlin.de!not-for-mail From: Dennis Lee Bieber Newsgroups: comp.lang.python Subject: Re: extending PATH on Windows? Date: Fri, 19 Feb 2016 19:57:59 -0500 Organization: IISS Elusive Unicorn Lines: 30 Message-ID: References: <56C72420.8020607@yahoo.no> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: news.uni-berlin.de E+YA2PD9K+I6Qg0GfjaWuAHNLier+SaSKPSsd1yV5ojw== Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.012 X-Spam-Evidence: '*H*': 0.98; '*S*': 0.00; 'subject:Windows': 0.09; 'message-id:@4ax.com': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'script,': 0.09; '.py': 0.16; '2016': 0.16; 'executable,': 0.16; 'line)': 0.16; 'locations.': 0.16; 'received:80.91.229.3': 0.16; 'received:io': 0.16; 'received:plane.gmane.org': 0.16; 'received:psf.io': 0.16; 'url:home': 0.18; '(on': 0.22; 'defined': 0.23; 'feb': 0.23; "python's": 0.23; 'command': 0.26; 'header:X-Complaints-To:1': 0.26; 'fri,': 0.27; 'locations': 0.27; 'searches': 0.29; 'regardless': 0.31; 'another': 0.32; 'run': 0.33; 'problem': 0.33; 'file': 0.34; 'path': 0.35; 'but': 0.36; 'needed': 0.36; 'tool': 0.36; '(and': 0.36; 'url:library': 0.36; 'to:addr:python-list': 0.36; 'subject:?': 0.36; 'subject:: ': 0.37; 'received:org': 0.37; 'charset:us-ascii': 0.37; 'integration': 0.38; "won't": 0.38; 'someone': 0.38; 'files': 0.38; 'to:addr:python.org': 0.40; 'where': 0.40; 'some': 0.40; 'treat': 0.72; 'url:en-us': 0.72; 'special': 0.73; 'prompt': 0.79; '"where"': 0.84; 'directory:': 0.84; "op's": 0.84; 'dennis': 0.91 X-Injected-Via-Gmane: http://gmane.org/ X-Gmane-NNTP-Posting-Host: adsl-108-68-179-144.dsl.klmzmi.sbcglobal.net X-Newsreader: Forte Agent 6.00/32.1186 X-No-Archive: YES X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.21rc2 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Xref: csiph.com comp.lang.python:103228 On Fri, 19 Feb 2016 12:42:41 -0600, eryk sun declaimed the following: >Your tool has special integration with Python's search paths, which is >cool. But for someone that wants some of these features without >installing another program and without learning PowerShell, where.exe >may suffice: > > https://technet.microsoft.com/en-us/library/cc753148 > >Search PATH and the current directory: > > C:\>where kd > C:\Program Files (x86)\Windows Kits\10\Debuggers\x64\kd.exe > Problem -- if the OP's PATH had contained the location of the add2path script, the OP might not have needed to search for it... (presuming their configuration also was set up to treat .py files as executable, entering win_add2path would be all that was needed to run it on a command line) "where" only searches the locations defined in PATH; the PowerShell (and the old command prompt equivalent) would find the file regardless of where it is (on the partition). It, therefore, won't find copies that are in other locations. -- Wulfraed Dennis Lee Bieber AF6VN wlfraed@ix.netcom.com HTTP://wlfraed.home.netcom.com/