gulp-cli
gulp-cli copied to clipboard
Use theming-log for logging.
I've implemented configurable logs with theming-log.
But it is needed js-liftoff#95 to configure logs for require flag and completion flag.
I updated this pr based on the current master
branch.
I've modified the above two points about document.
This is a sample:
$ cat .gulp.js
module.exports = {
log: {
theme: require('./my-theme'),
messages: require('./my-msgs'),
}
};
$ cat my-theme.json
{
"ICON": "🥤",
"VERSION": "{bold: {magenta: {1}}}",
"TIMESTAMP": "{yellow: [{NOW: YYYY/MM/DD HH:mm:ss}]} ",
"DESC": "{cyan: {1}}"
}
$ cat my-msgs.json
{
"info": {
"version": "{ICON} {DESC: Gulp version}: {VERSION: {2}}\n{ICON} {DESC: CLI version}: {VERSION: {1}}"
},
"error": {
"gulpfileNotFound": "{ICON} {TIMESTAMP}{ERROR: No gulpfile found}"
}
}
@sttk I'd like to start work on this again. I noticed the HTML files in this PR - what are those used for?
@phated Thanks.
HTML files (and other files in docs/html
) are sample documents to configure themes and messages. It's not necessary and use as refernece of Gulp document.
@phated I created a new branch in my repository, which was based on the current master (v2.2.1), was merged with the change of this PR except doc/html
, and was modified for #177.
https://github.com/sttk/gulp-cli/tree/use_theming-log_2
Should I update this PR with that new branch?
@sttk Yes, please update this branch. It needed a rebase on master anyway.
I hope to find time to review soon.
@sttk would you want to include your gulp libraries inside the gulpjs organization?
@phated I've updated!
would you want to include your gulp libraries inside the gulpjs organization?
Yeah, it's good. I'd like to include copy-props, each-props and theming-log into gulp organization.
I forgot to test about #177, and did it.
@sttk thank you! I have confirmed that gulpjs members can create and transfer repositories, so you can transfer those projects when you have time.
@sttk I believe this needs conflicts resolved since I merged #239
@sttk are you planning to bring this up-to-date for the gulp-cli v3.0.0 release or should I plan to finish the remaining tasks without color configuration?
@phated I'm tackling this issue. Hopefully, I'll finish this weekend. I hope to include this feature into gulp-cli v3.0.0. Please give me a little more time.
https://github.com/sttk/gulp-cli/commits/ci-test/
@sttk 👍 sounds good. I will wait for your changes.
@phated I've completed the changes for this PR. Please review it.
I've added handling for yargs error message.
I've made several changes. In Addition, I've removed config.description
as its purpose overlaps with config.log.msgs.tasks/tasksJson.description
.
@phated I've modified what you pointed out except some points still under discussion.
@phated I want to add --no-theme
cli flag and flags.noTheme
config flag that are not to use log theme and messages in a config file. I believe they could be useful when reporting issues or when not using the theme specified in the project.
Can I add them to this PR?