Skip to content

Commit a605712

Browse files
committedJul 14, 2016
Merge branch 'develop'
Conflicts: dist/fenix-ui-map.min.css dist/fenix-ui-map.min.js dist/fenix-ui-map.src.js
2 parents a8e69fa + f3e5921 commit a605712

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

60 files changed

+9088
-3048
lines changed
 

‎.gitignore

+3
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,6 @@
22
node_modules/*
33
npm-debug.log
44
*.iml
5+
.ftppass
6+
sftpCache.json
7+
*.DS_Store

‎Gruntfile.js

+30-5
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,14 @@ grunt.loadNpmTasks('grunt-contrib-jshint');
1010
grunt.loadNpmTasks('grunt-contrib-copy');
1111
grunt.loadNpmTasks('grunt-jsonlint');
1212
grunt.loadNpmTasks('grunt-contrib-watch');
13+
grunt.loadNpmTasks('grunt-sftp-deploy');
1314

1415
grunt.initConfig({
1516
pkg: grunt.file.readJSON('package.json'),
1617
meta: {
1718
banner:
1819
'/* \n'+
19-
' * <%= pkg.name %> v<%= pkg.version %> - <%= grunt.template.today("yyyy-mm-dd") %> \n'+
20+
' * <%= pkg.name %> v<%= pkg.version %> \n'+
2021
' * Copyright <%= grunt.template.today("yyyy") %> <%= pkg.author.name %> \n'+
2122
' * <%= pkg.author %> \n'+
2223
' * \n'+
@@ -30,6 +31,9 @@ grunt.initConfig({
3031
js: {
3132
src: ['dist/*.js']
3233
},
34+
css: {
35+
src: ['dist/*.css']
36+
},
3337
images: {
3438
src: ['dist/images/*']
3539
}
@@ -94,7 +98,7 @@ grunt.initConfig({
9498
'src/map/config/*.js',
9599
'src/map/Map.js',
96100
'src/map/utils/LayerLegend.js',
97-
'src/map/controller/MapControllerDraggable.js',
101+
'src/map/MapController.js',
98102
'src/map/html/gui-controller.js',
99103
'src/map/html/gui-map.js',
100104
'src/map/utils/*.js ',
@@ -130,12 +134,29 @@ grunt.initConfig({
130134
src: '<%= cssmin.combine.dest %>'
131135
}
132136
},
137+
'sftp-deploy': {
138+
build: {
139+
auth: {
140+
host: 'fenixrepo.fao.org',
141+
port: 22,
142+
authKey: {
143+
username: 'root'
144+
}
145+
},
146+
cache: 'sftpCache.json',
147+
src: 'dist',
148+
dest: '/work/prod/nginx/www/cdn/fenix/<%= pkg.name %>/<%= pkg.version %>',
149+
serverSep: '/',
150+
concurrency: 4,
151+
progress: true
152+
}
153+
},
133154
watch: {
134155
dist: {
135156
options: { livereload: true },
136157
files: ['src/**/*','Gruntfile.js'],
137-
tasks: ['clean:js','copy:fenixmapconfig','concat','cssmin','jshint']
138-
}
158+
tasks: ['clean:js','clean:css','copy:fenixmapconfig','concat','cssmin','jshint']
159+
}
139160
}
140161
});
141162

@@ -149,4 +170,8 @@ grunt.registerTask('default', [
149170
'copy'
150171
]);
151172

152-
};
173+
grunt.registerTask('deploy', [
174+
'sftp-deploy',
175+
]);
176+
177+
};

0 commit comments

Comments
 (0)
Please sign in to comment.