[英]Where is the entry point for a Rails application?

I can't find out what file is the first one to be executed when starting a Rails application. Does anybody know?


1 个解决方案



First, to answer the question: the init documentation from July 2011 (Rails 3.0, when this question was asked) points out railties/bin/rails as the first file to run on Rails invocation.

首先,回答這個問題:2011年7月的初始文檔(Rails 3.0,當問到這個問題時)指出railties / bin / rails是第一個在Rails調用上運行的文件。

Second, more generally, this question was asked and answered over four years ago. The link in the first answer still works, but only for the current version (Rails 4 as of early 2016). Those who are looking for historical information on this topic may be best served by trying the Internet Archive. For example, a snapshot of this document from April 2013 (Rails 3.2):

其次,更普遍的是,這個問題在四年前得到了回答。第一個答案中的鏈接仍然有效,但僅適用於當前版本(截至2016年初的Rails 4)。那些正在尋找關於這個主題的歷史信息的人可能最好通過嘗試互聯網檔案。例如,2013年4月該文檔的快照(Rails 3.2):




粤ICP备14056181号  © 2014-2020 ITdaan.com