Windows Vista Forums

PowerShell's Default Start Directory

  1. #1


    Algernon Guest

    PowerShell's Default Start Directory

    How do I change the directory that PowerShell starts in? it shows my
    "Documents and Settings\username" for a path after the prompt, but I
    just want to see "PS C:\"


      My System SpecsSystem Spec

  2. #2


    RichS Guest

    RE: PowerShell's Default Start Directory

    Do you want PowerShell to start in c:\ ?

    if so then right click the icon you use to start it and chnage the "Start
    in: " property on the Shortcut tab to be the folder where you want to start

    Do you just want the prompt to say C:\ irrespective of where you start?

    If so then change the prompt function in your profile so that it says "C:\"


    --
    Richard Siddaway
    Please note that all scripts are supplied "as is" and with no warranty
    Blog: http://richardsiddaway.spaces.live.com/
    PowerShell User Group: http://www.get-psuguk.org.uk


    "Algernon" wrote:

    > How do I change the directory that PowerShell starts in? it shows my
    > "Documents and Settings\username" for a path after the prompt, but I
    > just want to see "PS C:\"
    >
    >


      My System SpecsSystem Spec

  3. #3


    dreeschkind Guest

    RE: PowerShell's Default Start Directory

    Putting

    set-location c:\

    in your PowerShell startup script ($profile) might also be an option.

    ....\MyDocs\WindowsPowerShell\Microsoft.PowerShell_profile.ps1

    --
    greetings
    dreeschkind

    "Algernon" wrote:

    > How do I change the directory that PowerShell starts in? it shows my
    > "Documents and Settings\username" for a path after the prompt, but I
    > just want to see "PS C:\"
    >
    >


      My System SpecsSystem Spec

  4. #4


    Guest

    Re: PowerShell's Default Start Directory


    "Algernon" <kelly.dyjur@gmail.com> a écrit dans le message de news:
    1179930843.687958.327430@h2g2000hsg.googlegroups.com...
    > How do I change the directory that PowerShell starts in? it shows my
    > "Documents and Settings\username" for a path after the prompt, but I
    > just want to see "PS C:\"
    >


    in your $PROFILE file, you can add a
    Set-Location "xxxxxxxxx"
    where xxxxxxxxx is the path you want to start on.

    bye
    Nico



      My System SpecsSystem Spec


PowerShell's Default Start Directory
Similar Threads
Thread Forum
Default folder/directory Vista General
Moving Wallpaper Default Directory General Discussion
How Do You Change The Default Install Directory? General Discussion
How to change default spam directory ? Vista mail
Powershell & Active Directory PowerShell