You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+20-3Lines changed: 20 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -21,16 +21,33 @@ The "out of box" experience is meant to be very familiar to PowerShell.exe users
21
21
22
22
Installation
23
23
============
24
+
First, you need to download the module. Using PsGet (http://psget.net, very easy to install), you can run:
24
25
25
-
1. Extract the `PSReadline.zip` into your `C:\Users\[User]\Documents\WindowsPowerShell\modules\PSReadline` folder. (You may have to create these directories if they don't exist)
26
+
```
27
+
psget PSReadline
28
+
```
29
+
30
+
Alternatively, download the file https://github.com/lzybkr/PSReadLine/raw/master/PSReadline.zip and extract the contents into your `C:\Users\[User]\Documents\WindowsPowerShell\modules\PSReadline` folder. (You may have to create these directories if they don't exist)
26
31
27
-
2. Edit your `C:\Users\[User]\Documents\WindowsPowerShell\Microsoft.PowerShell_profile.ps1` file (or create if not exists) and include the commands you want to load:
32
+
Next edit your profile to import the module. There are two common profile files commonly used and the instructions are slightly different for each.
33
+
34
+
The file `C:\Users\[User]\Documents\WindowsPowerShell\profile.ps1` is used for all hosts (e.g. the ISE and powershell.exe). If you already have this file, then you should add the following:
35
+
36
+
```
37
+
if ($host.Name -eq 'ConsoleHost')
38
+
{
39
+
Import-Module PSReadline
40
+
}
41
+
```
42
+
43
+
Alternatively, the file `C:\Users\[User]\Documents\WindowsPowerShell\Microsoft.PowerShell_profile.ps1` is for powershell.exe only. Using this file, you can simply add:
28
44
29
45
```
30
46
Import-Module PSReadLine
31
-
Set-PSReadlineOption -EditMode Emacs
32
47
```
33
48
49
+
In either case, you can create the appropriate file if you don't already have one.
0 commit comments