NGMsoftware

NGMsoftware
로그인 회원가입
  • 매뉴얼
  • 학습
  • 매뉴얼

    학습


    Web nvm : 'nvm' 용어가 cmdlet, 함수, 스크립트 파일 또는 실행할 수 있는 프로그램 이름으로 인식되지 않습니다. 이…

    페이지 정보

    본문

    윈도우에서 개발 환경을 구성할 때 npm, nvm, yarn을 사용합니다. 새로운 프로젝트를 수행하면서 개발 환경 가이드(Development Environment Guide)에 nvm으로 되어 있더라구요. 저는 주로 노드만 설치해두고, 프로젝트에서 npm을 사용했는데요. nvm을 사용하면 아래와 같은 에러가 발생합니다.

    nvm : 'nvm' 용어가 cmdlet, 함수, 스크립트 파일 또는 실행할 수 있는 프로그램 이름으로 인식되지 않습니다. 
    이름이 정확한지 확인하고 경로가 포함된 경우 경로가 올바른지 검증한 다음 다시 시도하십시오.

     

    노드를 설치하면 npm은 기본 설치되지만, nvm은 윈도우 환경에서 별도로 설치해줘야 합니다. 일단 환경 변수를 확인 해볼까요? 귀찮아서 npm으로 노드를 설치하고 진행하려 했으나~ 예상하지 못한 문제로 시간을 낭비하지 않을까 걱정되어 가이드를 따르기로 했습니다. 프로젝트 개발이 촉박했거든요~

    vyJcSzY.png

     

     

    우하단에 "환경 변수"를 클릭하세요.

    WErlyPw.png

     

     

    하단의 시스템 변수에서 ①Path를 더블 클릭하세요. 환경 변수 편집창이 표시됩니다. %NVM_HOME%, %NVM_SYMLINK%, C:\Program Files\nodejs\ 3개가 모두 있어야 합니다. nvm이 안된다면 아마도~ %NVM_HOME%, %NVM_SYMLINK% 2개가 없을겁니다. 그렇다면 nvm을 설치해야 합니다.

    ovOHtPc.png

     

     

    깃헙에서 nvm 설치 파일을 다운로드 하세요.

    [ nvm download ]

     

    nvm-setup.zip 파일을 받으세요. 직접 환경을 구성하려면 nvm-noinstall.zip을 받으면 됩니다. 이것저것 귀찮으니 그냥 저처럼 nvm-setup.zip을 받아서 설치하시는게 좋을거예요~

    1swz1gx.png

     

     

    실치는 별다른게 없습니다. 그냥 다음(Next)만 계속 누르면 됩니다.

    w4AZDsS.png

     

     

    설치 위치인데... 어차피 시스템 환경 변수에 등록되기 때문에 딱히 변경할건 없습니다. 용량도 얼마 안돼기 때문에 그냥 설치 했습니다.

    9wkEnwi.png

     

     

    시스템 환경 변수에 등록할 노드의 위치입니다. 노드를 기본으로 설치했으면 아마 저 위치가 맞을겁니다.

    hIN43Pc.png

     

     

    설치가 완료되면~ 시스템 환경 변수에 등록되었기 때문에 리부팅을 한번 해야 합니다. 그리고, Visual Studio Code를 열어주세요. 이제 에러가 안나는군요^^;

    PS E:\NGMsoftware\Project\Source\oeea\frontend> nvm
    
    Running version 1.1.9.
    
    Usage:
     
      nvm arch                     : Show if node is running in 32 or 64 bit mode.
      nvm current                  : Display active version.
      nvm install <version> [arch] : The version can be a specific version, "latest" for the latest current version, or "lts" for the
                                     most recent LTS version. Optionally specify whether to install the 32 or 64 bit version (defaults
                                     to system arch). Set [arch] to "all" to install 32 AND 64 bit versions.
                                     Add --insecure to the end of this command to bypass SSL validation of the remote download server.
      nvm list [available]         : List the node.js installations. Type "available" at the end to see what can be installed. Aliased as ls.
      nvm on                       : Enable node.js version management.
      nvm off                      : Disable node.js version management.
      nvm proxy [url]              : Set a proxy to use for downloads. Leave [url] blank to see the current proxy.
                                     Set [url] to "none" to remove the proxy.
      nvm node_mirror [url]        : Set the node mirror. Defaults to https://nodejs.org/dist/. Leave [url] blank to use default url.
      nvm npm_mirror [url]         : Set the npm mirror. Defaults to https://github.com/npm/cli/archive/. Leave [url] blank to default url.
      nvm uninstall <version>      : The version must be a specific version.
      nvm use [version] [arch]     : Switch to use the specified version. Optionally use "latest", "lts", or "newest".
                                     "newest" is the latest installed version. Optionally specify 32/64bit architecture.
                                     nvm use <arch> will continue using the selected version, but switch to 32/64 bit mode.
      nvm root [path]              : Set the directory where nvm should store different versions of node.js.
                                     If <path> is not set, the current root will be displayed.
      nvm version                  : Displays the current running version of nvm for Windows. Aliased as v.
    
    PS E:\NGMsoftware\Project\Source\oeea\frontend> 

     

    개발자에게 후원하기

    MGtdv7r.png

     

    추천, 구독, 홍보 꼭~ 부탁드립니다.

    여러분의 후원이 빠른 귀농을 가능하게 해줍니다~ 답답한 도시를 벗어나 귀농하고 싶은 개발자~

    감사합니다~

    • 네이버 공유하기
    • 페이스북 공유하기
    • 트위터 공유하기
    • 카카오스토리 공유하기
    추천0 비추천0

    댓글목록

    등록된 댓글이 없습니다.