컴퓨터 & IT (Computer & IT)/Windows and Powershell11 [PowerShell] float 및 Double 소수점 출력 PowerShell에서 Float 혹은 Double 변수의 string format을 지정하는 방법은 아래와 같다. 1. .ToString() method 사용 [1] ToString() method를 사용하는 방법은 다음과 같다: .ToString(#.###) - #.###: digit이 사라지는 지점을 명시적으로 표기. - digit이 사리지는 지점은 반올림하여 표기함. ex) 예시 >>> $example = 123.45678 >>> $example.ToString("#.#") 123.5 >>> $example.ToString("#.##") 123.46 >>> $example.ToString("#.###") 123.457 2. [math]::Round() Method 이용 [2] [math]::Rou.. 2021. 1. 26. [Windows/PowerShell] 파워쉘 명령어 정리 1. Alias 설정 • https://learn.microsoft.com/ko-kr/powershell/module/microsoft.powershell.utility/set-alias?view=powershell-7.41) 2) 영구적으로 설정을 유지하고자 할 경우 (a) Powershell 설정 파일을 연다. • 일반적으로 Powershell의 설정파일은 `C:/Users/사용자명/Document/WindowsPowerShell`에 있음 • 또는 이미 설정파일이 생성된 경우, `vim $profile`를 통해서 이동가능 (vim은 Powershell 내에서 내가 사용하는 텍스트 편집기) (b) Powershell 설정 파일에서 - 명령어Rename-Item "ol.. 2021. 1. 24. 이전 1 2 다음