File tree Expand file tree Collapse file tree 5 files changed +100
-0
lines changed
Expand file tree Collapse file tree 5 files changed +100
-0
lines changed Original file line number Diff line number Diff line change @@ -307,3 +307,7 @@ __pycache__/
307307
308308# Compiled Docs
309309docs_compiled /
310+
311+ # Package lock
312+ package-lock.json
313+
Original file line number Diff line number Diff line change 6868 <None Include =" App.config" >
6969 <SubType >Designer</SubType >
7070 </None >
71+ <None Include =" package.json" />
7172 <None Include =" packages.config" />
7273 <None Include =" Properties\Settings.settings" >
7374 <Generator >SettingsSingleFileGenerator</Generator >
8081 <Name >Encryption</Name >
8182 </ProjectReference >
8283 </ItemGroup >
84+ <ItemGroup >
85+ <Content Include =" gulpfile.js" />
86+ <Content Include =" project.config.js" />
87+ </ItemGroup >
8388 <Import Project =" $(MSBuildToolsPath)\Microsoft.CSharp.targets" />
89+ <PropertyGroup >
90+ <PostBuildEvent >gulp post-build-$(ConfigurationName)</PostBuildEvent >
91+ </PropertyGroup >
92+ <PropertyGroup >
93+ <PreBuildEvent >gulp pre-build-$(ConfigurationName)</PreBuildEvent >
94+ </PropertyGroup >
8495</Project >
Original file line number Diff line number Diff line change 1+ /// <binding Clean='clean-bin' />
2+
3+ /*
4+ Configuration
5+ Load the project configuration file.
6+ */
7+ var CONFIG = require ( './project.config' ) ;
8+
9+ /*
10+ Paths
11+ Create all the paths we need ahead of time.
12+ */
13+ var binDir = 'bin/Release/' ,
14+ compiledModulesDir = '../../CompiledModules/' ;
15+
16+ /*
17+ Modules
18+ Require the modules we need.
19+ */
20+ var gulp = require ( 'gulp' ) ,
21+ clean = require ( 'gulp-clean' ) ,
22+ zip = require ( 'gulp-zip' ) ;
23+
24+ /*
25+ Visual Studio Integration
26+ These tasks are to provide integration with Visual Studio through pre and
27+ post build events.
28+ */
29+ gulp . task ( 'pre-build-Release' , [
30+ 'clean-bin'
31+ ] ) ;
32+ gulp . task ( 'post-build-Release' , [
33+ 'build-release'
34+ ] ) ;
35+
36+ /*
37+ Clean Bin
38+ You can't rely on Visual Studio to clean the bin folder, even when calling
39+ for the project to be cleaned. This task cleans the bin.
40+ Doesn't bother reading the directory as that slows the task down.
41+ */
42+ gulp . task ( 'clean-bin' ,
43+ function ( ) {
44+ return gulp . src (
45+ `${ binDir } *` ,
46+ {
47+ read : false
48+ } )
49+ . pipe ( clean ( ) ) ;
50+ }
51+ ) ;
52+
53+ /*
54+ Build Release
55+ Create a release zip.
56+ */
57+ gulp . task ( 'build-release' ,
58+ function ( ) {
59+ return gulp . src (
60+ [
61+ `${ binDir } **`
62+ ] )
63+
64+ // Zip in to install zip.
65+ . pipe ( zip ( `DeployClient_${ CONFIG . MODULE_VERSION } .zip` ) )
66+
67+ // Move to compiled modules folder.
68+ . pipe ( gulp . dest ( compiledModulesDir ) ) ;
69+ }
70+ ) ;
Original file line number Diff line number Diff line change 1+ {
2+ "name" : " deploy-client" ,
3+ "version" : " 0.7.0" ,
4+ "main" : " gulpfile.js" ,
5+ "license" : " Apache-2.0" ,
6+ "private" : true ,
7+ "devDependencies" : {
8+ "gulp" : " ^3.9.1" ,
9+ "gulp-clean" : " ^0.4.0" ,
10+ "gulp-zip" : " ^4.2.0"
11+ }
12+ }
Original file line number Diff line number Diff line change 1+ module . exports = {
2+ MODULE_VERSION : '00.07.00'
3+ } ;
You can’t perform that action at this time.
0 commit comments