Skip to content
README.md 1,25 KB
Newer Older
Thorsten Eggeling's avatar
Thorsten Eggeling committed
# Powershell für Linux
Download: https://github.com/PowerShell/PowerShell

Installation:

```
sudo dpkg -i powershell_6.2.0-1.ubuntu.18.04_amd64.deb
sudo apt -f install
```
Thorsten Eggeling's avatar
Thorsten Eggeling committed
Alternativ binden Sie das Microsoft-Repositorium in die Ubuntu-Paketquellen ein. Sie erhalten dann automatisch Updates, wenn diese verfügbar sind.
```
wget -q https://packages.microsoft.com/config/ubuntu/18.04/packages-microsoft-prod.deb
sudo dpkg -i packages-microsoft-prod.deb
sudo apt update
sudo add-apt-repository universe
sudo apt install -y powershell
```

Nach der Installation starten Sie die Powershell in einem Terminalfenster mit
```
pwsh
```

Durch Eingabe von exit gefolgt von der Enter-Taste verlassen Sie die Powershell wieder.
Thorsten Eggeling's avatar
Thorsten Eggeling committed

Thorsten Eggeling's avatar
Thorsten Eggeling committed
## Visual Studio Code unter Linux installieren
Thorsten Eggeling's avatar
Thorsten Eggeling committed
Download: https://code.visualstudio.com/Download

Installieren Sie das heruntergeladene DEB-Paket in einem Terminalfenster mit
```
sudo dpk -i code_1.33.1-1554971066_amd64.deb
```

Thorsten Eggeling's avatar
Thorsten Eggeling committed
## Profildatei
Thorsten Eggeling's avatar
Thorsten Eggeling committed
Wo Ihre persönliche Profildatei liegen muss, erfahren Sie in der Powershell über 

Thorsten Eggeling's avatar
Thorsten Eggeling committed
```powershell
Thorsten Eggeling's avatar
Thorsten Eggeling committed
$profile
```
Profildatei erstellen:
Thorsten Eggeling's avatar
Thorsten Eggeling committed
```powershell
Thorsten Eggeling's avatar
Thorsten Eggeling committed
if (!(Test-Path -Path $profile )) { New-Item -Type File -Path $profile -Force }
```
Profildatei im Editor öffnen (Visual Studio Code):
Thorsten Eggeling's avatar
Thorsten Eggeling committed
```powershell
Thorsten Eggeling's avatar
Thorsten Eggeling committed
code $profile
```