FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
bitcore/gulpfile.js at master · BeaverCoin-Project/bitcore · GitHub
BeaverCoin-Project
bitcore
Repository navigation
Code
Issues
Pull requests
Actions
Projects
Wiki
Security and quality
Insights
Expand file tree
Breadcrumbs
bitcore
/
gulpfile.js
Copy path
More file actions
More file actions
Latest commit
History
History
History
25 lines (20 loc) · 896 Bytes
Breadcrumbs
bitcore
/
gulpfile.js
Copy path
File metadata and controls
25 lines (20 loc) · 896 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
var
gulp
=
require
(
'gulp'
)
,
concat
=
require
(
'gulp-concat'
)
,
path
=
require
(
'path'
)
,
es
=
require
(
'event-stream'
)
;
var
format
=
es
.
through
(
function
(
file
)
{
if
(
file
.
isNull
(
)
)
return
this
.
emit
(
'data'
,
file
)
;
// pass along
if
(
file
.
isStream
(
)
)
return
this
.
emit
(
'error'
,
new
Error
(
'Streaming not supported'
)
)
;
//add indentation
var
contents
=
"\t"
+
file
.
contents
.
toString
(
"utf8"
)
.
split
(
"\n"
)
.
join
(
"\n\t"
)
;
//add header
contents
=
[
"#"
,
path
.
basename
(
file
.
path
)
,
"\n"
,
contents
]
.
join
(
""
)
;
file
.
contents
=
new
Buffer
(
contents
,
"utf8"
)
;
this
.
emit
(
'data'
,
file
)
;
}
)
;
gulp
.
task
(
'examples'
,
function
(
)
{
//concat .js files from ./examples folder into ./examples.md
return
gulp
.
src
(
"./examples/*.js"
)
.
pipe
(
format
)
.
pipe
(
concat
(
'examples.md'
)
)
.
pipe
(
gulp
.
dest
(
'./'
)
)
;
}
)
;
gulp
.
task
(
'default'
,
[
"examples"
]
)
;
Back
|
FazBrowse Home
|
New Git URL