Skip to content

Commit 97b2e44

Browse files
committed
Update blog
1 parent 952b733 commit 97b2e44

File tree

4 files changed

+386
-0
lines changed

4 files changed

+386
-0
lines changed

content/blog/Blog Search.md

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
---
2+
title: 검색엔진에 블로그 내용 올리기
3+
tags:
4+
- Jekyll
5+
- Github
6+
date: 2017-01-03
7+
aliases:
8+
- /articles/2017-01/blog-search
9+
---
10+
11+
# **구글 네이버에 블로그 글 등록하기**
12+
13+
## 1. Jekyll Sitemap 만들기
14+
- #### /sitemap.xml 만들기
15+
16+
![[assets/posts/20170103/1.png]]
17+
18+
#### Github Sitemap.xml 확인하기
19+
![[assets/posts/20170103/sitemap.PNG]]
20+
21+
#### Local Sitemap.xml (127.0.0.1:4000/sitemap.xml) 확인하기
22+
![[assets/posts/20170103/sitemap2.PNG]]
23+
24+
## 2. Robots.txt 만들기
25+
- #### /robots.txt 만들기
26+
27+
```
28+
User-agent: *
29+
Allow: /
30+
31+
Sitemap: http://nesoy.github.io/sitemap.xml
32+
```
33+
34+
## 3. Google Search Console 등록
35+
- ##### [https://www.google.com/webmasters/#?modal_active=none](https://www.google.com/webmasters/#?modal_active=none)
36+
37+
- #### Search Console 들어가기
38+
![[assets/posts/20170103/googleSearch.PNG]]
39+
40+
- #### 속성추가하기
41+
![[assets/posts/20170103/googleSearch2.PNG]]
42+
43+
- #### Blog URL입력하기
44+
![[assets/posts/20170103/googleSearch3.PNG]]
45+
46+
- #### HTML 다운받아서 Github에 올려서 인증받기
47+
![[assets/posts/20170103/googleSearch4.PNG]]
48+
49+
- #### Sitemap 추가하기
50+
![[assets/posts/20170103/googleSearch5.PNG]]
51+
52+
## 4. Naver 등록하기
53+
- #### [http://webmastertool.naver.com/](http://webmastertool.naver.com/)
54+
- #### 위에 방법과 비슷하게 진행한다.
55+
56+
57+
## Reference
58+
- <http://dveamer.github.io/homepage/SubmitSitemap>

content/blog/Git-stash.md

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
---
2+
title: Git Stash에 대해 알아보자.
3+
tags:
4+
- Git
5+
date: 2017-05-12
6+
aliases:
7+
- /articles/2017-05/git-stash
8+
---
9+
10+
![[assets/logo/git.png]]
11+
12+
> 프로그래밍 작업을 하던 도중에 다른 작업을 하기 위해 commit하지 않고 나중에 다시 돌아와서 작업을 다시 하고 싶을 경우가 있었는데 이 경우에 Git에서 Stashing이란 기능이 있어 기록을 남기기 위해 Posting합니다.
13+
14+
## Git Stash
15+
- `Stash` 명령을 사용하면 Working Directory에서 수정한 파일만 저장한다.
16+
17+
#### 1. 현재 git status
18+
19+
![[assets/posts/20170512/1.PNG]]
20+
21+
#### 2. git stash 사용
22+
- `git stash`
23+
24+
![[assets/posts/20170512/2.PNG]]
25+
26+
#### 3. 깔끔해진 Working Tree
27+
28+
![[assets/posts/20170512/3.PNG]]
29+
30+
#### 4. Stash List 확인하기
31+
- `git stash list`
32+
33+
![[assets/posts/20170512/4.PNG]]
34+
35+
#### 5. Stash List에 저장된 Stash 적용하기
36+
- `git stash apply`
37+
- `git stash apply --index`
38+
39+
![[assets/posts/20170512/5.PNG]]
40+
41+
#### 6. 확인하기
42+
43+
![[assets/posts/20170512/6.PNG]]
44+
45+
#### 7. stash 제거하기
46+
- `stash apply` 은 stack에서 제거되지 않기 때문에 `stash drop`으로 제거할 수 있다.
47+
- `git stash drop`
48+
49+
![[assets/posts/20170512/7.PNG]]
50+
51+
## Reference
52+
- <https://git-scm.com/book/ko/v1/Git-%EB%8F%84%EA%B5%AC-Stashing>

content/blog/SpringMVC.md

Lines changed: 232 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,232 @@
1+
---
2+
title: Intellij에서 Spring MVC 시작하기
3+
tags:
4+
- Spring
5+
- Intellij
6+
date: 2017-02-05
7+
aliases:
8+
- /articles/2017-02/SpringMVC
9+
---
10+
11+
![[assets/logo/spring.png]]
12+
13+
> Intellij에서 Spring MVC를 이용하여 Hello World를 띄우기 까지 매우 많은 삽질을 통해 해결했다. 많은 이들이 포스팅을 통해서 삽질을 그나마 줄일 수 있다면 좋겠다.
14+
15+
## Intellij Maven Project 만들기
16+
17+
- New Project - Maven - Create from archetype(해제하기)
18+
19+
![[assets/posts/20170204/1.PNG]]
20+
21+
## Project SpringMVC Framework 추가하기
22+
23+
- Add Framework Support
24+
25+
![[assets/posts/20170204/2.PNG]]
26+
27+
- Spring - Spring MVC 체크하기
28+
29+
![[assets/posts/20170204/3.PNG]]
30+
31+
## Spring MVC Library 다운로드 완료 후 Project 모습
32+
![[assets/posts/20170204/4.PNG]]
33+
34+
## web.xml 변경하기
35+
- servlet-mapping의 url-pattern변경하기 : ``` *.form -> / ```
36+
- 변경 전 web.xml
37+
38+
![[assets/posts/20170204/5.PNG]]
39+
40+
- 변경 후 web.xml
41+
42+
```xml
43+
<?xml version="1.0" encoding="UTF-8"?>
44+
<web-app xmlns="http://xmlns.jcp.org/xml/ns/javaee"
45+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
46+
xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/web-app_3_1.xsd"
47+
version="3.1">
48+
<context-param>
49+
<param-name>contextConfigLocation</param-name>
50+
<param-value>/WEB-INF/applicationContext.xml</param-value>
51+
</context-param>
52+
<listener>
53+
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
54+
</listener>
55+
<servlet>
56+
<servlet-name>dispatcher</servlet-name>
57+
<servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
58+
<load-on-startup>1</load-on-startup>
59+
</servlet>
60+
<servlet-mapping>
61+
<servlet-name>dispatcher</servlet-name>
62+
<url-pattern>/</url-pattern> <!-- *.form -> / 바꾸기-->
63+
</servlet-mapping>
64+
</web-app>
65+
```
66+
67+
## 라이브러리 추가해주기
68+
69+
- Project Structure - Artifacts에 들어간다.
70+
71+
![[assets/posts/20170204/18.PNG]]
72+
73+
### Available Elements 아래에 있는 Library를 더블 클릭한다.
74+
- Spring-4.3.6-RELEASE to artifact
75+
- Spring MVC-4.3.6-RELEASE to artifact
76+
77+
### 옮겨진 모습
78+
79+
![[assets/posts/20170204/19.PNG]]
80+
81+
82+
## dispatcher-servlet.xml에 추가하기
83+
84+
- Annotation 활성화 & component-scan 파일 지정하기
85+
86+
```xml
87+
<?xml version="1.0" encoding="UTF-8"?>
88+
<beans xmlns="http://www.springframework.org/schema/beans"
89+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
90+
xmlns:context="http://www.springframework.org/schema/context"
91+
xmlns:mvc="http://www.springframework.org/schema/mvc"
92+
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
93+
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-4.0.xsd
94+
http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc/spring-mvc-4.0.xsd">
95+
96+
<mvc:annotation-driven></mvc:annotation-driven> <!-- Annotation 활성화 -->
97+
<context:component-scan base-package="Controller"></context:component-scan> <!-- Component 패키지 지정 -->
98+
99+
<bean class="org.springframework.web.servlet.view.InternalResourceViewResolver">
100+
<property name="prefix" value="/WEB-INF/views/"></property>
101+
<property name="suffix" value=".jsp"></property>
102+
</bean>
103+
104+
</beans>
105+
```
106+
- Annotation 활성화를 안해주면 bean을 하나하나 다 등록 해야 하는 어려움이 있다.
107+
- component-scan 패키지를 지정해주지 않으면 spring-framework가 scan을 못하여 작동하지 않게 된다.
108+
109+
## views 디렉토리 파일 만들기 & index.jsp 이동시키기
110+
111+
- New - Directory
112+
113+
![[assets/posts/20170204/6.PNG]]
114+
115+
- index.jsp
116+
117+
```html
118+
<%--
119+
Created by IntelliJ IDEA.
120+
User: NESOY
121+
Date: 2017-02-04
122+
Time: 오후 11:41
123+
To change this template use File | Settings | File Templates.
124+
--%>
125+
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
126+
<html>
127+
<head>
128+
<title>$Title$</title>
129+
</head>
130+
<body>
131+
Hello Spring World
132+
</body>
133+
</html>
134+
```
135+
136+
137+
138+
## Controller 디렉토리 만들기 & 간단한 Controller code
139+
140+
- New - Directory
141+
142+
![[assets/posts/20170204/7.PNG]]
143+
144+
```java
145+
package Controller;
146+
147+
import org.springframework.stereotype.Controller;
148+
import org.springframework.web.bind.annotation.RequestMapping;
149+
150+
/**
151+
* Created by NESOY on 2017-02-04.
152+
*/
153+
@Controller
154+
public class controller {
155+
156+
@RequestMapping(value = "/")
157+
public String test(){
158+
return "index";
159+
}
160+
}
161+
```
162+
163+
## Run Edit Configuration으로 Tomcat Server 추가하기
164+
165+
- Run - Edit Configuration
166+
167+
![[assets/posts/20170204/8.PNG]]
168+
169+
- Tomcat Server 추가하기
170+
171+
![[assets/posts/20170204/9.PNG]]
172+
173+
- Warning 나오면 Fix 버튼누르기
174+
175+
![[assets/posts/20170204/10.PNG]]
176+
177+
- war exploded로 추가하여 설정한 모습
178+
179+
![[assets/posts/20170204/11.PNG]]
180+
181+
## Error 1 : web.xml의 ApplicationContext.xml 빨간 글씨가 발생하여 tomcat 실행 X
182+
### 원인
183+
- tomcat의 context root 기본 파일 이름명이 `webapps` 때문에 에러가 발생하였다.
184+
### 해결방법
185+
- 경로 재설정 / 파일 이름 바꾸기 두 가지 해결방법이 있다.
186+
- 아래는 경로 재설정을 설명한 것이다.
187+
- 만약 이 에러가 보인다면 아래와 같이 따라하자.
188+
189+
![[assets/posts/20170204/12.PNG]]
190+
191+
### WEB-INF 경로 잡아주기
192+
193+
- Open Module Settings에 들어간다.
194+
195+
![[assets/posts/20170204/13.PNG]]
196+
197+
- Modules - web - Web Resource Directory가 빨간 글씨가 된 걸 확인할 수 있다.
198+
199+
![[assets/posts/20170204/14.PNG]]
200+
201+
- 경로 다시 잡아 주기
202+
203+
![[assets/posts/20170204/15.PNG]]
204+
205+
- 해결 된 모습
206+
207+
![[assets/posts/20170204/16.PNG]]
208+
209+
## Error 2 : Tomcat 오류 - RMI TCP Connection
210+
211+
- 만약 이 에러가 보인다면 아래와 같이 따라하자.
212+
213+
![[assets/posts/20170204/17.PNG]]
214+
215+
### 해결 방법 : Library 집어넣기.
216+
217+
- Project Structure - Artifacts에 들어간다.
218+
219+
![[assets/posts/20170204/18.PNG]]
220+
221+
- **Available Elements 아래에 있는 Library를 더블 클릭한다.**
222+
223+
- 옮겨진 모습
224+
225+
![[assets/posts/20170204/19.PNG]]
226+
227+
## 모든 에러를 통과한 후 실행하기
228+
229+
> 깔끔하게 성공된 모습을 볼 수 있다.
230+
231+
![[assets/posts/20170204/20.PNG]]
232+

content/blog/WebFont.md

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
---
2+
title: 한글 웹 폰트 적용하기
3+
tags:
4+
- Web
5+
date: 2017-10-07
6+
aliases:
7+
- /articles/2017-10/Web-Font
8+
---
9+
# Web Font 적용하기
10+
### Example Html Code
11+
- <https://developers.google.com/fonts/docs/getting_started>
12+
13+
```html
14+
<html>
15+
<head>
16+
<link rel="stylesheet"
17+
href="https://fonts.googleapis.com/css?family=Tangerine">
18+
<style>
19+
body {
20+
font-family: 'Tangerine', serif;
21+
font-size: 48px;
22+
}
23+
</style>
24+
</head>
25+
<body>
26+
<div>Making the Web Beautiful!</div>
27+
</body>
28+
</html>
29+
```
30+
31+
### 한국어 리스트 확인하기
32+
- <https://fonts.google.com/earlyaccess>
33+
34+
#### 배달의 민족 하나체
35+
![[assets/posts/20171007/1.PNG]]
36+
37+
#### 적용 후 모습
38+
![[assets/posts/20171007/2.PNG]]
39+
40+
41+
42+
## Reference
43+
- <https://developers.google.com/fonts/docs/getting_started>
44+
- <https://fonts.google.com/earlyaccess>

0 commit comments

Comments
 (0)