在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
开源软件名称(OpenSource Name):tugberkugurlu/gulp-dnx开源软件地址(OpenSource Url):https://github.com/tugberkugurlu/gulp-dnx开源编程语言(OpenSource Language):JavaScript 92.5%开源软件介绍(OpenSource Introduction):gulp-dnxGulp plugin for ASP.NET 5. You can use this plugin to integrate ASP.NET 5 InstallationYou can install gulp-dnx plugin through npm:
Preferably, you can save this as dev dependency:
Usagevar gulp = require('gulp'),
dnx = require("gulp-dnx");
gulp.task('default', function(cb) {
return gulp.start('dnx-run');
});
gulp.task('dnx-run', dnx('kestrel')); The default function restores the packages according to your project.json file and runs the web command inside the project.json file. You can pass a few options to this to choose what's actually going to run: // the default options
var options = {
restore: true,
build: false,
run: true,
cwd: './'
};
var dnxCommand = 'web';
gulp.task('dnx-run', dnx(dnxCommand, options)); There are also shorthand methods for specific tasks: //runs the project.json's command 'kestrel'
gulp.task('dnx-run', dnx('kestrel'));
// only restores the packages
gulp.task('dnu-restore', dnx.restore());
// only builds the project
gulp.task('dnu-build', dnx.build());
// restores the packages and builds the project
gulp.task('dnu-restore-build', dnx.restoreBuild()); gulp-dnx also integrates with cwdYou can change the working directory for the specific command to run passing //assuming project.json is inside the 'server' directory
var options = {
cwd: './server/'
};
gulp.task('dnx-run', dnx('web', options));
//using the shorthand methods
gulp.task('dnx-restore', dnx.restore('./server/'));
gulp.task('dnu-build', dnx.build('./server/'));
gulp.task('dnu-restore-build', dnx.restoreBuild('./server/')); |
2023-10-27
2022-08-15
2022-08-17
2022-09-23
2022-08-13
请发表评论