This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
find . -type f | grep '.m$' | xargs basename -s .m | grep -v '^Contents$' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Configure Emacs build options. | |
./autogen.sh | |
mkdir build && cd build | |
# Replace `--with-pgtk` with `--with-cairo` if building for X11. | |
CFLAGS='-march=native -O3' ../configure \ | |
--with-modules \ | |
--with-xwidgets \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
\documentclass[14pt]{beamer} | |
\usetheme{Singapore} | |
\begin{document} | |
\begin{frame} | |
\end{frame} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# see https://www.topbug.net/blog/2013/04/14/install-and-use-gnu-command-line-tools-in-mac-os-x/ | |
# core | |
brew install coreutils | |
# key commands | |
brew install binutils | |
brew install diffutils | |
brew install ed --default-names | |
brew install findutils --with-default-names |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
echo '#!/bin/bash' | |
echo '' | |
echo 'failed_items=""' | |
echo 'function install_package() {' | |
echo 'echo EXECUTING: brew install $1 $2' | |
echo 'brew install $1 $2' | |
echo '[ $? -ne 0 ] && $failed_items="$failed_items $1" # package failed to install.' | |
echo '}' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Makefile template for a shared library in C | |
# https://www.topbug.net/blog/2019/10/28/makefile-template-for-a-shared-library-in-c-with-explanations/ | |
CC = gcc # C compiler | |
CFLAGS = -fPIC -Wall -Wextra -O2 -g # C flags | |
LDFLAGS = -shared # linking flags | |
RM = rm -f # rm command | |
TARGET_LIB = libtarget.so # target lib | |
SRCS = main.c src1.c src2.c # source files |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python3 | |
# This file is licensed under CC0 <https://creativecommons.org/publicdomain/zero/1.0/legalcode> | |
# https://www.topbug.net/blog/2016/12/13/send-git-patches-with-gui-email-clients/ | |
import sys | |
import webbrowser | |
try: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
\documentclass{article} | |
\usepackage{CJK} | |
\usepackage{indentfirst} | |
\usepackage[CJKbookmarks]{hyperref} | |
\usepackage{float} | |
\usepackage{amsmath,bm} | |
\usepackage{url} | |
\usepackage{graphicx} | |
\setlength{\parindent}{2em} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
./configure --with-features=huge --enable-pythoninterp --enable-python3interp --enable-perlinterp --enable-rubyinterp CFLAGS='-O3 -Wall -Wextra' $* |
NewerOlder