This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@echo off | |
REM https://www.makeuseof.com/tag/access-group-policy-editor-even-windows-home-settings-try/ | |
pushd "%~dp0" | |
dir /b %SystemRoot%\servicing\Packages\Microsoft-Windows-GroupPolicy-ClientExtensions-Package~3*.mum >List.txt | |
dir /b %SystemRoot%\servicing\Packages\Microsoft-Windows-GroupPolicy-ClientTools-Package~3*.mum >>List.txt | |
for /f %%i in ('findstr /i . List.txt 2^>nul') do dism /online /norestart /add-package:"%SystemRoot%\servicing\Packages\%%i" | |
pause |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name kwonnam wiki accesskey changer | |
// @namespace http://tampermonkey.net/ | |
// @version 0.1 | |
// @description try to take over the world! | |
// @author KwonNam Son | |
// @match https://kwonnam.pe.kr/wiki/* | |
// @grant none | |
// ==/UserScript== |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# workspace-switcher.sh [num-of-workspace] [Down/Up] | |
CMD="$2" | |
NUM_WORKSPACES=$1 | |
CURRENT_WS=`wmctrl -d | grep \* | cut -d " " -f 1` | |
MOVE_UP="-1" | |
MOVE_DOWN="+1" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Gnome 3 based workspace changer | |
# only works with gnome 3 vertical workspace | |
# workspace-switcher.sh Up | |
# workspace-switcher.sh Down | |
# | |
# ref : https://www.artificialworlds.net/blog/2011/03/04/switching-workspace-in-gnome-via-the-command-line/ | |
CMD="$1" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import com.intellij.database.model.DasTable | |
import com.intellij.database.util.Case | |
import com.intellij.database.util.DasUtil | |
/* | |
IntelliJ Database Extension script for Java 8 or Later JPA entity mapping generation. | |
*/ | |
/* | |
* Available context bindings: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import org.slf4j.Logger | |
import org.slf4j.LoggerFactory | |
import org.springframework.beans.factory.annotation.Autowired | |
import org.springframework.boot.test.autoconfigure.web.servlet.WebMvcTest | |
import org.springframework.http.MediaType | |
import org.springframework.test.web.servlet.MockMvc | |
import org.springframework.test.web.servlet.MvcResult | |
import org.springframework.web.bind.annotation.* | |
import spock.lang.Specification |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Slf4j | |
public class MdcLoggingInterceptor implements HandlerInterceptor { | |
public static final String REQUEST_URL_MDC_KEY = "URL"; | |
public static final String REQUEST_CONTROLLER_MDC_KEY = "Controller"; | |
@Override | |
public boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object handler) throws Exception { | |
if (handler instanceof HandlerMethod) { | |
String fullUrl = request.getRequestURI() + Optional.ofNullable(request.getQueryString()).map(qs -> "?" + qs).orElse(""); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Grapes([ | |
@Grab(group='io.github.http-builder-ng', module='http-builder-ng-apache', version='1.0.3') | |
@Grab(group='org.slf4j', module='slf4j-simple', version='1.7.25') | |
]) | |
import static groovyx.net.http.HttpBuilder.configure | |
def sonarqubeHttp = configure { | |
request.uri = 'http://sonarqube.example.com' | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// 3.11 이후 버전에서 package가 변경되었으므로 GenerationTool과 Configuration 의 package를 다시 확인해야 한다! | |
buildscript { | |
dependencies { | |
classpath 'org.jooq:jooq-codegen:3.11.4' | |
classpath "mysql:mysql-connector-java:${mySqlDriverVersion}" | |
} | |
} | |
ext { | |
jooqSourceDir = "src/generated/jooq" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// MySQLQuery와 JPASQLQuery 를 참조해서 만든 MySQLJPASQLQuery : QueryDSL 3.x | |
public class MySQLJPASQLQuery extends AbstractJPASQLQuery<MySQLJPASQLQuery> { | |
private static final Joiner JOINER = Joiner.on(", "); | |
public MySQLJPASQLQuery(EntityManager entityManager, SQLTemplates sqlTemplates) { | |
super(entityManager, new Configuration(sqlTemplates)); | |
} | |
public MySQLJPASQLQuery forceIndex(String... indexes) { |
NewerOlder