Skip to content

Instantly share code, notes, and snippets.

View toanalien's full-sized avatar
🎯
Focusing

Thiên Toán toanalien

🎯
Focusing
View GitHub Profile
[
{
"active": true,
"base": "BTC",
"id": "BTC-USDT",
"info": {
"buy": 9465.820002,
"change": 112.820005,
"changeRate": 0.0121,
"coinType": "BTC",
pragma solidity ^0.4.0;
contract Counter {
int private count = 0;
function incrementCounter() public {
count += 1;
}
function decrementCounter() public {
count -= 1;
}
function getCount() public constant returns (int) {
BEGIN;
-- Model missing for table: pg_stat_statements
-- Model missing for table: crm_crmfield
-- Model missing for table: qna_qnaquestion
-- Model missing for table: trello_sync_card
-- Model missing for table: trello_sync_trelloprofile
-- Model missing for table: crm_activity
-- Model missing for table: crm_affiliateuser
-- Model missing for table: crm_autopipelinetask
-- Model missing for table: crm_autotask
#! /bin/bash
red='\e[1;31m%s\e[0m\n'
green='\e[1;32m%s\e[0m\n'
printf "$red" "======= 1. update system ======="
sudo apt update -y
printf "$red" "======= 2. install docker ======="
curl https://releases.rancher.com/install-docker/17.12.sh | sh
# -----------------------------
# PostgreSQL configuration file
# -----------------------------
#
# This file consists of lines of the form:
#
# name = value
#
# (The "=" is optional.) Whitespace may be used. Comments are introduced with
# "#" anywhere on a line. The complete list of parameter names and allowed
version: '2'
services:
postgres:
container_name: postgres
image: postgres
restart: always
ports:
- "5432:5432"
volumes:
@toanalien
toanalien / kmskeys10.txt
Created April 7, 2018 09:30 — forked from CHEF-KOCH/kmskeys10.txt
Windows 10 KMS Keys
Windows.10.and.Office.2016.gVLK
#####################################################################
# Install/Uninstall keys #
#####################################################################
1.) Uninstall the current product by entering the “uninstall product key” extension:
slmgr.vbs /upk
2.) Install the key that you obtained above for “Windows Srv 2012R2 DataCtr/Std KMS for Windows 10”
@toanalien
toanalien / gist:0d139a0c287261fc1489fd30d0ae1cb5
Created January 30, 2018 11:04 — forked from bigsnarfdude/gist:b2eb1cabfdaf7e62a8fc
ubuntu 14.04 install scala 2.11.7 and sbt 13.9 and java 8 and git
# scala install
wget www.scala-lang.org/files/archive/scala-2.11.7.deb
sudo dpkg -i scala-2.11.7.deb
# sbt installation
echo "deb https://dl.bintray.com/sbt/debian /" | sudo tee -a /etc/apt/sources.list.d/sbt.list
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 642AC823
sudo apt-get update
sudo apt-get install sbt
@toanalien
toanalien / gist:bd69a0e5ab0545ceb0d2aa575d781ff8
Created January 22, 2018 04:21
performance/static/js/tree-init.js
var st = null;
var node_id = null;
var language = 'VN';
function valid_input() {
if ($('#id-email-employee-edit').val() == ''){
alert(gettext('Email field is required.'));
return false;
}
var pattern = new RegExp(/^((([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\u
version: '3.1'
services:
ghost:
image: ghost:1-alpine
restart: always
ports:
- 8080:2368
environment: