2013-06-22 6 views
1

이전 앱을 자산 pipline으로 업그레이드하는 중이지만 3.1로 업그레이드하는 라이언 베이츠 자습서를 따른 후에도 여전히 pipline을 사용할 수 없습니다. 내 업그레이드 프로세스를 배제하기 위해 새로운 레일스 응용 프로그램을 만들고 커피 스크립팅을 시도하고/assets/javascripts 폴더에 다른 파일을 추가하려고했지만 application.js 이외의 추가 파일은 렌더링되지 않는 것 같습니다.Rails 3.1 자산 파이프 라인이 작동하지 않습니다.

이 내 application.js 파일입니다

// This is a manifest file that'll be compiled into including all the files listed below. 
// Add new JavaScript/Coffee code in separate files in this directory and they'll automatically 
// be included in the compiled file accessible from http://example.com/assets/application.js 
// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the 
// the compiled file. 
// 
//= require jquery 
//= require jquery_ujs 
//= require_tree . 


alert("this displays fine"); 

그리고 추가 dogs.js.coffee 파일 :

# Place all the behaviors and hooks related to the matching controller here. 
# All this logic will automatically be available in application.js. 
# You can use CoffeeScript in this file: http://jashkenas.github.com/coffee-script/ 

alert "cant see this!" 

톱니 문제가 될 것으로 보인다하지만 난 정말 캔트와 함께 사람을 찾아 동일한 문제 또는 assets 폴더 내의 추가 자바 스크립트 파일이 require_tree를 통해 application.js에 포함되지 않은 경우에 대한 정보.

gem 'rails', '3.1.1' 
gem 'sqlite3' 
group :assets do 
    gem 'sass-rails', '~> 3.1.4' 
    gem 'coffee-rails', '~> 3.1.1' 
    gem 'uglifier', '>= 1.0.3' 
end 
gem 'jquery-rails' 

group :test do 
    # Pretty printed test output 
    gem 'turn', :require => false 
end 

내 루비 버전이 어떤 도움 2.0.0p195

덕분에 :

여기에 내 보석 파일입니다!

G

답변

0

내가 다음, 1.9.3을 루비 다운 그레이드 보석을 다시 설치 루비 버전은 내 문제였다 보인다 지금은 작동한다!

관련 문제