Commit Graph

6 Commits

Author SHA1 Message Date
Brian Palmer 775df064d4 set only the default_external encoding
setting default_internal will cause issues with reading and writing to
files, and is no longer necessary now that we override
ActiveSupport::SafeBuffer to always be utf-8 encoded.

however, setting default_external is still necessary to correctly read
in files like erb templates, scss files, etc.

fixes #CNVS-2165

test plan: course migrations and other operations that read/write to
files should work, but erb templates should also display without error.
in a console, File.open('test', 'w').external_encoding should be nil.

Change-Id: Ica02ff164a29617e95ee3d65a0e4f31414c2ce33
Reviewed-on: https://gerrit.instructure.com/16143
Reviewed-by: Ethan Vizitei <ethan@12spokes.com>
Tested-by: Jenkins <jenkins@instructure.com>
QA-Review: Brian Palmer <brianp@instructure.com>
2012-12-17 16:57:53 -07:00
Brian Palmer 103b8d1bfc don't set default Encodings in ruby 1.9
closes #CNVS-2165

This is recommended in some guides for upgrading a Rails 2.3 app to Ruby
1.9, but it was causing a lot of problems with file reading and writing,
especially in gems.

Our override for ActiveSupport::SafeBuffer to always be encoded as utf-8
fixes the issue that originally prompted us to add these default
encodings in the first place.

Change-Id: Ifb4649dd6aa86bfb15ff16daa706a5c6df33292a
Reviewed-on: https://gerrit.instructure.com/16079
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Ethan Vizitei <ethan@12spokes.com>
QA-Review: Brian Palmer <brianp@instructure.com>
2012-12-17 10:45:55 -07:00
Brian Palmer d9b75ead14 allow overriding the Gemfile location with BUNDLE_GEMFILE
Change-Id: Idba5b6d7186321fa795bfb2ca0dca39316884208
Reviewed-on: https://gerrit.instructure.com/15363
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Jacob Fugal <jacob@instructure.com>
2012-11-15 14:50:22 -07:00
Brian Palmer 7ecd23899c 1.9.3 fixes
* default all .rb source files to utf-8
 * fix enrollment spec
 * fix external tools spec

Change-Id: Iebbfb580150e67ab95c4126455d405b2c2fe25fa
Reviewed-on: https://gerrit.instructure.com/10719
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Zach Wily <zach@instructure.com>
2012-05-14 12:26:20 -06:00
Brian Palmer 45f54e35ac update our preinitializer.rb
this'll let you run script/console and such without having to cd to the
rails root dir first.

Change-Id: Ic2ff10652afc92ac1e5dc4ebfef97a9a27059e29
Reviewed-on: https://gerrit.instructure.com/2790
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Zach Wily <zach@instructure.com>
2011-03-24 09:39:15 -06:00
Brian Whitmer 8b8173dcc9 Initial commit.
closes #6988138
2011-01-31 18:57:29 -07:00