CSSを少し勉強している。
CSSを少し勉強している。勉強しているといっても、まだかじり始めた程度。
どのようなものから始めればいいのかわかりづらかったが、ドットインストールで基礎的なものを学べるので便利。
また、チートシートをダウンロードしたので、それを参考にしながら少しずつでも進んでいければいいなと思う。
プリンタのセットアップを完成しないとプリントアウトできないという問題を抱えているので、とりあえずそれに取り組もうと思う。
また、エディタをmiからKomodo Editというのにした。
構文チェック・色分け表示・関数の折りたたみ表示・キーワードの自動補完などの機能があるので、入力がとても楽。
最初の設定で、utf8に変更しないと日本語が反映されたりしないのが少々面倒だったくらい。
燃えよ剣
大学入学と同時くらいに買ってから放置していた、「燃えよ剣」を読みました。
幕末から江戸へと時代が変わりゆく中を、新撰組副長を勤めた土方歳三を中心に描いた作品になります。
不器用ながら、ひたむきに己の信じた道を行く姿は男らしいの一言に尽きますが、
その目的の達成のために邪魔であれば、見方さえ殺してしまうという残酷な面もあるのが、
彼らしさでもあるのかなとも思いました。
土方歳三関連だと、日野宿本陣はおすすめです。
素晴らしい日本建築で、日野駅からも近いです。
http://www.city.hino.tokyo.jp/shinsenr/honjin/honnjinnindex.html
ただ、上巻の終わり方はずるい。
- 作者: 司馬遼太郎
- 出版社/メーカー: 新潮社
- 発売日: 1972/06/01
- メディア: 文庫
- 購入: 32人 クリック: 409回
- この商品を含むブログ (293件) を見る
- 作者: 司馬遼太郎
- 出版社/メーカー: 新潮社
- 発売日: 1972/06/19
- メディア: 文庫
- 購入: 25人 クリック: 55回
- この商品を含むブログ (169件) を見る
Homebrew本体のアンインストールメモとインストールメモ
Homebrewをアンインストールするには以下のコードを実行する。
シェルスクリプトでできるようですが、わからなかったので、コピペしました。
もう一回Homebrewを入れようとすると
/usr/local/.git already exists!
というエラーが出る。
gitのフォルダが残っているみたい。
rm -rf .git
これで、きちんとインストールできるようになります。
ドットインストールがおもしろい。
ドットインストールを昨年末くらいからやっています。
とてもわかりやすくて、またPCの環境もほぼ同じ環境なのでとてもわかりやすく学べています。
もっとペースを上げて学んで自分のサイトを一日でも早く作れるようになればと思います。
その時に、開発した方に感謝の言葉と自分で作ったサイトをお伝えできるようになることを夢見て今日もドットインストールをやろうと思います。
HomebrewでMySQLをインストールしたが、MySQLが動かなくて動くようになるまでの一部始終。
環境:MacOSX(10.7.2)
MySQL(5.5.15)
太字が実際に入力したコマンドになります。
brew install mysql
==> Downloading http://downloads.mysql.com/archives/mysql-5.5/mysql-5.5.15.tar.g
######################################################################## 100.0%
==> Patching
patching file scripts/mysqld_safe.sh
Hunk #1 succeeded at 555 (offset 172 lines).
patching file scripts/mysql_config.sh
Hunk #1 succeeded at 137 (offset 5 lines).
patching file configure.cmake
==> cmake . -DCMAKE_INSTALL_PREFIX=/usr/local/Cellar/mysql/5.5.15 -DMYSQL_DATADI
==> make
==> make install
==> Caveats
Set up databases to run AS YOUR USER ACCOUNT with:
unset TMPDIR
mysql_install_db --verbose --user=`whoami` --basedir="$(brew --prefix mysql)" --datadir=/usr/local/var/mysql --tmpdir=/tmpTo set up base tables in another folder, or use a different user to run
mysqld, view the help for mysqld_install_db:
mysql_install_db --helpand view the MySQL documentation:
* http://dev.mysql.com/doc/refman/5.5/en/mysql-install-db.html
* http://dev.mysql.com/doc/refman/5.5/en/default-privileges.htmlTo run as, for instance, user "mysql", you may need to `sudo`:
sudo mysql_install_db ...options...Start mysqld manually with:
mysql.server startNote: if this fails, you probably forgot to run the first two steps up above
A "/etc/my.cnf" from another install may interfere with a Homebrew-built
server starting up correctly.To connect:
mysql -urootTo launch on startup:
if this is your first install:
mkdir -p ~/Library/LaunchAgents
cp /usr/local/Cellar/mysql/5.5.15/com.mysql.mysqld.plist ~/Library/LaunchAgents/
launchctl load -w ~/Library/LaunchAgents/com.mysql.mysqld.plistif this is an upgrade and you already have the com.mysql.mysqld.plist loaded:
launchctl unload -w ~/Library/LaunchAgents/com.mysql.mysqld.plist
cp /usr/local/Cellar/mysql/5.5.15/com.mysql.mysqld.plist ~/Library/LaunchAgents/
launchctl load -w ~/Library/LaunchAgents/com.mysql.mysqld.plistYou may also need to edit the plist to use the correct "UserName".
unset TMPDIR
mysql_install_db --verbose --user=`whoami` --basedir="$(brew --prefix mysql)" --datadir=/usr/local/var/mysql --tmpdir=/tmp
Installing MySQL system tables...
OK
Filling help tables...
OKTo start mysqld at boot time you have to copy
support-files/mysql.server to the right place for your systemPLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER !
To do so, start the server, then issue the following commands:/usr/local/Cellar/mysql/5.5.15/bin/mysqladmin -u root password 'new-password'
/usr/local/Cellar/mysql/5.5.15/bin/mysqladmin -u root -h **********-MacBook-Pro.local password 'new-password'Alternatively you can run:
/usr/local/Cellar/mysql/5.5.15/bin/mysql_secure_installationwhich will also give you the option of removing the test
databases and anonymous user created by default. This is
strongly recommended for production servers.See the manual for more instructions.
You can start the MySQL daemon with:
cd /usr/local/Cellar/mysql/5.5.15 ; /usr/local/Cellar/mysql/5.5.15/bin/mysqld_safe &You can test the MySQL daemon with mysql-test-run.pl
cd /usr/local/Cellar/mysql/5.5.15/mysql-test ; perl mysql-test-run.plPlease report any problems with the /usr/local/Cellar/mysql/5.5.15/scripts/mysqlbug script!
mysql.server start
Starting MySQL
... ERROR! The server quit without updating PID file
mysql_secure_installationを実行すると、socketがないから繋がないというエラーが出る。
Can’t connect to local MySQL server through socket '/tmp/mysql.sock'
Google先生に聞くこと約一日。
ここに書いてあるようにするとなりました。
結論としては、おそらくsocketファイルが存在しなかった。
一度、プロセスをkillした。
killよりはmysql.server stopなどのほうがいいと思います。
$ launchctl load /usr/local/Cellar/mysql/5.5.15/com.mysql.mysqld.plist
こうしたら普通に動きました。
参考までに、my.cnfの中身。
[mysqld]
#Max packetlength to send/receive from to server.
max_allowed_packet=64M
#socket=/var/mysql/mysql.sock
socket=/tmp/mysql.sock
character-set-server=utf8
#This option makes InnoDB to store each created table into its own .ibd file.
innodb_file_per_table[mysql]
default-character-set=utf8[client]
#socket=/var/mysql/mysql.sock
socket=/tmp/mysql.sock
default-character-set=utf8
MySQLのアンインストールのメモ
MySQLがHomebrewでインストールしたものに加えて、昔ダウンロードして入れたのをそのままにしていたので、両方共MySQLをアンインストールしました。
まず、HomebrewでMySQLをアンインストール!
brew uninstall mysql
続いて、MySQLのアンインストール。
rm -rf /usr/local/mysql
rm -rf /usr/local/mysql-5.5.15-osx10.6-x86_64
sudo rm -rf /Library/StartupItems/MYSQLCOM
sudo rm -rf /Library/PreferencePages/MYSQL.prePane
sudo rm -rf /Library/Receipts/mysql-.pkg
下から2つは、入っていなかったみたいだけど念のためにコマンドを叩きました。
参考にしたところ。ありがとうございました!!
機会忍者 MySQLのアンインストール方法(MAC OS X)
マオの徒然開発日誌 MacからMySQLをアンインストールする方法
Homebrewでtmuxをインストールしたよ。
すっかり年明けしてしまっているけど・・・・。
Homebrewでtmuxをインストールしたよ。
なんとなく、tmuxというのをインストールしてみたくなったので、Homebrewでインストールしてみました。
まず、Homebrewのインストール。
/usr/bin/ruby -e "$(curl -fsSL https://raw.github.com/gist/323731)"
なおtmuxをインストールする際には、libevent*1が必要になります。
brew install libevent
==> Downloading https://github.com/downloads/libevent/libevent/libevent-2.0.16-s
######################################################################## 100.0%
==> ./configure --prefix=/usr/local/Cellar/libevent/2.0.16
==> make
1 ==> make install
/usr/local/Cellar/libevent/2.0.16: 48 files, 1.9M, built in 48 seconds
続いて、tmuxをインストール。
==> brew install tmux
Downloading http://sourceforge.net/projects/tmux/files/tmux/tmux-1.5/tmux-1.
######################################################################## 100.0%
==> ./configure --prefix=/usr/local/Cellar/tmux/1.5 --sysconfdir=/usr/local/etc
==> make install
==> Caveats
Bash completion script was installed to:
/usr/local/etc/bash_completion.d/tmux
==> Summary
/usr/local/Cellar/tmux/1.5: 5 files, 532K, built in 16 seconds
これでインストール完了。
Homebrewがあると楽です。
*1:libevent1.4か2.0