Skip to content

Instantly share code, notes, and snippets.

@Gernene
Created June 12, 2019 16:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Gernene/6872fcbabdd6e7fb330a8f6f66bda00b to your computer and use it in GitHub Desktop.
Save Gernene/6872fcbabdd6e7fb330a8f6f66bda00b to your computer and use it in GitHub Desktop.
"MS Teams: Automating Manifest Generation" code snipppet
const gulp = require('gulp');
const zip = require('gulp-zip');
const del = require('del');
gulp.task('clean', function(done) {
return del([
'manifest/**/*'
], done);
});
gulp.task('generate-manifest', function(done) {
gulp.src(['src/static/images/logo*', 'manifest.json']) // Get relevant images from specified folder, change as needed
.pipe(zip('yourapp.zip'))
.pipe(gulp.dest('manifest'), done);
done();
});
gulp.task('default', gulp.series('clean', 'generate-manifest'), function(done) {
console.log('Build completed. Output in manifest folder');
done();
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment