2014年4月5日土曜日

neosnippetの説明

snippetファイルの作り方
https://github.com/yonchu/dotfiles/blob/master/.vim/snippets/snippet.snip

2014年3月22日土曜日

uim-mozcの設定

以下のパッケージをインストール
uim-qt
uim-xim

起動
uim-xim &

設定
uim-pref-qt4

dovecotで特定のユーザのみ接続許可する

/etc/pam.d/dovecot
をいじってこんな感じにするといい
#%PAM-1.0

@include common-auth
account required pam_succeed_if.so user = hogeuser
@include common-account
@include common-session

参考リンク
http://wiki2.dovecot.org/Authentication/RestrictAccess

2014年3月9日日曜日

無線LANとサスペンド機能の有効化

以下のパッケージとかを入れる

firmware-linux-nonfree
firmware-realtek

lspci
とか使ってハードウェアを調べること

2014年2月2日日曜日

軽量なLinux用PDFビューワ

mupdf

apt-get install mupdf

viライクなキーバインド

2014年1月19日日曜日

X11の画面設定はarandrが便利


apt-get install arandr
でインストールできる

公式サイト
http://christian.amsuess.com/tools/arandr/

2014年1月18日土曜日

wget画像収集

こんな感じのコマンドかな?
wget -erobots=off -H -N -r -nd -nH -l 1 -k -A jpg,png -R html url

2014年1月13日月曜日

xrandrの使い方

wikipedia分かりやすい

モニターと可能な設定の表示

xrandr

全てのモニターを最高解像度で、同じ画面を表示する。

xrandr --auto

内蔵モニターの右側に外部モニターを表示。モニターの名前は、上の xrandr で調べられる。ここでは 内部モニター:LVDS、外部モニター:VGA とする。

xrandr --output VGA --right-of LVDS

内蔵モニターの上側に外部モニターを表示。

xrandr --output VGA --above LVDS

マルチモニターを使用する場合、X11の設定ファイル:通常 /etc/X11/xorg.conf で、仮想スクリーンの範囲を大きく取っておく。 例:

Virtual 2048 2048

参考リンク
http://ja.wikipedia.org/wiki/XRandR

関連記事
X11で縦表示とか画面の回転設定

2014年1月11日土曜日

Debianで無線LAN接続

今回はwicdを使う

無線デバイス確認
# lspci | grep -i wire
03:00.0 Network controller: Intel Corporation PRO/Wireless 3945ABG [Golan] Network Connection (rev 02)

ファームインストール
apt-get install firmware-iwlwifi

あとはこんな感じで設定

Networkmanagerのアンインストール
apt-get remove network-manager

# apt-getinstall install wicd
# apt-getinstall wicd-curses

Xなくてもつかえるwicd-cursesが便利だった
あとnetdevグループに属してないとwicd使えない

参考リンク
https://wiki.debian.org/WiFi/HowToUse#Wicd
https://wiki.debian.org/iwlwifi

let's noteにacpid入れてバックライト調整


debian jessieでやってみた
使用したPCはLet's Note CF-W5

acpi-supportインストール
apt-get install acpi-support

Enabling backlight controlを参考にする

/etc/acpi/bright.sh
#!/bin/sh
bl_dev=/sys/class/backlight/panasonic/brightness
step=1

case $1 in
    -)
        echo $( expr `cat $bl_dev` - $step ) > $bl_dev
        ;;
    +)
        echo $( expr `cat $bl_dev` + $step ) > $bl_dev
        ;;
esac

/etc/acpi/events/bright_d
event=video/brightnessdown
action=/etc/acpi/bright.sh -

/etc/acpi/events/bright_u
event=video/brightnessup
action=/etc/acpi/bright.sh +


参考リンク
https://wiki.archlinux.org/index.php/acpid

2014年1月2日木曜日

Debian wheezyで日本語環境設定


こんな感じ
apt-get install manpages-ja
dpkg-reconfigure locales
dpkg-reconfigure tzdata

2013年12月15日日曜日

chef bootstrapが使えないときにnodeを追加する


knife configure client /path/to/tempdir

できたファイルをnodeに置く
/etc/chef/client.rb
/etc/chef/validation.pem

で↓のコマンドでOK
chef-client

参考リンク
http://hivecolor.com/id/46

maildirsizeをMaildirに置くとクォータ設定できる

maildirsizeをMaildirに置くとクォータの設定ができる
dovecotとかmaildropが対応している

~/Maildir/maildirsize
8000C
   284871170        10382

2013年12月7日土曜日

WindowsでSPICE接続

SPICEクライアントをダウンロード
http://www.spice-space.org/download.html

virt-viewer-x64-0.5.7.msiを使いました
んでインストール

C:\Program Files\VirtViewer\bin\remote-viewer.exe
あたりを実行


参考リンク
http://www.server-world.info/query?os=Fedora_18&p=kvm&f=8