Ubuntu 14.04 Theme をnumixへ変更

install sudo apt-add-repository ppa:numix/ppa sudo aptitude update sudo aptitude install numix-gtk-theme #sudo aptitude install numix-icon-theme-utouch sudo aptitude install numix-icon-theme sudo aptitude install numix-wallpaper-saucy # ↓この丸いアイコンがすごくよい。 sudo aptitude install numix-icon-theme-circle theme setting setting from tweak-tool

2014-10-08 ·  2014-10-08 · 1 分 · 34 文字

Debian wheezy に Ubuntu 14.04 クライアントからSSH接続する

[Client] Key generate create pub, private key at ~/.ssh cd ~/.ssh ssh-keygen -t rsa # created under files id_rsa id_rsa.pub upload public key to server. scp id_rsa.pub [server ip address]:~/ [Client] .ssh/config vim ~/.ssh/config Host [server name] HostName [server name or ipaddress] Port 22 User [login user name] IdentityFile ~/.ssh/id_rsa [server] regist pub key login the server. cd ~ cat rsa.pub >> ~/.ssh/authorized_keys [server] sshd settings sudo vim /etc/ssh/sshd_config check the settings...

2014-10-07 ·  2014-10-07 · 1 分 · 78 文字

Ubuntu 14.04 libwebsockets クライアントを試す

libwebsockets build sudo aptitude install cmake cd ~/works git clone git://git.libwebsockets.org/libwebsockets cd libwebsockets/ mkdir build cd build cmake .. make -j8 # sudo make install サンプルとして作成したサーバに libwebsocket-test-echo サンプルからアクセスする server rails 上に em-websocket を実装したcontrollerを用意する ※ rails に関しては、省略 Ubuntu 14.04 libwebsockets クライアントを試す libwebsockets build sudo aptitude install cmake cd ~/works git clone git://git.libwebsockets.org/libwebsockets cd libwebsockets/ mkdir build cd build cmake .. make -j8 # sudo make install サンプルとして作成したサーバに libwebsocket-test-echo サンプルからアクセスする server rails 上に em-websocket を実装したcontrollerを用意する...

2014-10-03 ·  2014-10-03 · 2 分 · 224 文字

Ubuntu 14.04 rails scoffoldでEntity作成、からDB migrateまで

以下のような形式で generate できる bundle exec rails generate scaffold [entity_name] [column_name]:[data_type][column_name]:[data_type] # 間違えたら! bundle exec rails destroy scaffold "name" data type integer, string, timestamp などなどが使える Generateした各ファイルをそれぞれ条件を追加するように、下記のように修正 db/migrate/YYYYMMDDhhmmss_create_[entity_name].rb 以下のように、NotNullや桁指定、デフォルト指定ができる class CreateEvents < ActiveRecord::Migration def change create_table :[entity_name] do |t| t.string :column_name, :null => false, :limit => 1, :default => 0 t.timestamps end end end 作成した rb ファイルで、DB再作成 # 通常DB作成 # bundle exec rake db:migrate # DB再作成(db/schema.rb より再実行) # bundle exec rake db:reset # DB再作成(db/migrate/**....

2014-10-03 ·  2014-10-03 · 1 分 · 86 文字

Ubuntu 14.04 ruby2.1.2 で ActiveRecord4.1.6 を使用し、postgresql4.1.6 へアクセス

まずはdatabase 確認 sudo su postgres -c psql install activerecord,pg mkdir -p ~/works/99_sample/02_activerecord cd ~/works/99_sample/02_activerecord gem install activerecord gem install pg gem list DBユーザtest_nameを作成しておく sudo su postgres -c psql create role test_name superuser login; \password test_name Enter new password: test_name Enter it again: test_name create database test_name; config/database.yml mkdir -p config && vim config/database.yml db: production: adapter: postgresql host: localhost username: test_name password: test_name database: test_name development: adapter: postgresql host: localhost username: test_name password: test_name database: test_name db/migrate配下に、3ファイルを配置(rails環境からコピー) mkdir -p db/migrate...

2014-10-03 ·  2014-10-03 · 1 分 · 130 文字