Skip to content

Instantly share code, notes, and snippets.

@daemin-hwang
daemin-hwang / gist:1441c79b8925e9df3e7e
Created March 17, 2016 17:03
spring boot color banner
[스프링 부트 컬러 배너 제작사이트]
https://spring-boot-banner-gen.cfapps.io/banner
@daemin-hwang
daemin-hwang / maven dependency plugin 참조 링크
Created March 16, 2016 06:43
maven dependency plugin 참조 링크
사용
dependency:analyze
프로젝트내에서 정의되고 사용되는 dependency 들의 유형을 분석(사용되며 선언됨, 사용되고 선언되지 않음, 사용하지 않고 선언됨)
dependency:analyze-duplicate
프로젝트내에 중복된 dependency 들을 분석하여 출력
[maven dependency plugin 참조 링크]
@daemin-hwang
daemin-hwang / git credential cache 설정
Created March 14, 2016 12:12
git credential cache 설정
아래 사이트에 가서 다운로드 후 설치 한다.
https://github.com/Microsoft/Git-Credential-Manager-for-Windows/releases/tag/v1.2.1
~/.gitconfig
[credential]
helper = manager
와 같이 설정 된다.
#!/bin/sh
#
# For each ref, validate the commit.
#
# - It disallows deleting branches without a /.
# - It disallows non fast-forward on branches without a /.
# - It disallows deleting tags without a /.
# - It disallows unannotated tags to be pushed.
@daemin-hwang
daemin-hwang / gist:6cd7f422ab4ef05f3485
Created March 5, 2016 12:20
git config 설정 Hook과 정책
[7.1 Git맞춤 - Git 설정하기]
로컬 클라이언트 config 설정 / 서버 denyNonFastForwards 설정 관련 내용
: https://git-scm.com/book/ko/v1/Git%EB%A7%9E%EC%B6%A4-Git-%EC%84%A4%EC%A0%95%ED%95%98%EA%B8%B0
[7.4 Git맞춤 - 정책 구현하기]
서버훅 / 클라이언트훅(denyNonFastForwards 체크)
: https://git-scm.com/book/ko/v1/Git%EB%A7%9E%EC%B6%A4-%EC%A0%95%EC%B1%85-%EA%B5%AC%ED%98%84%ED%95%98%EA%B8%B0
@daemin-hwang
daemin-hwang / jetty-maven-plugin 설정 정보
Last active March 5, 2016 12:15
jetty-maven-plugin 설정 정보
<plugin>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-maven-plugin</artifactId>
<version>9.3.7.v20160115</version>
<configuration>
<httpConnector>
<port>8080</port>
<idleTimeout>30000</idleTimeout>
</httpConnector>
<scanIntervalSeconds>10</scanIntervalSeconds>
@daemin-hwang
daemin-hwang / JDBC ConnectionTimeOut 설정
Created February 10, 2016 08:33
JDBC ConnectionTimeOut 설정
http://uip80.tistory.com/entry/24%EC%8B%9C%EA%B0%84-%EB%8F%99%EC%95%88-connection-%EC%98%A4%EB%A5%98-mysql
@daemin-hwang
daemin-hwang / NGINX image 경로 설정
Created February 9, 2016 14:58
NGINX image 경로 설정
location ~ ^/image/.*(png|jpg|jpeg|gif|ico|swf)$ {
root /home/ubuntu/project/bolt25/upload;
break;
}
# /image/a.png 로 요청이 들어온 경우 root로 지정된 경로의 파일을 찾음
# ex) /home/ubuntu/project/bolt25/upload/image.png
@daemin-hwang
daemin-hwang / JAVA 페이징 처리 클래스
Created January 28, 2016 05:54
JAVA 페이징 처리 클래스
//* @Getter, @Setter 사용 - lombock 디펜던시 있음
@ToString
public class Paging {
private static final int DEFAULT_COUNT_PER_PAGE = 10; //한화면에 보여질 item row 수
private static final int DEFAULT_PAGE_PER_BLOCK = 10; //페이지블럭에 보일 페이지 수 [1] [2] [3] == '3'
@Getter @Setter
private int countPerPage = DEFAULT_COUNT_PER_PAGE;
@Getter @Setter
@daemin-hwang
daemin-hwang / spring boot application.properties
Last active January 26, 2016 02:10
spring boot application.properties 설정
spring boot application.properties 에서 프로파일별 로딩 설정시에
logback.xml 내에 명시되어있는 resource 경로를 명시해줘야함.
"application-dev.properties" 파일을 로드 하고자 하면
JVM 아규먼트를 "-Dspring.profiles.active=dev" 와 같이 던지고
logbak.xml 내 설정을
<property resource="application-${spring.profiles.active}.properties" /> 와 같이 작성한다.
라이브러리 디펜던시 필요 :
<dependency>
<groupId>org.codehaus.janino</groupId>