Comments (3)
Thanks for the screenshot. I'm willing to accept a PR that adds a colorized WARN
, ERROR
or FATAL
prefix for those levels (leaving the log message itself un-colorized). No prefix or color for INFO
. Will that still work for you?
from airbrussh.
Thanks for the idea! Could you show me a screenshot of some Airbrussh output that shows what your changes look like? I'm particularly interested in examples of error messages you are colorizing.
If you are referring to stderr command output, I don't want to color stderr red because stderr is not necessary error messages. Often times it is just debug messages or progress indication. Colorizing those in red would give the user the mistaken impression that something has gone wrong. This was one problem in Capistrano's pretty
output that Airbrussh was specifically designed to correct.
from airbrussh.
Alright, here is how it looks (OS X Terminal):
This is with the code from above, in my Commit (https://github.com/klyonrad/airbrussh/commit/8b57a477cdc555fae6b3b571e1136cc92da87c98) I only colorized the verbosity Label, which makes more sense.
If you are referring to stderr command output, I don't want to color stderr red because stderr
I didn't check for that, but judging from the Code the write_log_message
method is only used for LogMessage
instances
def write(obj)
case obj
when SSHKit::Command
log_command_start(obj)
log_and_clear_command_output(obj, :stderr)
log_and_clear_command_output(obj, :stdout)
log_command_exit(obj) if obj.finished?
when SSHKit::LogMessage
write_log_message(obj)
end
end
from airbrussh.
Related Issues (20)
- AppVeyor CI (Windows) builds failing with net-ssh 4.0.0
- command_output HOT 9
- Colors in the capistrano.log file HOT 3
- Circular dependency warning
- Empty console output HOT 9
- Customize output to show server hostname HOT 1
- Mocha::NotInitializedError on stubbed tests when running minitest locally HOT 2
- "invalid byte sequence in UTF-8" when rsyncing files with international character
- Make rake a gem dependency HOT 3
- Make ConsoleFormatter's context configurable HOT 5
- Console error only when using Spring HOT 1
- Test on ruby 3
- Travis-CI builds are no longer working HOT 3
- Replace Travis with CircleCI HOT 1
- "Last 20 lines" of log file should not be truncated to console width
- IO.console can be nil
- Vague and unhelpful error message if log cannot be created HOT 4
- Hostname in output HOT 1
- Tests fail under Ruby 2.4.0
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from airbrussh.