Skip to content

Instantly share code, notes, and snippets.

@JohnKim
JohnKim / AppDelegate.swift
Created July 12, 2024 14:54
Local Notification 과 privacy screen 을 추가한 코드 for IOS
import UIKit
import Flutter
@UIApplicationMain
@objc class AppDelegate: FlutterAppDelegate {
private var flutterViewController: FlutterViewController!
private var securityChannel: FlutterMethodChannel!
private var blurEffectView: UIVisualEffectView?
private var isInBackground: Bool = false // Track whether app is in background
@JohnKim
JohnKim / gist:7534d00d49fceb569524291a88966ada
Last active November 16, 2021 23:47
gsshop_mobile_lib_folders
lib/
|- bloc/
|- constants/
|- router/
|- screens/
|- utils/
|- widgets/
|- main.dart
gsshop_mobile
|- android
|- assets <-- 아이콘 및 이미지 파일 저장
|- build
|- docs
|- ios
|- lib <-- 어플리케이션 소스 코드
|- packages
@JohnKim
JohnKim / main.dart
Created November 6, 2020 09:09
Face Example (Flutter)
import 'package:flutter/material.dart';
import 'dart:math';
double degreesToRads(double deg) {
return (deg * pi) / 180.0;
}
void main() {
runApp(Face());
}
@JohnKim
JohnKim / README.md
Created May 3, 2019 04:12
Support for the experimental syntax 'decorators-legacy' isn't currently enabled

Installation

$ yarn add --dev @babel/plugin-proposal-decorators
@JohnKim
JohnKim / rs-index.js
Created October 23, 2017 08:34
[React-sketchapp 강의] 가장 기본적인 코드
import { render, Text, Artboard } from 'react-sketchapp';
const App = props => (
<Artboard>
<Text style={{ fontFamily: 'Comic Sans MS', color: 'hotPink' }}>
{ props.message }
</Text>
</Artboard>
);
@JohnKim
JohnKim / gist:77cba1c6564a0a5a8a3e
Created October 31, 2015 03:40
change the global module directory on Ubuntu for NPM
mkdir ~/npm-global-modules && npm config set prefix '~/npm-global-modules' && echo "export PATH=~/npm-global-modules/bin:\$PATH" >> ~/.profile && source ~/.profile
@JohnKim
JohnKim / gist:7993c718d27d85a23dee
Last active August 14, 2019 12:08
install mosquitto & auth-plugin
## upgrade openssl
wget http://www.openssl.org/source/openssl-1.0.1i.tar.gz
tar -zxf openssl-1.0.1i.tar.gz
cd openssl-1.0.1i
./config --prefix=/usr --openssldir=/usr/local/openssl shared
make
make test
sudo make install
openssl version
@JohnKim
JohnKim / gist:a63f2be825b186e79d9e
Last active August 29, 2015 14:10
[XPUSH-HY] upgrade JAVA SDK and install zookeeper
$ su -
$ cd /tmp
~ http://www.oracle.com/technetwork/java/javase/downloads/index.html 에서 다운로드 받을 JDK 링크 확인.
~ 참조 : http://tecadmin.net/steps-to-install-java-on-centos-5-6-or-rhel-5-6/
$ wget --no-cookies --no-check-certificate --header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie" "http://download.oracle.com/otn-pub/java/jdk/7u71-b14/jdk-7u71-linux-x64.rpm"
~ 설치
$ rpm -ivh jdk-7u71-linux-x64.rpm
@JohnKim
JohnKim / gist:31813552e7f89604cad1
Last active August 29, 2015 14:10
[XPUSH-HY] HAPROXY (public)
~ 업데이트
$ yum remove matahari*
$ yum update
~ 서버 종류 확인하기.
$ lsb_release -a
~ 컴파일하기 위한 툴킷 설치
$ yum -y groupinstall "Development Tools"