728x90

๐Ÿ“š Computer Science 24

[git] commit์ด git์— ๋ฐ˜์˜๋˜์ง€ ์•Š์„ ๋•Œ ๋Œ€์ฒ˜๋ฒ•

1. git url์— origin์œผ๋กœ ์—ฐ๊ฒฐ๋˜์–ด ์žˆ๋Š”์ง€ ํ™•์ธํ•˜์ž git remote -v 'origin https://github.com/๊ณ„์ •/๋ ˆํผ์ง€ํ† ๋ฆฌ' ๋ผ๋Š” ๊ฒฐ๊ณผ๊ฐ€ ๋‚˜์™€์•ผ ํ•œ๋‹ค. 2. ์•„๋‹ˆ๋ผ๋ฉด remote์— ๊ณ„์ • ์—ฐ๊ฒฐ์ด ์ž˜ ์•ˆ๋˜์–ด ์žˆ๋Š” ๊ฒƒ์ด๋ฏ€๋กœ ์—ฐ๊ฒฐํ•ด์ฃผ๋ฉด ๋œ๋‹ค. git remote add origin https://github.com/๊ณ„์ •/๋ฆฌํฌ์ง€ํ† ๋ฆฌ 3. ๊ทธ๋ฆฌ๊ณ  ๋‹ค์‹œ pushํ•ด๋ณด๋ฉด OK. [git ๊ณต์‹ reference ์ฐธ์กฐ] Git - ๋ฆฌ๋ชจํŠธ ์ €์žฅ์†Œ ์›๊ฒฉ ์ €์žฅ์†Œ๋ผ ํ•˜๋”๋ผ๋„ ๋กœ์ปฌ ์‹œ์Šคํ…œ์— ์œ„์น˜ํ•  ์ˆ˜๋„ ์žˆ๋‹ค. remote'' ์ €์žฅ์†Œ๋ผ๊ณ  ์ด๋ฆ„์ด ๋ถ™์–ด์žˆ์–ด๋„ ์ด ์›๊ฒฉ ์ €์žฅ์†Œ๊ฐ€ ์‚ฌ์‹ค ๊ฐ™์€ ๋กœ์ปฌ ์‹œ์Šคํ…œ์— ์กด์žฌํ•  ์ˆ˜๋„ ์žˆ๋‹ค. ์—ฌ๊ธฐ์„œ remote'' ๋ผ๋Š” ์ด๋ฆ„์€ ๋ฐ˜๋“œ git-scm.com

[git] pull ์ „์— commit ํ–ˆ์„ ๋•Œ ๋Œ€์ฒ˜๋ฒ•

commit์„ ํ–ˆ๋Š”๋ฐ, pull ๋‚ด์—ญ์ด ๋ณด์ด์ง€ ์•Š์•˜์–ด์„œ pull์„ ๋‹ค ๋ชป๋ฐ›๊ณ  commit์„ ๋จผ์ € ํ–ˆ๋‹ค๋ฉด git ์ถฉ๋Œ์ด ๋‚  ๊ฐ€๋Šฅ์„ฑ์ด ๋งŽ์ฃ . (์•„์ฃผ ๋นˆ๋ฒˆํ•œ ์‹ค์ˆ˜...ํ•˜ํ•˜) ์ด ๋•Œ์˜ ๊ฐ„๋‹จ ํ•ด๊ฒฐ๋ฒ•์„ ์•Œ์•„๋ด…์‹œ๋‹น. ์šฐ์„ , git commit ๋‚ด์—ญ์„ ์ง€์›Œ์ค๋‹ˆ๋‹ค. (์ผ๋‹จ commit ํ•œ ์ƒํƒœ๋‹ˆ๊นŒ ๋‚ด์—ญ ๊ฒ€์ƒ‰์œผ๋กœ ์‚ด๋ฆด ์ˆ˜ ์žˆ์–ด์š”! ๊ฑฑ์ • NoNo) git reset --hard HEAD^ 1) --hard ์˜ต์…˜์€ ๋Œ์•„๊ฐ€๋ ค๋Š” ์ด๋ ฅ์ดํ›„์˜ ๋ชจ๋“  ๋‚ด์šฉ์„ ์ง€์›Œ ๋ฒ„๋ฆฌ๋ฏ€๋กœ ์ปค๋ฐ‹ํ•ด์•ผํ•  ๊ฒƒ๋“ค์ด ์žˆ๋Š”์ง€ ๋‹ค์‹œ ํ•œ ๋ฒˆ ํ™•์ธํ•ด์ฃผ์„ธ์š”. 2) HEAD^๋Š” ๋ฐ”๋กœ ์ง์ „ ์ปค๋ฐ‹ 1๊ฐœ๋ฅผ ์˜๋ฏธํ•ฉ๋‹ˆ๋‹ค. ์—ฌ๋Ÿฌ๊ฐœ์˜ ์ปค๋ฐ‹์ด๋ผ๋ฉด HEAD~2 (2๊ฐœ), HEAD~3 (3๊ฐœ) ๋“ฑ์˜ ํ‘œํ˜„์„ ์‚ฌ์šฉํ•ด์ฃผ์„ธ์š”. ๋‹ค์Œ์œผ๋กœ ๋ชป ๋ฐ›์€ pull์„ ๋ฐ›์•„์ฃผ์„ธ์š”. git pull ๊ทธ ๋‹ค์Œ gi..

[Diagram] ๋‹ค์ด์–ด๊ทธ๋žจ ๊ทธ๋ฆฌ๋Š” ๋ฌด๋ฃŒ ์‚ฌ์ดํŠธ ๊ณต์œ /์ถ”์ฒœ

https://app.diagrams.net/ Flowchart Maker & Online Diagram Software Flowchart Maker and Online Diagram Software diagrams.net (formerly draw.io) is free online diagram software. You can use it as a flowchart maker, network diagram software, to create UML online, as an ER diagram tool, to design database schema, to build BPM app.diagrams.net Usecase Diagram Flow Chart Class Diagram Sequence Diagra..

[Database] SQL ๋ฌธ ์ •๋ฆฌ(์ฝ”๋”ฉ ํ…Œ์ŠคํŠธ ๋Œ€๋น„)

1. SELECT(๊ฒ€์ƒ‰) 1) ํ…Œ์ด๋ธ”์˜ ํŠน์ • ์นผ๋Ÿผ์„ ๋ถˆ๋Ÿฌ์˜ฌ ๋•Œ SELECT ์นผ๋Ÿผ๋ช… FROM ํ…Œ์ด๋ธ”๋ช…; ์—ฌ๋Ÿฌ ๊ฐœ์˜ ์นผ๋Ÿผ์„ ๋ถˆ๋Ÿฌ์˜ฌ ๋•Œ๋Š” ์ฝค๋งˆ(,)๋ฅผ ์‚ฌ์šฉํ•œ๋‹ค. SELECT ์นผ๋Ÿผ๋ช…1, ์นผ๋Ÿผ๋ช…2, ์นผ๋Ÿผ๋ช…3 FROM ํ…Œ์ด๋ธ”๋ช…; ๋ชจ๋“  ์นผ๋Ÿผ์€ * ๊ธฐํ˜ธ ์‚ฌ์šฉ SELECT * FROM ํ…Œ์ด๋ธ”๋ช…; AS ๊ตฌ๋ฌธ์„ ์‚ฌ์šฉํ•˜์—ฌ ๋ณ„๋ช…(์ƒˆ๋กœ์šด ์ด๋ฆ„)์„ ๋ถ™์ผ ์ˆ˜ ์žˆ๋‹ค. SELECT ์นผ๋Ÿผ1 AS ๋ณ„๋ช…1 FROM ํ…Œ์ด๋ธ”๋ช…; ์ค‘๋ณต์„ ์ œ์™ธํ•˜๊ณ  ๊ฐ€์ ธ์˜ค๊ณ  ์‹ถ์„ ๋•Œ๋Š” DISTINCT ์—ฐ์‚ฐ์ž๋ฅผ ์“ด๋‹ค. ๋ฐ์ดํ„ฐ๋Š” ์˜ค๋ฆ„์ฐจ์ˆœ์œผ๋กœ ์ •๋ ฌ๋œ๋‹ค. SELECT DISTINCT ์นผ๋Ÿผ๋ช… FROM ํ…Œ์ด๋ธ”๋ช…; 2) ํŠน์ • ์กฐ๊ฑด์„ ๋งŒ์กฑํ•˜๋Š” ์นผ๋Ÿผ์„ ๋ถˆ๋Ÿฌ์˜ฌ ๋•Œ SELECT ์นผ๋Ÿผ๋ช… FROM ํ…Œ์ด๋ธ”๋ช… WHERE ์นผ๋Ÿผ๋ช… = ๊ฐ’; /*์กฐ๊ฑด๋น„๊ต๋Š” =, !=, , =, IS NULL ๋“ฑ์ด ..

728x90