Module: Shakapacker
- Extended by:
- Shakapacker
- Included in:
- Shakapacker
- Defined in:
- lib/shakapacker.rb,
lib/shakapacker/runner.rb,
lib/shakapacker/version.rb,
lib/shakapacker/utils/misc.rb,
lib/shakapacker/base_strategy.rb,
lib/shakapacker/utils/manager.rb,
lib/shakapacker/mtime_strategy.rb,
lib/shakapacker/webpack_runner.rb,
lib/shakapacker/digest_strategy.rb,
lib/shakapacker/version_checker.rb,
lib/shakapacker/compiler_strategy.rb,
lib/shakapacker/dev_server_runner.rb,
lib/shakapacker/deprecation_helper.rb,
lib/shakapacker/utils/version_syntax_converter.rb
Defined Under Namespace
Modules: Helper, Utils
Classes: BaseStrategy, Commands, Compiler, CompilerStrategy, Configuration, DevServer, DevServerProxy, DevServerRunner, DigestStrategy, Engine, Env, Instance, Manifest, MtimeStrategy, Runner, VersionChecker, WebpackRunner
Constant Summary
collapse
- DEFAULT_ENV =
"production".freeze
- VERSION =
Change the version in package.json too, please!
"8.0.2".freeze
- SHELL =
Thor::Shell::Color.new
Instance Method Summary
collapse
Instance Method Details
#ensure_log_goes_to_stdout ⇒ Object
27
28
29
30
31
32
33
|
# File 'lib/shakapacker.rb', line 27
def ensure_log_goes_to_stdout
old_logger = Shakapacker.logger
Shakapacker.logger = Logger.new(STDOUT)
yield
ensure
Shakapacker.logger = old_logger
end
|
#instance=(instance) ⇒ Object
11
12
13
|
# File 'lib/shakapacker.rb', line 11
def instance=(instance)
@instance = instance
end
|
#puts_deprecation_message(message) ⇒ Object
6
7
8
|
# File 'lib/shakapacker/deprecation_helper.rb', line 6
def puts_deprecation_message(message)
SHELL.say "\n#{message}\n", :yellow
end
|
#with_node_env(env) ⇒ Object
19
20
21
22
23
24
25
|
# File 'lib/shakapacker.rb', line 19
def with_node_env(env)
original = ENV["NODE_ENV"]
ENV["NODE_ENV"] = env
yield
ensure
ENV["NODE_ENV"] = original
end
|