Skip to content

Commit

Permalink
Merge e9df7a9 into ef58c59
Browse files Browse the repository at this point in the history
  • Loading branch information
sttk committed Jun 12, 2019
2 parents ef58c59 + e9df7a9 commit 1cb90fc
Show file tree
Hide file tree
Showing 48 changed files with 2,185 additions and 245 deletions.
1 change: 1 addition & 0 deletions .eslintignore
@@ -1,2 +1,3 @@
**/*.babel.js
coverage
docs
2 changes: 1 addition & 1 deletion .eslintrc
@@ -1,7 +1,7 @@
{
"extends": "gulp",
"rules": {
"max-len": [1, 90],
"max-len": [1, 100],
"max-statements": [1, 40],
"no-console": "off"
}
Expand Down
2 changes: 2 additions & 0 deletions README.md
Expand Up @@ -110,6 +110,8 @@ Supported configurations properties:
| flags.series | Run tasks given on the CLI in series (the default is parallel) |
| flags.require | An array of modules to require before running the gulpfile. Any relative paths will be resolved against the `--cwd` directory (if you don't want that behavior, use absolute paths) |
| flags.nodeFlags | An array of flags used to forcibly respawn the process upon startup. For example, if you always want your gulpfiles to run in node's harmony mode, you can set `--harmony` here |
| log.messages.* | Configure log messages. (See [configurable-log-msgs.html](./docs/html/configurable-log-msgs.html)) |
| log.theme.* | Configure log theme. (See [configurable-log-theme.html](./docs/html/configurable-log-theme.html)) |

## Flags

Expand Down
41 changes: 41 additions & 0 deletions docs/html/configurable-log-msgs.html
@@ -0,0 +1,41 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8"/>
<meta content="width=device-width,initial-scale=1" name="viewport">
<title>Configurable Log Messages</title>
<script src="js/copy-props.min.js"></script>
<script src="js/theming-log.min.js"></script>
<script>var module = { exports: {} };</script>
<script src="../../lib/shared/log/messages.js"></script>
<script>var msgs = module.exports;</script>
<script src="../../lib/shared/log/theme.js"></script>
<script>var theme = module.exports;</script>
<script src="js/msg-dic.js"></script>
<script src="js/page.js"></script>
<script>window.addEventListener('DOMContentLoaded', writeMsgs);</script>
<link href="css/page.css" rel="stylesheet" type="text/css">
</head>
<body>
<header>
<h1>Configurable Log Messages</h1>
<p>Gulp's log messages can be configured with <code>.gulp.*</code> file. Since this function is realized by using <a href="https://github.com/sttk/theming-log">theming-log</a>, the format of log message templates follows the specification of it. An example is as below:</p>
<div class="configfile-example jscode"><code><pre>
// .gulp.js
module.exports = {
log: {
messages: {
help: {
usage: '\n{TITLE: Usage:} gulp {OPTION: [options]} {TASK: tasks}',
...,
},
...,
},
},
};
</pre></code></div>
</header>
<main>
</main>
</body>
</html>
41 changes: 41 additions & 0 deletions docs/html/configurable-log-theme.html
@@ -0,0 +1,41 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8"/>
<meta content="width=device-width,initial-scale=1" name="viewport">
<title>Configurable Log Theme</title>
<script src="js/copy-props.min.js"></script>
<script src="js/theming-log.min.js"></script>
<script>var module = { exports: {} };</script>
<script src="../../lib/shared/log/theme.js"></script>
<script>var theme = module.exports;</script>
<script src="js/theme-dic.js"></script>
<script src="js/page.js"></script>
<script>window.addEventListener('DOMContentLoaded', writeTheme);</script>
<link href="css/page.css" rel="stylesheet" type="text/css">
</head>
<body>
<header>
<h1>Configurable Log Theme</h1>
<p>Gulp's log outputs have theme and the theme can be configured with <code>.gulp.*</code> file. Since this function is realized by using <a href="https://github.com/sttk/theming-log">theming-log</a>, the format of log message templates follows the specification of it. An example is as below:</p>
<div class="configfile-example jscode"><code><pre>
// .gulp.js
module.exports = {
log: {
theme: {
...,
TASK: '{cyan: {1}}',
TASKS: {
NAME: '{TASK: {1}}',
...,
},
...,
},
},
};
</pre></code></div>
</header>
<main>
</main>
</body>
</html>
57 changes: 57 additions & 0 deletions docs/html/css/page.css
@@ -0,0 +1,57 @@
@charset "utf-8";

header {
border-bottom: solid 1px gray;
}

main {
margin: 0.5rem;
}

section {
padding: 1rem 0rem; margin: 0rem 0.5rem;
border-bottom: solid 1px gray;
}

h1 {
margin: 0.5rem;
}

h2 {
margin: 0rem -0.5rem 0.8rem -0.5rem;
font-family: Helvetica, arial, sans-serif;
}

h3 {
margin-bottom: 0.3rem;
}

p {
margin: 0rem; padding: 0.3rem 1rem;
}

pre {
margin: 0px; padding: 0px;
}

code {
background-color: #eee;
}

ol {
margin: 0px;
}

div.shell {
border: solid 1px white; color: white; background-color: #333;
padding: 0.5rem; overflow-x: auto;
}

div.jscode {
border: solid 1px #ccc; background-color: #eee;
padding: 0.3rem; overflow-x: auto;
}

div.configfile-example {
margin: 1rem 2rem;
}
2 changes: 2 additions & 0 deletions docs/html/js/copy-props.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 1cb90fc

Please sign in to comment.