From dale.poulter at Vanderbilt.Edu Sun May 20 19:41:07 2012 From: dale.poulter at Vanderbilt.Edu (Poulter, Dale) Date: Sun, 20 May 2012 14:41:07 -0500 Subject: [Umlaut-general] V3 -- what am I missing Message-ID: <7288D49C0448E840B752320350AFA94E014258F624@its-hcwnem03.ds.Vanderbilt.edu> Good afternoon all, I have been attempting to work though the asset pipeline for the past couple of days and have had zero success. My goal is just to change the css. I have stepped through " customize css" on https://github.com/team-umlaut/umlaut/wiki/Customizing without success - no changes appear after restarting. Any idea what I am missing? ./app/assets/application.css /* * This is a manifest file that'll be compiled into application.css, which will include all the files * listed below. * * Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets, * or vendor/assets/stylesheets of plugins, if any, can be referenced here using a relative path. * * You're free to add application-wide styles to this file and they'll appear at the top of the * compiled file, but it's generally better to create a new file per style scope. * *= require_self * * The base Umlaut styles: *= require 'umlaut' * *= require_tree . */ /* Umlaut needs a jquery-ui theme CSS. Here's an easy way to get one, * you can replace with another theme. * * Note, CSS @import needs to be the first line in a CSS file. This will * become so if 'require_self' is included above, as the FIRST sprockets * require, and this @import line is the first non-comment line in this * file. */ @import url(//ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/themes/ui-lightness/jquery-ui.css); /app/assets/stylesheets/vu.css.erb .umlaut .header h1 { /* hide text for visual browsers but leave readable by screen readers, we're going to provide a background img for visual instead */ position:absolute; left:-10000px; top:auto; width:1px; height:1px; overflow:hidden; } .umlaut .header { background: url(<%= asset_path 'signature_new2.jpg' %>) no-repeat; height: 36px; /* height of your image, need to make room */ } --Dale --------------------------------------- Dale Poulter Coordinator, Search and Core Services Library Digital Services Vanderbilt University 419 21st Avenue South, Room 812 Nashville, TN 37203-2427 (615)343-5388 (615)343-8834 (fax) (615)207-9705 (cell) dale.poulter at vanderbilt.edu -------------- next part -------------- An HTML attachment was scrubbed... URL: From rochkind at jhu.edu Mon May 21 14:37:28 2012 From: rochkind at jhu.edu (Jonathan Rochkind) Date: Mon, 21 May 2012 10:37:28 -0400 Subject: [Umlaut-general] V3 -- what am I missing In-Reply-To: <7288D49C0448E840B752320350AFA94E014258F624@its-hcwnem03.ds.Vanderbilt.edu> References: <7288D49C0448E840B752320350AFA94E014258F624@its-hcwnem03.ds.Vanderbilt.edu> Message-ID: <4FBA5328.7050100@jhu.edu> Hi Dale, sorry to hear you're having troubles. I've found that Rails can sometimes get confused (or confuse the browser) about caching the CSS assets in development mode, using an old version. This can especially happen if you've been switching between development and production mode execution of your app. Try this: * delete the ./public/assets folder in your app * delete the ./tmp/cache/assets folder in your app, if present * also delete the cache in your _browser_. See if that fixes it up. If not, we'll have to debug a bit more. The source you pasted looks to me like it _ought_ to work. If you are running your app in _production_ mode though, you'll have to manually 'recompile' the assets -- are you running in production mode? The Rails Guide on the asset pipeline is a pretty good overview of what's going on. http://guides.rubyonrails.org/asset_pipeline.html But please feel free to ask questions here too (and you don't need to wait through two days of frustration before doing so!). You can also try finding me or other library folks who know Rails on the #code4lib IRC channel on freenode. Jonathan On 5/20/2012 3:41 PM, Poulter, Dale wrote: > Good afternoon all, > > I have been attempting to work though the asset pipeline for the past > couple of days and have had zero success. My goal is just to change the > css. I have stepped through ? customize css? on > https://github.com/team-umlaut/umlaut/wiki/Customizing without success ? > no changes appear after restarting. Any idea what I am missing? > > ./app/assets/application.css > > /* > > * This is a manifest file that'll be compiled into application.css, > which will include all the files > > * listed below. > > * > > * Any CSS and SCSS file within this directory, lib/assets/stylesheets, > vendor/assets/stylesheets, > > * or vendor/assets/stylesheets of plugins, if any, can be referenced > here using a relative path. > > * > > * You're free to add application-wide styles to this file and they'll > appear at the top of the > > * compiled file, but it's generally better to create a new file per > style scope. > > * > > *= require_self > > * > > * The base Umlaut styles: > > *= require 'umlaut' > > * > > *= require_tree . > > */ > > /* Umlaut needs a jquery-ui theme CSS. Here's an easy way to get one, > > * you can replace with another theme. > > * > > * Note, CSS @import needs to be the first line in a CSS file. This will > > * become so if 'require_self' is included above, as the FIRST sprockets > > * require, and this @import line is the first non-comment line in this > > * file. > > */ > > @import > url(//ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/themes/ui-lightness/jquery-ui.css); > > > /app/assets/stylesheets/vu.css.erb > > .umlaut .header h1 { > > /* hide text for visual browsers but leave readable by screen > > readers, we're going to provide a background img for visual > > instead */ > > position:absolute; > > left:-10000px; > > top:auto; > > width:1px; > > height:1px; > > overflow:hidden; > > } > > .umlaut .header { > > background: url(<%= asset_path 'signature_new2.jpg' %>) no-repeat; > > height: 36px; /* height of your image, need to make room */ > > } > > --Dale > > --------------------------------------- > Dale Poulter > > Coordinator, Search and Core Services > > Library Digital Services > Vanderbilt University > > 419 21st Avenue South, Room 812 > Nashville, TN 37203-2427 > (615)343-5388 > (615)343-8834 (fax) > (615)207-9705 (cell) > dale.poulter at vanderbilt.edu > > > > _______________________________________________ > Umlaut-general mailing list > Umlaut-general at rubyforge.org > http://rubyforge.org/mailman/listinfo/umlaut-general From dale.poulter at Vanderbilt.Edu Tue May 22 01:04:16 2012 From: dale.poulter at Vanderbilt.Edu (Poulter, Dale) Date: Mon, 21 May 2012 20:04:16 -0500 Subject: [Umlaut-general] V3 -- what am I missing In-Reply-To: <4FBA5328.7050100@jhu.edu> References: <7288D49C0448E840B752320350AFA94E014258F624@its-hcwnem03.ds.Vanderbilt.edu> <4FBA5328.7050100@jhu.edu> Message-ID: <7288D49C0448E840B752320350AFA94E014258F795@its-hcwnem03.ds.Vanderbilt.edu> Jonathan, Thanks. Once I deleted the two asset folders the web interface only presents an error. When I look at the file system, the app does not recreate these directories. I looked at the app logs and the apache logs and no errors seem to have been recorded -- except that the error page was sent to the browser. I did manually rake assets:precompile but the logs then indicated that the application.css was not precompiled. Any ideas? -----Original Message----- From: Jonathan Rochkind [mailto:rochkind at jhu.edu] Sent: Monday, May 21, 2012 9:37 AM To: umlaut-general at rubyforge.org Cc: Poulter, Dale Subject: Re: [Umlaut-general] V3 -- what am I missing Hi Dale, sorry to hear you're having troubles. I've found that Rails can sometimes get confused (or confuse the browser) about caching the CSS assets in development mode, using an old version. This can especially happen if you've been switching between development and production mode execution of your app. Try this: * delete the ./public/assets folder in your app * delete the ./tmp/cache/assets folder in your app, if present * also delete the cache in your _browser_. See if that fixes it up. If not, we'll have to debug a bit more. The source you pasted looks to me like it _ought_ to work. If you are running your app in _production_ mode though, you'll have to manually 'recompile' the assets -- are you running in production mode? The Rails Guide on the asset pipeline is a pretty good overview of what's going on. http://guides.rubyonrails.org/asset_pipeline.html But please feel free to ask questions here too (and you don't need to wait through two days of frustration before doing so!). You can also try finding me or other library folks who know Rails on the #code4lib IRC channel on freenode. Jonathan On 5/20/2012 3:41 PM, Poulter, Dale wrote: > Good afternoon all, > > I have been attempting to work though the asset pipeline for the past > couple of days and have had zero success. My goal is just to change the > css. I have stepped through " customize css" on > https://github.com/team-umlaut/umlaut/wiki/Customizing without success - > no changes appear after restarting. Any idea what I am missing? > > ./app/assets/application.css > > /* > > * This is a manifest file that'll be compiled into application.css, > which will include all the files > > * listed below. > > * > > * Any CSS and SCSS file within this directory, lib/assets/stylesheets, > vendor/assets/stylesheets, > > * or vendor/assets/stylesheets of plugins, if any, can be referenced > here using a relative path. > > * > > * You're free to add application-wide styles to this file and they'll > appear at the top of the > > * compiled file, but it's generally better to create a new file per > style scope. > > * > > *= require_self > > * > > * The base Umlaut styles: > > *= require 'umlaut' > > * > > *= require_tree . > > */ > > /* Umlaut needs a jquery-ui theme CSS. Here's an easy way to get one, > > * you can replace with another theme. > > * > > * Note, CSS @import needs to be the first line in a CSS file. This will > > * become so if 'require_self' is included above, as the FIRST sprockets > > * require, and this @import line is the first non-comment line in this > > * file. > > */ > > @import > url(//ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/themes/ui-lightness/jquery-ui.css); > > > /app/assets/stylesheets/vu.css.erb > > .umlaut .header h1 { > > /* hide text for visual browsers but leave readable by screen > > readers, we're going to provide a background img for visual > > instead */ > > position:absolute; > > left:-10000px; > > top:auto; > > width:1px; > > height:1px; > > overflow:hidden; > > } > > .umlaut .header { > > background: url(<%= asset_path 'signature_new2.jpg' %>) no-repeat; > > height: 36px; /* height of your image, need to make room */ > > } > > --Dale > > --------------------------------------- > Dale Poulter > > Coordinator, Search and Core Services > > Library Digital Services > Vanderbilt University > > 419 21st Avenue South, Room 812 > Nashville, TN 37203-2427 > (615)343-5388 > (615)343-8834 (fax) > (615)207-9705 (cell) > dale.poulter at vanderbilt.edu > > > > _______________________________________________ > Umlaut-general mailing list > Umlaut-general at rubyforge.org > http://rubyforge.org/mailman/listinfo/umlaut-general From rochkind at jhu.edu Tue May 22 14:20:01 2012 From: rochkind at jhu.edu (Jonathan Rochkind) Date: Tue, 22 May 2012 10:20:01 -0400 Subject: [Umlaut-general] V3 -- what am I missing In-Reply-To: <7288D49C0448E840B752320350AFA94E014258F795@its-hcwnem03.ds.Vanderbilt.edu> References: <7288D49C0448E840B752320350AFA94E014258F624@its-hcwnem03.ds.Vanderbilt.edu> <4FBA5328.7050100@jhu.edu> <7288D49C0448E840B752320350AFA94E014258F795@its-hcwnem03.ds.Vanderbilt.edu> Message-ID: <4FBBA091.1090708@jhu.edu> Are you intending to run your app in 'development' mode or 'production' mode? If you are running in development mode, you do NOT want to precompile the assets, and if you have precompiled them, you want to delete ./public/assets (which is where the precompiled assets go). If you are running in 'production' mode, you NEED to precompile the assets, and re-precompile them when they change. Your error message about "application.css not precompiled" implies you are running in production mode -- in standard development mode, this error does not occur. But then we have the mystery of why it's saying application.css is not precompiled even though you precompiled assets. Okay, let's start with intentionally running your app in development mode, NOT through apache or passenger. Again delete those directories I mentioned. Start your app with `rails server` from the home directory of your app. It will launch on port 3000. Connect to it on port 3000 and see if it works and you get your assets. Once you have that working, we can move on to getting it to work in production mode too. I'd again recommend reviewing the Rails Guide on the asset pipeline, to understand the general design of the asset pipeline and how it works. On 5/21/2012 9:04 PM, Poulter, Dale wrote: > Jonathan, > > Thanks. Once I deleted the two asset folders the web interface only > presents an error. When I look at the file system, the app does not > recreate these directories. I looked at the app logs and the apache > logs and no errors seem to have been recorded -- except that the > error page was sent to the browser. I did manually rake > assets:precompile but the logs then indicated that the > application.css was not precompiled. Any ideas? > > > -----Original Message----- From: Jonathan Rochkind > [mailto:rochkind at jhu.edu] Sent: Monday, May 21, 2012 9:37 AM To: > umlaut-general at rubyforge.org Cc: Poulter, Dale Subject: Re: > [Umlaut-general] V3 -- what am I missing > > Hi Dale, sorry to hear you're having troubles. > > I've found that Rails can sometimes get confused (or confuse the > browser) about caching the CSS assets in development mode, using an > old version. This can especially happen if you've been switching > between development and production mode execution of your app. Try > this: > > * delete the ./public/assets folder in your app * delete the > ./tmp/cache/assets folder in your app, if present * also delete the > cache in your _browser_. > > See if that fixes it up. If not, we'll have to debug a bit more. The > source you pasted looks to me like it _ought_ to work. If you are > running your app in _production_ mode though, you'll have to manually > 'recompile' the assets -- are you running in production mode? > > The Rails Guide on the asset pipeline is a pretty good overview of > what's going on. > > > http://guides.rubyonrails.org/asset_pipeline.html > > But please feel free to ask questions here too (and you don't need > to wait through two days of frustration before doing so!). You can > also try finding me or other library folks who know Rails on the > #code4lib IRC channel on freenode. > > Jonathan > > On 5/20/2012 3:41 PM, Poulter, Dale wrote: >> Good afternoon all, >> >> I have been attempting to work though the asset pipeline for the >> past couple of days and have had zero success. My goal is just to >> change the css. I have stepped through " customize css" on >> https://github.com/team-umlaut/umlaut/wiki/Customizing without >> success - no changes appear after restarting. Any idea what I am >> missing? >> >> ./app/assets/application.css >> >> /* >> >> * This is a manifest file that'll be compiled into >> application.css, which will include all the files >> >> * listed below. >> >> * >> >> * Any CSS and SCSS file within this directory, >> lib/assets/stylesheets, vendor/assets/stylesheets, >> >> * or vendor/assets/stylesheets of plugins, if any, can be >> referenced here using a relative path. >> >> * >> >> * You're free to add application-wide styles to this file and >> they'll appear at the top of the >> >> * compiled file, but it's generally better to create a new file >> per style scope. >> >> * >> >> *= require_self >> >> * >> >> * The base Umlaut styles: >> >> *= require 'umlaut' >> >> * >> >> *= require_tree . >> >> */ >> >> /* Umlaut needs a jquery-ui theme CSS. Here's an easy way to get >> one, >> >> * you can replace with another theme. >> >> * >> >> * Note, CSS @import needs to be the first line in a CSS file. This >> will >> >> * become so if 'require_self' is included above, as the FIRST >> sprockets >> >> * require, and this @import line is the first non-comment line in >> this >> >> * file. >> >> */ >> >> @import >> url(//ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/themes/ui-lightness/jquery-ui.css); >> >> >> >> /app/assets/stylesheets/vu.css.erb >> >> .umlaut .header h1 { >> >> /* hide text for visual browsers but leave readable by screen >> >> readers, we're going to provide a background img for visual >> >> instead */ >> >> position:absolute; >> >> left:-10000px; >> >> top:auto; >> >> width:1px; >> >> height:1px; >> >> overflow:hidden; >> >> } >> >> .umlaut .header { >> >> background: url(<%= asset_path 'signature_new2.jpg' %>) no-repeat; >> >> height: 36px; /* height of your image, need to make room */ >> >> } >> >> --Dale >> >> --------------------------------------- Dale Poulter >> >> Coordinator, Search and Core Services >> >> Library Digital Services Vanderbilt University >> >> 419 21st Avenue South, Room 812 Nashville, TN 37203-2427 >> (615)343-5388 (615)343-8834 (fax) (615)207-9705 (cell) >> dale.poulter at vanderbilt.edu >> >> >> >> _______________________________________________ Umlaut-general >> mailing list Umlaut-general at rubyforge.org >> http://rubyforge.org/mailman/listinfo/umlaut-general > > From dale.poulter at Vanderbilt.Edu Wed May 23 14:51:16 2012 From: dale.poulter at Vanderbilt.Edu (Poulter, Dale) Date: Wed, 23 May 2012 09:51:16 -0500 Subject: [Umlaut-general] V3 -- what am I missing In-Reply-To: <4FBBA091.1090708@jhu.edu> References: <7288D49C0448E840B752320350AFA94E014258F624@its-hcwnem03.ds.Vanderbilt.edu> <4FBA5328.7050100@jhu.edu> <7288D49C0448E840B752320350AFA94E014258F795@its-hcwnem03.ds.Vanderbilt.edu> <4FBBA091.1090708@jhu.edu> Message-ID: <7288D49C0448E840B752320350AFA94E014258F972@its-hcwnem03.ds.Vanderbilt.edu> Yes, the goals is to run this in production mode to fully simulate our production instance. Running the rails server, it seems to run but does not have any stylesheet information. The log indicated that it cannot find the application.css, but the file is in the ./apps/assets directory. I moved the file into the ./apps/assets/stylesheets directory and the server then started on port 3000. However, it still seems to have an issue running in production mode (I even attempted to recompile the files). Thanks. -----Original Message----- From: Jonathan Rochkind [mailto:rochkind at jhu.edu] Sent: Tuesday, May 22, 2012 9:20 AM To: Poulter, Dale Cc: umlaut-general at rubyforge.org Subject: Re: [Umlaut-general] V3 -- what am I missing Are you intending to run your app in 'development' mode or 'production' mode? If you are running in development mode, you do NOT want to precompile the assets, and if you have precompiled them, you want to delete ./public/assets (which is where the precompiled assets go). If you are running in 'production' mode, you NEED to precompile the assets, and re-precompile them when they change. Your error message about "application.css not precompiled" implies you are running in production mode -- in standard development mode, this error does not occur. But then we have the mystery of why it's saying application.css is not precompiled even though you precompiled assets. Okay, let's start with intentionally running your app in development mode, NOT through apache or passenger. Again delete those directories I mentioned. Start your app with `rails server` from the home directory of your app. It will launch on port 3000. Connect to it on port 3000 and see if it works and you get your assets. Once you have that working, we can move on to getting it to work in production mode too. I'd again recommend reviewing the Rails Guide on the asset pipeline, to understand the general design of the asset pipeline and how it works. On 5/21/2012 9:04 PM, Poulter, Dale wrote: > Jonathan, > > Thanks. Once I deleted the two asset folders the web interface only > presents an error. When I look at the file system, the app does not > recreate these directories. I looked at the app logs and the apache > logs and no errors seem to have been recorded -- except that the error > page was sent to the browser. I did manually rake assets:precompile > but the logs then indicated that the application.css was not > precompiled. Any ideas? > > > -----Original Message----- From: Jonathan Rochkind > [mailto:rochkind at jhu.edu] Sent: Monday, May 21, 2012 9:37 AM To: > umlaut-general at rubyforge.org Cc: Poulter, Dale Subject: Re: > [Umlaut-general] V3 -- what am I missing > > Hi Dale, sorry to hear you're having troubles. > > I've found that Rails can sometimes get confused (or confuse the > browser) about caching the CSS assets in development mode, using an > old version. This can especially happen if you've been switching > between development and production mode execution of your app. Try > this: > > * delete the ./public/assets folder in your app * delete the > ./tmp/cache/assets folder in your app, if present * also delete the > cache in your _browser_. > > See if that fixes it up. If not, we'll have to debug a bit more. The > source you pasted looks to me like it _ought_ to work. If you are > running your app in _production_ mode though, you'll have to manually > 'recompile' the assets -- are you running in production mode? > > The Rails Guide on the asset pipeline is a pretty good overview of > what's going on. > > > http://guides.rubyonrails.org/asset_pipeline.html > > But please feel free to ask questions here too (and you don't need to > wait through two days of frustration before doing so!). You can also > try finding me or other library folks who know Rails on the #code4lib > IRC channel on freenode. > > Jonathan > > On 5/20/2012 3:41 PM, Poulter, Dale wrote: >> Good afternoon all, >> >> I have been attempting to work though the asset pipeline for the past >> couple of days and have had zero success. My goal is just to change >> the css. I have stepped through " customize css" on >> https://github.com/team-umlaut/umlaut/wiki/Customizing without >> success - no changes appear after restarting. Any idea what I am >> missing? >> >> ./app/assets/application.css >> >> /* >> >> * This is a manifest file that'll be compiled into application.css, >> which will include all the files >> >> * listed below. >> >> * >> >> * Any CSS and SCSS file within this directory, >> lib/assets/stylesheets, vendor/assets/stylesheets, >> >> * or vendor/assets/stylesheets of plugins, if any, can be referenced >> here using a relative path. >> >> * >> >> * You're free to add application-wide styles to this file and they'll >> appear at the top of the >> >> * compiled file, but it's generally better to create a new file per >> style scope. >> >> * >> >> *= require_self >> >> * >> >> * The base Umlaut styles: >> >> *= require 'umlaut' >> >> * >> >> *= require_tree . >> >> */ >> >> /* Umlaut needs a jquery-ui theme CSS. Here's an easy way to get one, >> >> * you can replace with another theme. >> >> * >> >> * Note, CSS @import needs to be the first line in a CSS file. This >> will >> >> * become so if 'require_self' is included above, as the FIRST >> sprockets >> >> * require, and this @import line is the first non-comment line in >> this >> >> * file. >> >> */ >> >> @import >> url(//ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/themes/ui-lightne >> ss/jquery-ui.css); >> >> >> >> /app/assets/stylesheets/vu.css.erb >> >> .umlaut .header h1 { >> >> /* hide text for visual browsers but leave readable by screen >> >> readers, we're going to provide a background img for visual >> >> instead */ >> >> position:absolute; >> >> left:-10000px; >> >> top:auto; >> >> width:1px; >> >> height:1px; >> >> overflow:hidden; >> >> } >> >> .umlaut .header { >> >> background: url(<%= asset_path 'signature_new2.jpg' %>) no-repeat; >> >> height: 36px; /* height of your image, need to make room */ >> >> } >> >> --Dale >> >> --------------------------------------- Dale Poulter >> >> Coordinator, Search and Core Services >> >> Library Digital Services Vanderbilt University >> >> 419 21st Avenue South, Room 812 Nashville, TN 37203-2427 >> (615)343-5388 (615)343-8834 (fax) (615)207-9705 (cell) >> dale.poulter at vanderbilt.edu >> >> >> >> _______________________________________________ Umlaut-general >> mailing list Umlaut-general at rubyforge.org >> http://rubyforge.org/mailman/listinfo/umlaut-general > > From rochkind at jhu.edu Wed May 23 15:05:06 2012 From: rochkind at jhu.edu (Jonathan Rochkind) Date: Wed, 23 May 2012 11:05:06 -0400 Subject: [Umlaut-general] V3 -- what am I missing In-Reply-To: <7288D49C0448E840B752320350AFA94E014258F972@its-hcwnem03.ds.Vanderbilt.edu> References: <7288D49C0448E840B752320350AFA94E014258F624@its-hcwnem03.ds.Vanderbilt.edu> <4FBA5328.7050100@jhu.edu> <7288D49C0448E840B752320350AFA94E014258F795@its-hcwnem03.ds.Vanderbilt.edu> <4FBBA091.1090708@jhu.edu> <7288D49C0448E840B752320350AFA94E014258F972@its-hcwnem03.ds.Vanderbilt.edu> Message-ID: <4FBCFCA2.2000101@jhu.edu> Okay, I'm suggesting _first_ verify you have things working in 'development' mode. THEN, move on to getting things to work in 'production' mode. Because development mode is easier to debug, and there may be a problem that effects both modes that can be found there. Have you verified you can make it work in development mode? But if we're moving on to production mode, I'd want to know what you are using to deploy -- passenger? You should _not_ be moving around any application.css manually. That's not going to lead you to a solution, don't do that. The _precompiled_ application.css should be in ./public/assets/application.css, but it should be put there automatically by rake assets:precompile, you should not put it there yourself (and if you did, it might be over-written later by Rails). The _source_ of application.css, which is just an Asset Pipeline 'manifest' with some 'require' statements in it, should indeed be ./apps/assets/stylesheets/application.css. The rails generator should have put it there for you, and the Umlaut generator should have added a couple umlaut specific lines to it. Wait, are you trying to 'migrate' the Umlaut 2.x/Rails 2.x application to Rails/Umlaut 3 "in place"? That's gonna be a huge pain to do, and require all sorts of rails knowledge. As I say in the wiki: https://github.com/team-umlaut/umlaut/wiki/Upgrading-from-umlaut-2.x "There is no automated migration tool for moving from Umlaut 2.x to Umlaut 3.x." "You will just have to install Umlaut 3.x following the Installation instructions, and then re-apply your local customizations. This should hopefully not be too hard." I _strongly_ recommend you start an Umlaut 3.x installation fresh, and then re-apply local customizatons, instead of trying to migrate your Umlaut 2.x "in place". Rails 2 -> Rails 3 in-place upgrades are a mess. Sorry, clearly the Rails3 asset pipeline can be more confusing than it should be (blame Rails, not Umlaut), but it's what we've got. On 5/23/2012 10:51 AM, Poulter, Dale wrote: > Yes, the goals is to run this in production mode to fully simulate > our production instance. Running the rails server, it seems to run > but does not have any stylesheet information. The log indicated that > it cannot find the application.css, but the file is in the > ./apps/assets directory. I moved the file into the > ./apps/assets/stylesheets directory and the server then started on > port 3000. However, it still seems to have an issue running in > production mode (I even attempted to recompile the files). Thanks. > > > > -----Original Message----- From: Jonathan Rochkind > [mailto:rochkind at jhu.edu] Sent: Tuesday, May 22, 2012 9:20 AM To: > Poulter, Dale Cc: umlaut-general at rubyforge.org Subject: Re: > [Umlaut-general] V3 -- what am I missing > > Are you intending to run your app in 'development' mode or > 'production' mode? > > If you are running in development mode, you do NOT want to precompile > the assets, and if you have precompiled them, you want to delete > ./public/assets (which is where the precompiled assets go). > > If you are running in 'production' mode, you NEED to precompile the > assets, and re-precompile them when they change. > > Your error message about "application.css not precompiled" implies > you are running in production mode -- in standard development mode, > this error does not occur. But then we have the mystery of why it's > saying application.css is not precompiled even though you precompiled > assets. > > Okay, let's start with intentionally running your app in development > mode, NOT through apache or passenger. Again delete those > directories I mentioned. Start your app with `rails server` from the > home directory of your app. It will launch on port 3000. Connect to > it on port 3000 and see if it works and you get your assets. > > Once you have that working, we can move on to getting it to work in > production mode too. > > I'd again recommend reviewing the Rails Guide on the asset pipeline, > to understand the general design of the asset pipeline and how it > works. > > On 5/21/2012 9:04 PM, Poulter, Dale wrote: >> Jonathan, >> >> Thanks. Once I deleted the two asset folders the web interface >> only presents an error. When I look at the file system, the app >> does not recreate these directories. I looked at the app logs and >> the apache logs and no errors seem to have been recorded -- except >> that the error page was sent to the browser. I did manually rake >> assets:precompile but the logs then indicated that the >> application.css was not precompiled. Any ideas? >> >> >> -----Original Message----- From: Jonathan Rochkind >> [mailto:rochkind at jhu.edu] Sent: Monday, May 21, 2012 9:37 AM To: >> umlaut-general at rubyforge.org Cc: Poulter, Dale Subject: Re: >> [Umlaut-general] V3 -- what am I missing >> >> Hi Dale, sorry to hear you're having troubles. >> >> I've found that Rails can sometimes get confused (or confuse the >> browser) about caching the CSS assets in development mode, using >> an old version. This can especially happen if you've been >> switching between development and production mode execution of your >> app. Try this: >> >> * delete the ./public/assets folder in your app * delete the >> ./tmp/cache/assets folder in your app, if present * also delete >> the cache in your _browser_. >> >> See if that fixes it up. If not, we'll have to debug a bit more. >> The source you pasted looks to me like it _ought_ to work. If you >> are running your app in _production_ mode though, you'll have to >> manually 'recompile' the assets -- are you running in production >> mode? >> >> The Rails Guide on the asset pipeline is a pretty good overview of >> what's going on. >> >> >> http://guides.rubyonrails.org/asset_pipeline.html >> >> But please feel free to ask questions here too (and you don't need >> to wait through two days of frustration before doing so!). You can >> also try finding me or other library folks who know Rails on the >> #code4lib IRC channel on freenode. >> >> Jonathan >> >> On 5/20/2012 3:41 PM, Poulter, Dale wrote: >>> Good afternoon all, >>> >>> I have been attempting to work though the asset pipeline for the >>> past couple of days and have had zero success. My goal is just to >>> change the css. I have stepped through " customize css" on >>> https://github.com/team-umlaut/umlaut/wiki/Customizing without >>> success - no changes appear after restarting. Any idea what I am >>> missing? >>> >>> ./app/assets/application.css >>> >>> /* >>> >>> * This is a manifest file that'll be compiled into >>> application.css, which will include all the files >>> >>> * listed below. >>> >>> * >>> >>> * Any CSS and SCSS file within this directory, >>> lib/assets/stylesheets, vendor/assets/stylesheets, >>> >>> * or vendor/assets/stylesheets of plugins, if any, can be >>> referenced here using a relative path. >>> >>> * >>> >>> * You're free to add application-wide styles to this file and >>> they'll appear at the top of the >>> >>> * compiled file, but it's generally better to create a new file >>> per style scope. >>> >>> * >>> >>> *= require_self >>> >>> * >>> >>> * The base Umlaut styles: >>> >>> *= require 'umlaut' >>> >>> * >>> >>> *= require_tree . >>> >>> */ >>> >>> /* Umlaut needs a jquery-ui theme CSS. Here's an easy way to get >>> one, >>> >>> * you can replace with another theme. >>> >>> * >>> >>> * Note, CSS @import needs to be the first line in a CSS file. >>> This will >>> >>> * become so if 'require_self' is included above, as the FIRST >>> sprockets >>> >>> * require, and this @import line is the first non-comment line >>> in this >>> >>> * file. >>> >>> */ >>> >>> @import >>> url(//ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/themes/ui-lightne >>> >>> ss/jquery-ui.css); >>> >>> >>> >>> > /app/assets/stylesheets/vu.css.erb >>> >>> .umlaut .header h1 { >>> >>> /* hide text for visual browsers but leave readable by screen >>> >>> readers, we're going to provide a background img for visual >>> >>> instead */ >>> >>> position:absolute; >>> >>> left:-10000px; >>> >>> top:auto; >>> >>> width:1px; >>> >>> height:1px; >>> >>> overflow:hidden; >>> >>> } >>> >>> .umlaut .header { >>> >>> background: url(<%= asset_path 'signature_new2.jpg' %>) >>> no-repeat; >>> >>> height: 36px; /* height of your image, need to make room */ >>> >>> } >>> >>> --Dale >>> >>> --------------------------------------- Dale Poulter >>> >>> Coordinator, Search and Core Services >>> >>> Library Digital Services Vanderbilt University >>> >>> 419 21st Avenue South, Room 812 Nashville, TN 37203-2427 >>> (615)343-5388 (615)343-8834 (fax) (615)207-9705 (cell) >>> dale.poulter at vanderbilt.edu >>> >>> >>> >>> _______________________________________________ Umlaut-general >>> mailing list Umlaut-general at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/umlaut-general >> >> > > From rochkind at jhu.edu Tue May 29 21:20:54 2012 From: rochkind at jhu.edu (Jonathan Rochkind) Date: Tue, 29 May 2012 17:20:54 -0400 Subject: [Umlaut-general] Umlaut 3.0 progress, some roadblocks Message-ID: <4FC53DB6.5000108@jhu.edu> So when I put my Umlaut-3.0 based application into production here as a test -- I'm afraid there are still some performance and database connection pool problems. I believe they are due to some bugs in ActiveRecord's support for multi-threading, which we use. I am investigating, and will find a solution one way or another, I have a couple leads. It is indeed very frustrating. So that's what's holding back the 3.0 release at the moment. Just keeping you all updated. From rochkind at jhu.edu Wed May 30 19:50:06 2012 From: rochkind at jhu.edu (Jonathan Rochkind) Date: Wed, 30 May 2012 15:50:06 -0400 Subject: [Umlaut-general] umlaut beta testers -- update your DB Message-ID: <4FC679EE.5020405@jhu.edu> Okay, SOME of the performance problems i was seeing was because I was missing an important index in MySQL. I refactored the db a bit in Umlaut 3.x, and didn't realize this required a new index. If you currently have an Umlaut app running off Umlaut 3.0 beta, you'll want to update and update your db: Update to Umlaut 3.0.0beta10 bundle update umlaut Copy the new Rails migration to your local app: rake umlaut:install:migrations Run the new migration to add the index to your db: rake db:migrate And in your production DB too: RAILS_ENV=production rake db:migrate We're getting closer to an Umlaut 3.0 final release. The new implementation of Rails ConnectionPool which Umlaut monkey patches in seems to be helping too.