Skip to content

Instantly share code, notes, and snippets.

View Liam0205's full-sized avatar
🎯
Focusing

Liam Huang Liam0205

🎯
Focusing
View GitHub Profile
@Liam0205
Liam0205 / # systemd - 2020-02-03_10-02-01.txt
Created February 3, 2020 02:06
systemd on 2.6.32-754.2.1.el6.x86_64 - Homebrew build logs
Homebrew build logs for systemd on 2.6.32-754.2.1.el6.x86_64
Build date: 2020-02-03 10:02:01
@Liam0205
Liam0205 / # systemd - 2020-01-20_15-18-26.txt
Created January 20, 2020 07:25
systemd on 2.6.32-754.2.1.el6.x86_64 - Homebrew build logs
Homebrew build logs for systemd on 2.6.32-754.2.1.el6.x86_64
Build date: 2020-01-20 15:18:26
#include <cassert>
#include <cmath>
#include <iostream>
#include <random>
#include <algorithm>
#include <limits>
#include <functional>
#include <map>
#include <vector>
#include <queue>
@Liam0205
Liam0205 / quicksort.cc
Created November 17, 2019 15:20
A quick sort implement by Liam.
#include <iostream>
#include <iterator>
#include <functional>
#include <algorithm>
#include <type_traits>
#include <vector>
#include <list>
#include <forward_list>
namespace {
#include <iostream>
#include <string>
#include <iterator>
#include <algorithm>
#include <type_traits>
#include <functional>
namespace yuuki {
namespace detail {
static const constexpr size_t __bsearch_thrd = 16;
%% start of file `moderncv_demo.tex'.
%% Copyright 2006-2015 Xavier Danaux (xdanaux@gmail.com).
%
% This work may be distributed and/or modified under the
% conditions of the LaTeX Project Public License version 1.3c,
% available at http://www.latex-project.org/lppl/.
\documentclass[11pt,a4paper,sans]{moderncv} % possible options include font size ('10pt', '11pt' and '12pt'), paper size ('a4paper', 'letterpaper', 'a5paper', 'legalpaper', 'executivepaper' and 'landscape') and font family ('sans' and 'roman')
@Liam0205
Liam0205 / refraction.c
Last active January 2, 2019 03:25
2D-light demo for computer graphics enthusiasts.
#include "svpng.inc"
#include <math.h> // fabsf(), fminf(), fmaxf(), sinf(), cosf(), sqrt()
#include <stdlib.h> // rand(), RAND_MAX
#define TWO_PI 6.28318530718f
#define W 512
#define H 512
#define N 256
#define MAX_STEP 64
#define MAX_DISTANCE 5.0f
#include <iostream>
#include <string>
struct Person {
size_t age = 0;
std::string name;
Person& operator++() { // prefix
++age;
return *this;
@Liam0205
Liam0205 / install_git.sh
Created December 18, 2018 10:53
Compile and Install Git on CentOS 7
yum install asciidoc
yum install xmlto
yum install zlib-devel
yum install cpan
version="2.9.5"
fname="git-${version}"
tarball="${fname}.tar.gz"
wget https://mirrors.edge.kernel.org/pub/software/scm/git/${tarball}
@Liam0205
Liam0205 / install_vim.sh
Created November 2, 2018 03:17
Compile and install VIM on CentOS 6.x without root.
#!/bin/bash
git clone https://github.com/vim/vim.git --depth=1
cd vim
make -p $HOME/local/bin
./configure --prefix=$HOME/local/vim --enable-multibyte --with-tlib=tinfo --enable-pythoninterp --enable-rubyinterp --with-ruby-command=/usr/bin/ruby --with-features=huge
make -j24
make install
cd $HOME/local/bin
for file in $(ls $HOME/local/vim/bin); do ln -sf $HOME/local/vim/bin/$file $file; done