Skip to content
This repository was archived by the owner on Dec 4, 2017. It is now read-only.

Commit 1e908ff

Browse files
chalinwardbell
authored andcommitted
docs(cheatsheet/dart): temporarily use TS cheatsheet data
closes #1902
1 parent daca93c commit 1e908ff

File tree

1 file changed

+7
-11
lines changed

1 file changed

+7
-11
lines changed

gulpfile.js

+7-11
Original file line numberDiff line numberDiff line change
@@ -545,9 +545,9 @@ gulp.task('build-docs', ['build-devguide-docs', 'build-api-docs', 'build-plunker
545545
// Stop zipping examples Feb 28, 2016
546546
//gulp.task('build-docs', ['build-devguide-docs', 'build-api-docs', 'build-plunkers', '_zip-examples']);
547547

548-
gulp.task('build-api-docs', ['build-js-api-docs', 'build-ts-api-docs',
548+
gulp.task('build-api-docs', ['build-js-api-docs', 'build-ts-api-docs', 'build-dart-cheatsheet']
549549
// On TRAVIS? Skip building the Dart API docs for now.
550-
...(process.env.TRAVIS ? [] : ['build-dart-api-docs'])]);
550+
.concat(process.env.TRAVIS ? [] : ['build-dart-api-docs']));
551551

552552
gulp.task('build-devguide-docs', ['_shred-devguide-examples', '_shred-devguide-shared-jade'], function() {
553553
return buildShredMaps(true);
@@ -570,9 +570,11 @@ gulp.task('build-plunkers', ['_copy-example-boilerplate'], function() {
570570
return plunkerBuilder.buildPlunkers(EXAMPLES_PATH, LIVE_EXAMPLES_PATH, { errFn: gutil.log });
571571
});
572572

573-
gulp.task('build-dart-cheatsheet', [], function() {
574-
gutil.log('build-dart-cheatsheet - NOT IMPLEMENTED YET');
575-
// return buildApiDocsForDart();
573+
gulp.task('build-dart-cheatsheet', ['build-ts-api-docs'], function() {
574+
gutil.log('build-dart-cheatsheet - NOT IMPLEMENTED YET - copying TS cheatsheet data');
575+
const src = './public/docs/ts/latest/guide/cheatsheet.json';
576+
fs.copy(src, './public/docs/dart/latest/guide/cheatsheet.json', {clobber: true},
577+
(err) => { if(err) throw err });
576578
});
577579

578580
gulp.task('dartdoc', ['pub upgrade'], function() {
@@ -1170,12 +1172,6 @@ function buildApiDocs(targetLanguage) {
11701172
console.error(err.stack);
11711173
throw err;
11721174
}
1173-
1174-
function copyApiDocsToJsFolder() {
1175-
// Make a copy of the JS API docs to the TS folder
1176-
return gulp.src([path.join(DOCS_PATH, 'ts/latest/api/**/*.*'), '!' + path.join(DOCS_PATH, 'ts/latest/api/index.jade')])
1177-
.pipe(gulp.dest('./public/docs/js/latest/api'));
1178-
}
11791175
}
11801176

11811177

0 commit comments

Comments
 (0)