Total: Today: Yesterday:
'nodejs'에 해당되는 글 3건
2019.04.23 [AWS] EC2 인스턴스에 nodejs 설치
2016.05.16 [Electron] 시작해보기!!
2016.04.05 [Windows] node.js 시작하기
노하우/Linux | 2019. 4. 23. 00:16 | Posted by 자수씨

nvm(노드 버전 관리자)을 설치

curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.32.0/install.sh | bash

nvm 활성화

. ~/.nvm/nvm.sh

npm 설치

2019년 4월 23일 기준 10.15.3 버전이 최신이므로 해당 버전을 설치

[ec2-user@~~]$ nvm install 10.15.3
########################################################################################################################################################################################################################################## 100.0%
Computing checksum with sha256sum
Checksums matched!
Now using node v10.15.3 (npm v6.4.1)
Creating default alias: default -> 10.15.3 (-> v10.15.3)

버전 확인

[ec2-user@~~]$ node -e "console.log('Running Node.js ' + process.version)"
Running Node.js v10.15.3

참고자료

연구소/electron | 2016. 5. 16. 18:54 | Posted by 자수씨

스마트 개발자 협회 페이스북(https://www.facebook.com/sda.re.kr) 에 Electron 관련 글이 올라왔길래 어떤 용도로 활용이 가능한지 보기 위해서 기본 예제를 돌려보기로 했습니다.



Electron 홈페이지(http://electron.atom.io/) 에 접속하면 아래와 같은 화면이 나옵니다.


현재 주요 버전은 Electron 이 v1.0.1, Node 가 5.10.0 기반입니다.




이제 Electron Quick Start 를 해볼 차례입니다. (사전에 nodejs 와 git 이 설치되어 있어야 합니다.)


E:\Dev\nodejs> git clone https://github.com/electron/electron-quick-start


E:\Dev\nodejs> cd electron-quick-start


E:\Dev\nodejs\electron-quick-start> npm install


E:\Dev\nodejs\electron-quick-start> npm start


엥??? 실행했더니 다음과 같은 오류가 발생합니다.


> electron-quick-start@1.0.0 start E:\Dev\nodejs\electron-quick-start

> electron main.js



npm ERR! Windows_NT 6.1.7601

npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "start"

npm ERR! node v6.1.0

npm ERR! npm  v3.8.6

npm ERR! code ELIFECYCLE

npm ERR! electron-quick-start@1.0.0 start: `electron main.js`

npm ERR! Exit status 3221225781

npm ERR!

npm ERR! Failed at the electron-quick-start@1.0.0 start script 'electron main.js'.

npm ERR! Make sure you have the latest version of node.js and npm installed.

npm ERR! If you do, this is most likely a problem with the electron-quick-start package,

npm ERR! not with npm itself.

npm ERR! Tell the author that this fails on your system:

npm ERR!     electron main.js

npm ERR! You can get information on how to open an issue for this project with:

npm ERR!     npm bugs electron-quick-start

npm ERR! Or if that isn't available, you can get their info via:

npm ERR!     npm owner ls electron-quick-start

npm ERR! There is likely additional logging output above.


npm ERR! Please include the following file with any support request:

npm ERR!     E:\Dev\nodejs\electron-quick-start\npm-debug.log


구글링을 해보니 msvcp140.dll 과 같은 VC++ 14.0 (2015) 재배포 패키지에 포함된 파일이 없어서 발생된 문제였습니다.


VC++ 14.0 (2015) 재배포 패키지 설치 페이지(https://www.microsoft.com/ko-kr/download/details.aspx?id=48145) 에 접속하여 현재 OS 에 맞게 설치합니다.


다시 실행해보겠습니다.


E:\Dev\nodejs\electron-quick-start> npm start



크롬 기반의 웹 페이지가 GUI 어플리케이션 안에 들어가 있습니다.




최근에 nodejs 로 개발자 용 관리 페이지를 만들어볼까 했었는데, Electron 으로 시도를 해봐야겠습니다.





연구소/node.js | 2016. 4. 5. 16:27 | Posted by 자수씨

1. node.js 설치하기

 - node.js 홈페이지에 접속하여 LTS 버전을 다운로드 받습니다.

 - 포스팅 작성시점에는 v4.4.2 입니다.

 - LTS 는 Long-term Support 의 약어입니다.

 - 설치가 완료되면 cmd 창에서 "node -v" 명령으로 설치가 잘되었는지 확인합니다.



2. bootstrap 설치하기

 - HTML, CSS, JS 프레임워크

 - http://bootstrapk.com/

 - nodejs 가 설치된 경로(기본설치했을 경우 "C:\Program Files\nodejs")로 이동하여 다음의 명령어를 실행합니다.

 - "npm install bootstrap"


C:\> cd C:\Program Files\nodejs

C:\> npm install bootstrap




3. grunt 설치

 - 자바스크립트 task runner (자동화된 빌드도구?)

 - http://gruntjs.com/

 - 글로벌로 설치하기 위해 "-g" 옵션으로 설치합니다.

 

C:\> npm install grunt-cli -g



4. git 설치

 - 많은 오픈소스들이 git 으로 소스관리가 되어 있기 때문에 git 을 설치합니다.

 - https://git-scm.com

 - 자세한 설정은 잘 모르기 때문에 일단 "Next" 연타로 설치 완료//




5. "bootstrap" grunt task

 - bootstrap 을 grunt 로 빌드합니다.


C:\Program Files\nodejs> cd node_modules\bootstrap

C:\Program Files\nodejs\node_modules\bootstrap> npm install







위와 같이 나오면 bootstrap 빌드 완료?




뭐가 뭔지도 모르는 상태에 일단 따라하긴 했으나 앞으로 알아야 할 것이 너무 많아 보입니다...




References

1. http://50english.blog.me/220603479539

2. https://nodejs.org/en/

3. http://bootstrapk.com/

4. http://gruntjs.com/

5. https://git-scm.com/