我對Rails很陌生,正在嘗試着手,但遇到了一個問題,我搜索了一遍,似乎很多人都遇到了同樣的問題,但我要麼不明白他們的解決方案,或似乎沒有他們修改的文件,以解決它,Rails生成控制器頁面主頁:幫助器錯誤
我目前使用Windows並通過Git Bash運行所有命令,我有Ruby v2.2.4p230
和Rails v4.2.5.1
,通過混帳擊,如果我去了localhost3000
我剛纔運行這些命令
cd ~/Desktop
rails new pinteresting
cd pinteresting
rails generate controller pages home
rails server
所以,現在,它給我的基本樣本應用這是很好的,但後來我嘗試訪問的網頁/家,我得到三個錯誤之一的佈局,
Missing helper file helpers/c:/users/acer_pc/desktop/pinteresting/app/helpers/application_helper.rb_helper.rb
Missing helper file helpers/c:/users/acer_pc/desktop/pinteresting/app/helpers/pages_helper.rb_helper.rb
Missing template pages/home, application/home with {:locale=>[:en], :formats=>[:html], :variants=>[], :handlers=>[:erb, :builder, :raw, :ruby, :coffee, :jbuilder]}. Searched in: * "c:/Users/Acer-PC/desktop/pinteresting/app/views"
如果有幫助,這是文件夾https://github.com/Fuledbyramen/pinteresting
做工精細,可能是Windows的一個問題。 – danielrsmith
退房:http://stackoverflow.com/questions/27871726/strange-error-in-rails-missing-helper/27909917#27909917 – danielrsmith
什麼是$ HOME的使用Git的Bash shell的價值? [Here](http://markb.co.uk/portable-git-windows-setting-home-environment-variable.html)是正確設置$ HOME的指南,因此它沒有混合使用Windows路徑名Rails正在生成的* nix路徑名。 –