You can also upload existing files from your computer using the instructions below.
git config --global user.name "kreangkrai supchid"
git config --global user.email "kreang@kreangkrai.com"
git clone git@github.com:mynameiskreang/repo.git
| type Input struct { | |
| SenderName string `json:"sender_name"` | |
| Content string `json:"content"` | |
| Type string `json:"type"` | |
| } | |
| func main() { | |
| //bs, _ := ioutil.ReadFile("./input.json") | |
| bs := `{ | |
| "sender_name": "Kreang \u00e0\u00b9\u0080\u00e0\u00b8\u0081\u00e0\u00b8\u00b5\u00e0\u00b8\u00a2\u00e0\u00b8\u0087", |
| function decodeChatFacebook(input) { | |
| let d = new TextDecoder; | |
| let uint8 = input.split('').map(m => m.charCodeAt()); | |
| return d.decode(new Uint8Array(uint8)); | |
| } | |
| let sample = "Kreang \u00e0\u00b9\u0080\u00e0\u00b8\u0081\u00e0\u00b8\u00b5\u00e0\u00b8\u00a2\u00e0\u00b8\u0087"; | |
| console.log(decodeChatFacebook(sample)); |
| #! /usr/bin/env bash | |
| ## kill process by port | |
| kill -9 $(lsof -t -i:{port}) |
| async function f() { | |
| let sumPass = 0; | |
| for (let i = 0; i < 100; i++) { | |
| const isPass = await f1(i); | |
| if (isPass) { | |
| sumPass++; | |
| // await makeAsyncRequest(i); | |
| const ps = new Promise((resolve, reject) => { | |
| setTimeout(() => {resolve(i);}, 100); | |
| }); |
| If you used a non-default file path for your GitLab SSH key pair, | |
| you must configure your SSH client to find your GitLab private SSH key | |
| for connections to GitLab. | |
| Open a terminal and use the following commands | |
| (replacing other_id_rsa with your private SSH key): | |
| eval $(ssh-agent -s) | |
| ssh-add ~/.ssh/other_id_rsa | |
| #!/bin/bash | |
| sudo apt-get update | |
| sudo apt-get install build-essential chrpath libssl-dev libxft-dev | |
| sudo apt-get install libfreetype6 libfreetype6-dev | |
| sudo apt-get install libfontconfig1 libfontconfig1-dev | |
| wget https://bitbucket.org/ariya/phantomjs/downloads/phantomjs-2.1.1-linux-x86_64.tar.bz2 | |
| sudo tar xvjf phantomjs-2.1.1-linux-x86_64.tar.bz2 | |
| sudo mv phantomjs-2.1.1-linux-x86_64 /usr/local/share | |
| sudo ln -sf /usr/local/share/phantomjs-2.1.1-linux-x86_64/bin/phantomjs /usr/local/bin |
You can also upload existing files from your computer using the instructions below.
git config --global user.name "kreangkrai supchid"
git config --global user.email "kreang@kreangkrai.com"
git clone git@github.com:mynameiskreang/repo.git