Module: Hardhat
- Included in:
- System
- Defined in:
- lib/hardhat.rb,
lib/hardhat/version.rb
Defined Under Namespace
Modules: Repository, System Classes: Dependency, Installer
Constant Summary collapse
- PREFIX =
Prefix to be printed before every message.
"d:) ->"
- VERSION =
"0.0.1"
Instance Method Summary collapse
- #error(string) ⇒ Object
-
#inform(string) ⇒ Object
Printing methods: * inform : info about the build.
- #warn(string) ⇒ Object
Instance Method Details
#error(string) ⇒ Object
22 23 24 |
# File 'lib/hardhat.rb', line 22 def error(string) puts "#{PREFIX.magenta} #{"ERROR:".red} #{string}".red end |
#inform(string) ⇒ Object
Printing methods:
-
inform : info about the build.
-
warn : non critical errors.
-
error : blocking errors.
Use these methods for interacting with STDOUT exclusively, to help keep the build process feel uniform.
14 15 16 |
# File 'lib/hardhat.rb', line 14 def inform(string) puts "#{PREFIX.magenta} #{string}" end |
#warn(string) ⇒ Object
18 19 20 |
# File 'lib/hardhat.rb', line 18 def warn(string) puts "#{PREFIX.magenta} #{"WARNING:".yellow} #{string}".yellow end |