サクサク読めて、アプリ限定の機能も多数!
トップへ戻る
パリ五輪
litt.hatenadiary.org
LinuxマシンにUSBでデジカメを繋いでgphoto2でファイル保存するのはいいけど、一般ユーザでは権限がなく毎回rootになるのは面倒。 なもんでちょっと調べてみた。 # lsusb Bus 004 Device 003: ID 04cb:01c1 Fuji Photo Film Co., Ltd Bus 004 Device 001: ID 0000:0000 Bus 003 Device 001: ID 0000:0000 Bus 001 Device 001: ID 0000:0000 Bus 002 Device 001: ID 0000:0000Bus 004 の Device 003 にデバイスが割り当てられてるのでもっと詳しく表示 # udevinfo -a -p /sys/class/usb_device/usbdev4.3/ ... looking at parent
初期状態ではubuntuが入っているがいい加減古い。 せっかくバージョンアップするなら使い慣れてるDebianにしようと思いやってみた。 さらにこの際なのでフラッシュメモリに特化したファイルシステムUBIFSに変更してみた。 多分DreamPlugでもほぼ同じ手順でできると思う。 参考URL http://www.plugcomputer.org/plugwiki/index.php/SheevaPlug_Installer http://www.plugcomputer.org/plugwiki/index.php/Installing_Debian_To_Flash 準備するもの * sheevaplug 本体 * 作業領域として利用する512M以上のUSBメモリ(SDカードで代用可) * ローカルネットワークのどこかで稼動しているDHCPサーバとTFTPサーバ * sheevaplu
select to_timestamp(1188831600); → "2007-09-04 00:00:00+09"select extract(epoch from timestamp '2007-09-04'); → 1188831600MySQLとかではどうなんだろ?
!をつけるだけ。例えば hoge/ の中にある .sh ファイルを列挙したいけど hoge/huge/ の中のあるものは除くって場合 $ find hoge/ -name '*.sh' ! -path 'hoge/huge/*'
まずは基本。 header('Content-Disposition: attachment; filename="hoge.txt"'); header('Content-Type: application/octet-stream'); header('Content-Transfer-Encoding: binary'); header('Content-Length: '.strlen($buf)); print $buf; ファイルになってるやつをダウンロード。 header('Content-Disposition: attachment; filename="'.basename($filepath).'"'); header('Content-Type: application/octet-stream'); header('Content-Transfer-Encodin
このページを最初にブックマークしてみませんか?
『litt.hatenadiary.org』の新着エントリーを見る
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く