Skip to content

Instantly share code, notes, and snippets.

@TsutomuNakamura
TsutomuNakamura / happy_birthday_toki.sh
Created May 25, 2019
Run platform-display for Toki's happy birthday!
View happy_birthday_toki.sh
#!/usr/bin/env bash
bash -- <(curl -o- https://raw.githubusercontent.com/TsutomuNakamura/platform-display/master/index.sh 2> /dev/null) 'Happy birthday Toki!'
@TsutomuNakamura
TsutomuNakamura / Dockerfile
Last active Nov 8, 2018
Dokerfile for mediawiki with LaTeX
View Dockerfile
# https://hub.docker.com/_/mediawiki/
FROM mediawiki:latest
# Change the repository location of the repository for people who lives in Japan.
RUN VAR=$(grep -E '^deb .*' /etc/apt/sources.list | head -1 | awk '{print $3}') && \
echo "deb http://ftp.jp.debian.org/debian/ stretch ${VAR} main contrib non-free" > /etc/apt/sources.list && \
echo "deb http://ftp.jp.debian.org/debian ${VAR}-updates main contrib" >> /etc/apt/sources.list
# https://www.mediawiki.org/wiki/Extension:Math/advancedSettings#Installing_texvc
RUN apt-get update && \
View rsync_lxc_container.sh
rsync --archive --compress --partial --append --delete --numeric-ids \
--exclude=/rootfs/cdrom/* --exclude=/rootfs/dev/* --exclude=/rootfs/media/* --exclude=rootfs/mnt/* \
--exclude=/rootfs/proc/* --exclude=/rootfs/run/* --exclude=/rootfs/sys/* --exclude=/rootfs/tmp/* \
/var/lib/lxc/${container}/ user@desthost:/var/lib/lxc/${container}
@TsutomuNakamura
TsutomuNakamura / KDEShortcuts_RunCommand_KWin.txt
Created Mar 25, 2018
KDE のショートカット。System Settings -> Shortcuts からインポートする
View KDEShortcuts_RunCommand_KWin.txt
[krunner][Global Shortcuts]
run command=Meta+R; Alt+F2
run command on clipboard contents=Alt+Shift+F2
[kwin][Global Shortcuts]
Activate Window Demanding Attention=Ctrl+Alt+A
Decrease Opacity=none
Expose=Ctrl+F9
ExposeAll=Ctrl+F10; Launch (C)
ExposeClass=Ctrl+F7
@TsutomuNakamura
TsutomuNakamura / InstallDockerInUbuntu.sh
Last active Mar 25, 2018
Ubuntu にリポジトリから最新のDocker をインストールする
View InstallDockerInUbuntu.sh
#!/bin/bash -eu
# Reference https://docs.docker.com/engine/installation/ubuntulinux/
[ "$(id -u)" != "0" ] && echo "You must run this script as root." && exit 1
. /etc/os-release
[ "${NAME,,}" != "ubuntu" ] && echo "Sorry, this script doesn't support the distribution $NAME" && exit 1
apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D
. /etc/lsb-release
echo "deb https://apt.dockerproject.org/repo ubuntu-${DISTRIB_CODENAME,,} main" > /etc/apt/sources.list.d/docker.list
@TsutomuNakamura
TsutomuNakamura / IBMPowerKVM
Last active Mar 25, 2018
あらゆるLinux にKVMをインストールする ref: http://qiita.com/TsutomuNakamura/items/bb5cd1bcbf1b998941ed
View IBMPowerKVM
http://www-01.ibm.com/support/knowledgecenter/linuxonibm/liabo/liabokickoff.htm