Skip to content

Instantly share code, notes, and snippets.

View jaceshim's full-sized avatar
🌐
Working from earth

Jace Shim jaceshim

🌐
Working from earth
  • NAVER
  • Seoul, Korea
View GitHub Profile
@jaceshim
jaceshim / DataSourceType.java
Created February 6, 2018 09:06
Multiple DataSource on springboot
package com.kakao.order.common.config.database;
/**
* Created by jaceshim on 2017. 8. 23..
*/
public enum DataSourceType {
WRITE, READ
}
@jaceshim
jaceshim / FindJarPath.java
Created February 26, 2018 17:00
Find jar path loaded class in spring controller
@Controller
public class ClassLoaderController {
/**
*
* @param clazzName 패키지를 포함한 클래스명 ex) javax.servlet.http.HttpServlet
* @return
*/
@RequestMapping(value = "/find/jar")
@ResponseBody
task "create-dirs" << {
sourceSets*.java.srcDirs*.each { it.mkdirs() }
sourceSets*.resources.srcDirs*.each { it.mkdirs() }
}
@jaceshim
jaceshim / delete .git directory
Created April 9, 2018 07:37
delete .git directory
find . -type f | grep -i "\.git" | xargs rm
@jaceshim
jaceshim / MariaDB Audit Plugin
Created June 26, 2018 15:20
MariaDB Audit Plugin
#mariadb audit plugin 설치
무중단이 가능합니다!
## 플러그인 directory에서 server_audit.so 확인
SHOW GLOBAL VARIABLES LIKE 'plugin_dir';
## 설치
INSTALL PLUGIN server_audit SONAME 'server_audit.so';
@jaceshim
jaceshim / NBAMVP.java
Last active May 5, 2019 13:35 — forked from HomoEfficio/NBAMVP.java
Printing NBA MVP by name and count
package homo.efficio.java8.sort_by_value;
import java.util.*;
import java.util.stream.Collectors;
/**
* @author homo.efficio@gmail.com
* Created on 2019-05-05.
*/
import 'package:flutter/material.dart';
class ScrollTest extends StatefulWidget {
@override
_ScrollTestState createState() => _ScrollTestState();
}
class _ScrollTestState extends State<ScrollTest> {
ScrollController _scrollController = ScrollController();
@jaceshim
jaceshim / Finding where the key has been used
Created June 16, 2020 16:10
Finding where the key has been used
$ ssh -T -ai ~/.ssh/id_rsa git@github.com
# Connect to GitHub using a specific ssh key
> Hi username! You've successfully authenticated, but GitHub does not
> provide shell access.
@jaceshim
jaceshim / gist:137faf558ebd100667ef1cc8c5987586
Created June 16, 2020 16:12
clear all route and go page in flutter
Navigator.of(context).pushAndRemoveUntil(
MaterialPageRoute(builder: (BuildContext context) => PageWidget()),
(Route<dynamic> route) => false,
);
@jaceshim
jaceshim / zip_without_macosx.sh
Created June 22, 2020 11:45
zip_without_macosx
#!/bin/bash
for file in */ ; do
if [[ -d "$file" && ! -L "$file" ]]; then
echo "$file is a directory";
zipfile=$(find $file -name *.zip)
rm $zipfile
echo "deleted zipfile to $zipfile"
cd $file