Programming/node.js2018. 9. 7. 15:19
embeded/odroid2018. 9. 7. 14:01

아내님 윤허를 받았으니

(얼마에 어떤거 지른다고 말하진 않음 ㅋㅋㅋ)

Power 지름!


XU4 살리기 프로젝트인데 소심해서.. eMMC는 다음기회에..

XU4 케이스는.. 나사가 없다는 이유로 한번 더 사고(일단 검은색이라 마음에 안드는 것도 있음)

U3 랑 공용으로 쓰기 위해 UART 모듈 사고(흑.. 개 비싸 ㅠㅠ)

C2 케이스는.. 라즈베리 3B용으로 맞길 빌어 보는 중(어짜피 5천원인데 머..)


배송은 다음주 화요일쯤 이라고 하니 느긋하게 기다려 봐야지 머 ㅠㅠ

아.. 집으로 보내지 말걸 그랬나?


'embeded > odroid' 카테고리의 다른 글

odroid 케이스 + 파워 도착!  (2) 2018.09.12
odroid U3 stretch  (0) 2018.09.11
odroid eMMC / SD 리더 호환성  (0) 2018.05.14
odroid u3 저전력은 안되나..  (0) 2018.04.22
odroid u3 mediawiki 설치해보니..  (0) 2018.04.19
Posted by 구차니
Programming/node.js2018. 9. 7. 13:44

부디(?) 이걸 쓸일이 아직 안생기길..


[링크 : https://www.securesign.kr/guides/Node-js-SSL-Certificates-Install]

'Programming > node.js' 카테고리의 다른 글

RESTful  (0) 2018.09.07
node.js jwt -JSON Web Token  (0) 2018.09.07
node.js exec와 JSON.parse()  (0) 2018.09.07
node.js express template  (0) 2018.09.06
node.js exec()  (0) 2018.09.06
Posted by 구차니
파일방2018. 9. 7. 11:51

REST API 문서화 시켜주고 테스트 하는 용도로 쓰이는 툴(?)


[링크 : https://swagger.io/tools/swagger-ui/]

'파일방' 카테고리의 다른 글

vworld  (0) 2019.01.13
cairo  (0) 2018.12.20
차트 관련 자바스크립트  (3) 2018.09.04
웹에서 회면 캡쳐하기  (2) 2018.09.03
무료 오프라인 지도  (4) 2018.08.31
Posted by 구차니

음.. n-trig의 한계인지 어떤진 모르겠지만

확실히 wacom EMR 펜 보다는 좋지 않다.


배터리 문제인지 모르겠으나 가끔 펜 인식이 불량함

   1. 펜인식 안됨(커서가 안뜸, 배터리 뽑았다 꽂아야 살아남)

   2. 팜 리젝션 외의 문제(이상하게 입력모드 전환되면서 키보드 자꾸 뜸)

   3. 우클릭 / 지우개 인식 불량(지우개 삭제인데 선이 그어지다가 삭제된다던가)

   4. 가끔 필기 압력이 이상하게 강해짐(역시 배터리 뽑아야)


아무튼 결론은.. wacom AES 펜을 한달 정도 써보긴 해야 비교가 가능하겠지만

wacom AES 라고 해서 이런 현상이 전혀 없던건 또 아니라 이래저래 고민중



결론: 그러니 서피스 프로 2를 사야하나..(응?)

'개소리 왈왈 > 컴퓨터' 카테고리의 다른 글

asrock a-style / hdmi-in  (0) 2018.10.22
흐음.. 역시 와콤인가?  (2) 2018.09.14
NAS 하드 교체.. ㅠㅠ  (2) 2018.09.04
월이 지났으니 지르자!  (2) 2018.09.03
으으으.. 불안하다 ㅠㅠ  (2) 2018.08.29
Posted by 구차니
Programming/node.js2018. 9. 7. 10:53

test.js

var exec = require('child_process').exec,

child;


child = exec("type test.txt", function(error, stdout, stderr)

{

console.log(stdout);

var obj = JSON.parse(stdout);

console.log(obj.name);

if(error !== null)

{

console.log(error);

}

}); 


test.txt

{

    "name": "식빵",

    "family": "웰시코기",

    "age": 1,

    "weight": 2.14

}


결과.. 으으 인코딩 건드리기 싫다...

아무튼 type으로 파일 내용 돌려받고(즉, 아무 명령어나 실행하고 그 결과를 받아)

JSON 포맷일 경우 파싱해서 사용가능한걸 실증!

D:\node_test>node test.js

{

    "name": "�Ļ�",

    "family": "�����ڱ�",

    "age": 1,

    "weight": 2.14

}

�Ļ� 


[링크 : http://tcpschool.com/json/json_basic_structure]

[링크 : https://www.w3schools.com/js/js_json_parse.asp]

'Programming > node.js' 카테고리의 다른 글

node.js jwt -JSON Web Token  (0) 2018.09.07
아직 쓸일은 없지만 걍 찾아본 node.js ssl 적용  (0) 2018.09.07
node.js express template  (0) 2018.09.06
node.js exec()  (0) 2018.09.06
node.js / express/ pug(jade) 문법  (0) 2018.09.05
Posted by 구차니
Programming/node.js2018. 9. 6. 18:54

기본 템플릿은 express-generator를 통해서 만들면 되긴 하는데


C:\> npm install -g express-generator

...

+ express-generator@4.16.0

added 10 packages in 2.2s


C:\>express --ejs


  warning: option `--ejs' has been renamed to `--view=ejs'



   create : public\

   create : public\javascripts\

   create : public\images\

   create : public\stylesheets\

   create : public\stylesheets\style.css

   create : routes\

   create : routes\index.js

   create : routes\users.js

   create : views\

   create : views\error.ejs

   create : views\index.ejs

   create : app.js

   create : package.json

   create : bin\

   create : bin\www


   install dependencies:

     > npm install


   run the app:

     > SET DEBUG=node-test:* & npm start


[링크  : http://pyrasis.com/nodejs/nodejs-HOWTO]

[링크  : https://www.npmjs.com/package/express-generator]


-g는 global의 g

[링크 : http://someoneofsunrin.tistory.com/59]



app.js 에 ejs를 기본으로 삼아서 불편할 수도 있다.

// view engine setup

app.set('views', path.join(__dirname, 'views'));

app.set('view engine', 'ejs');


어쩌다 보니(?) pug를 먼저 써서
pug를 쓰려면 조금 수정을 해주어야 한다.


아무튼.. 기본 적인 소스 틀 만들기에는 express-generator가 무난해 보인다.



+

2018.09.11


$ express --view=pug myapp 

[링크 : http://expressjs.com/ko/starter/generator.html]

'Programming > node.js' 카테고리의 다른 글

아직 쓸일은 없지만 걍 찾아본 node.js ssl 적용  (0) 2018.09.07
node.js exec와 JSON.parse()  (0) 2018.09.07
node.js exec()  (0) 2018.09.06
node.js / express/ pug(jade) 문법  (0) 2018.09.05
npm package.json  (0) 2018.09.05
Posted by 구차니
Programming/node.js2018. 9. 6. 18:45

js 라고는 해도 서버사이드로 확장되면서 서버에서는 당연히(?) 있어야 할 exec()가 추가되었다.

아무튼 exec()로 나오는 결과를 받아서 먼가 처리하는 것 까지는 해봐야 할 듯..


[링크 : https://blog.outsider.ne.kr/551]

[링크 : https://mylko72.gitbooks.io/node-js/content/chapter9/chapter9_2.html]

[링크 : https://nodejs.org/api/child_process.html]


+

2018.09.07

var exec = require('child_process').exec,

child;


child = exec("dir", function(error, stdout, stderr)

{

console.log(stdout);

if(error !== null)

{

console.log(error);

}

});


D:\node_test>node test.js

 D ����̺��� ����: �� ����

 ���� �Ϸ� ��ȣ: CCEE-4FEA


 D:\node_test ���͸�


2018-09-07  ���� 10:38    <DIR>          .

2018-09-07  ���� 10:38    <DIR>          ..

2018-09-07  ���� 10:35               195 test.js

2018-09-07  ���� 10:38                 0 test.txt

2018-09-07  ���� 10:38                 0 �� �ؽ�Ʈ ����.txt

               3�� ����                 195 ����Ʈ

               2�� ���͸�  916,882,796,544 ����Ʈ ���� 


윈도우에서 euc-kr로 받아서 그런가.. 옵션에 euc-kr encoding 해주어도 깨지는건 여전하네..

어짜피 영어로 주고 받을테니 일단 패스~ ㅠㅠ

[링크 : https://junistory.blogspot.com/2017/08/blog-post_24.html]


+

파일이 ANSI라서 보는데 이런식으로 인코딩 바꾸니 

 hild = exec("type test.txt", {encoding: 'ansi'}, function(error, stdout, stderr)


배쨴다 ㅠㅠ

D:\node_test>node test.js

<Buffer 7b 0d 0a 20 20 20 20 22 6e 61 6d 65 22 3a 20 22 bd c4 bb a7 22 2c 0d 0a 20 20 20 20 22 66 61 6d 69 6c 79 22 3a 20 22 c0 a3 bd c3 c4 da b1 e2 22 2c 0d ... > 


'Programming > node.js' 카테고리의 다른 글

node.js exec와 JSON.parse()  (0) 2018.09.07
node.js express template  (0) 2018.09.06
node.js / express/ pug(jade) 문법  (0) 2018.09.05
npm package.json  (0) 2018.09.05
nodaemon  (0) 2018.09.04
Posted by 구차니

git remote set-url origin을 통해서 변경함

 

$ git remote -v
$ git remote set-url origin https://github.com/user/repo2.git 

 

[링크 : http://minsone.github.io/git/github-managing-remotes-changing-a-remotes-url]

 

+

23.11.13

기존 리포지토리 remote 제거
git remote remove origin

새 리포지토리 remote 추가
git remote add origin https://github.com/계정/리포지토리

[링크 : https://gist.github.com/480/4681b67d2a906db8c6c1321cc678f05f]

'프로그램 사용 > Version Control' 카테고리의 다른 글

git 리비전 돌아 다니기  (0) 2018.10.18
git 상태 다시 읽기  (0) 2018.09.20
git archive (svn export)  (0) 2018.09.05
git rm 복구하기  (0) 2018.08.22
git branch  (0) 2018.08.22
Posted by 구차니
Programming/css2018. 9. 5. 18:54

키워드를 몰라서 헤매는중..

.class1.class2 이런식으로 정의된 css를 본적이 있어서

상속인지 어떤건지 몰라서 찾는 중..


[링크 : https://windtale.net/blog/maintainable-expandable-front-end-web-strategy/] << CSS 구조화 방법

[링크 : https://developer.mozilla.org/en-US/docs/Learn/CSS/Introduction_to_CSS/Cascade_and_inheritance]

[링크 : https://www.cmsfactory.net/node/11369]


[링크 : https://css-tricks.com/almanac/selectors/c/class/]

[링크 : https://stackoverflow.com/questions/18584015/multiple-dots-periods-in-css]

[링크 : https://stackoverflow.com/questions/14132276/html-css-what-do-elements-with-multiple-dots-mean?lq=1]

[링크 : https://css-tricks.com/multiple-class-id-selectors/]

'Programming > css' 카테고리의 다른 글

css tooltip 위치  (0) 2018.10.25
css로 백그라운드만 돌리기  (0) 2018.10.10
sass scss  (0) 2018.09.05
hover inline css  (0) 2018.08.27
css selector  (0) 2018.08.21
Posted by 구차니