Contents contributed and discussions participated by 張 旭
Break Deep Associations - 0 views
-
常寫單元測試的開發者,多半已經養成遇到難測的元件時,就替該元件抽一個 interface 隔離
-
部署的時候再藉由 Dependency Injection 注入真正的實作
-
將它們隔離。這跟 class 抽 interface 其實很像的,都讓耦合下降,提高模組化
- ...1 more annotation...
導入 Vagrant 做開發配置 - 0 views
Durable Queue by Cassandra - 0 views
Getting Started with Docker - Servers for Hackers - 0 views
-
Docker is an isolated portion of the host computer, sharing the host kernel (OS) and even its bin/libraries if appropriate.
-
the Docker Container contains the parts that make Ubuntu different from CoreOS.
-
A Docker container only stays alive as long as there is an active process being run in it.
- ...10 more annotations...
David Verhasselt - Different Ways to Set Attributes in ActiveRecord - 0 views
-
update
-
attribute will be marked as dirty and the change will not be sent to the database yet
-
will change the attribute in the model and pass it straight to the database, without running any validations
- ...9 more annotations...
Asset Pipeline - Ruby on Rails 指南 - 0 views
-
清单文件或帮助方法
-
Sprockets 会按照搜索路径中各路径出现的顺序进行搜索。默认情况下,这意味着 app/assets 文件夹中的静态资源优先级较高,会遮盖 lib 和 vendor 文件夹中的相应文件
-
如果静态资源不会在清单文件中引入,就要添加到预编译的文件列表中,否则在生产环境中就无法访问文件。
- ...36 more annotations...
Embracing REST with mind, body and soul « Plataformatec Blog - 0 views
-
gain with respond_with introduction is more obvious if you compare index, new and show actions
-
you can define supported formats at the class level and tell in the instance the resource to be represented by those formats.
-
when a request comes, for example with format xml, it will first search for a template at users/index.xml. If the template is not available, it tries to render the resource given (in this case, @users) by calling :to_xml on it
- ...6 more annotations...
The Asset Pipeline - Ruby on Rails Guides - 0 views
-
provides a framework to concatenate and minify or compress JavaScript and CSS assets
-
adds the ability to write these assets in other languages and pre-processors such as CoffeeScript, Sass and ERB
-
invalidate the cache by altering this fingerprint
- ...80 more annotations...
The Flatiron School | Why You Don't Need Has_and_belongs_to_many... - 0 views
-
When creating associations between models, you almost never know how this relationship will blossom as your application grows.
-
setup a solid has_many :through relationship with an associated join table, you provide yourself with a huge amount of flexibility down the road.
-
A has_many :through association is used to setup a many to many relationship with another model
- ...2 more annotations...
How to Report Bugs Effectively - 0 views
-
有個理由可以解釋為什麼技術支援工作這麼難做, 原因就是這些亂七八糟的錯誤報告
-
希望全世界的人在報告任何錯誤前都能讀讀這篇短文
-
錯誤報告的目的是要讓程式師能親眼目睹程式出錯
- ...26 more annotations...
The Rails Command Line - Ruby on Rails Guides - 0 views
-
rake --tasks
-
Think of destroy as the opposite of generate.
-
runner runs Ruby code in the context of Rails non-interactively
- ...28 more annotations...
Authentication, Permissions and Roles in Rails with Devise, CanCan and Role Model | Phase2 - 0 views
-
Devise is a modular user authentication system
-
just gradually investigating the components you need for your app and configuring them as you need
-
define permissions
Baseimage-docker: A minimal Ubuntu base image modified for Docker-friendliness - 0 views
-
We encourage you to use multiple processes.
-
Baseimage-docker is a special Docker image that is configured for correct use within Docker containers.
-
A proper Unix system should run all kinds of important system services.
- ...16 more annotations...
Run Reference - Docker Documentation - 0 views
-
In detached mode (-d=true or just -d), all I/O should be done through network connections or shared volumes because the container is no longer listening to the command line where you executed docker run.
-
start the process in the container and attach the console to the process's standard input, output, and standard error. It can even pretend to be a TTY (this is what most command line executables expect) and pass along signals.
-
For interactive processes (like a shell) you will typically want a tty as well as persistent standard input (STDIN), so you'll use -i -t together in most interactive cases.
How To Install and Use Docker: Getting Started | DigitalOcean - 0 views
-
docker as a project offers you the complete set of higher-level tools to carry everything that forms an application across systems and machines - virtual or physical - and brings along loads more of great benefits with it
-
docker daemon: used to manage docker (LXC) containers on the host it runs
-
docker CLI: used to command and communicate with the docker daemon
- ...20 more annotations...
How to Use Docker on OS X: The Missing Guide | Viget - 0 views
-
Docker is a client-server application.
-
The Docker server is a daemon that does all the heavy lifting: building and downloading images, starting and stopping containers, and the like. It exposes a REST API for remote management.
-
The Docker client is a command line program that communicates with the Docker server using the REST API.
- ...9 more annotations...
Better Rails logging | poor effort - 0 views
数据库的最简单实现 - 阮一峰的网络日志 - 0 views
« First
‹ Previous
541 - 560 of 596
Next ›
Last »
Showing 20▼ items per page