PowerShell Core 6.0 on Linux 설치하기


참고: https://blogs.msdn.microsoft.com/powershell/2017/02/01/installing-latest-powershell-core-6-0-release-on-linux-just-got-easier/

<CentOS에 설치하기>
1) PowerShell을 사용할 수 있도록 Repository 등록하기
curl https://packages.microsoft.com/config/rhel/7/prod.repo > /etc/yum.repos.d/microsoft.repo

2) PowerShell 설치하기
yum install -y powershell

3) PowerShell 실행하기
powershell

4) 몇 개의 명령어가 있는지 확인하기
Get-Command | Measure-Object
349개

5) 현재 버전 확인하기
$psversiontable
%ec%9d%b4%eb%af%b8%ec%a7%80-1

6) PowerShell에서 빠져 나오기
exit

<Ubuntu 16.04에서 설치하기>
1) public repository GPG keys 가져오기
curl https://packages.microsoft.com/keys/microsoft.asc | sudo apt-key add –

2)Microsoft Ubuntu repository 등록하기
curl https://packages.microsoft.com/config/ubuntu/16.04/prod.list | sudo tee /etc/apt/sources.list.d/microsoft.list

3) 업데이트하기
sudo apt-get update

4) PowerShell 설치하기
sudo apt-get install -y powershell

5) PowerShell 시작하기
powershell

 

 

 

 

 

 

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s