1
0
mirror of https://github.com/moparisthebest/mail synced 2024-08-13 16:43:47 -04:00

Merge pull request #28 from whiteout-io/node-webkit

Node webkit
This commit is contained in:
Tankred Hase 2014-03-03 12:16:44 +01:00
commit 441ec3e4ca
7 changed files with 50 additions and 9 deletions

2
.gitignore vendored
View File

@ -5,7 +5,7 @@ test/lib/
.sass-cache
src/css/
dist/
*.zip
release/
test/integration/src/
src/lib/*.js
src/js/crypto/aes-cbc.js

View File

@ -29,6 +29,7 @@
"deepEqual",
"start",
"chrome",
"requirejs",
"define",
"self",
"describe",

View File

@ -209,18 +209,31 @@ module.exports = function(grunt) {
dest: 'test/integration/src/'
}
},
compress: {
main: {
chrome: {
options: {
mode: 'zip',
archive: zipName + '.zip'
archive: 'release/whiteout_mail_' + zipName + '.zip'
},
expand: true,
cwd: 'dist/',
src: ['**/*'],
dest: 'release/'
}
}
},
nodewebkit: {
options: {
version: '0.9.2', // node-webkit version
build_dir: './release', // Where the build version of my node-webkit app is saved
mac: true, // We want to build it for mac
win: false, // We want to build it for win
linux32: false, // We don't need linux32
linux64: false, // We don't need linux64
},
src: ['./dist/**/*'] // Your node-webkit app
},
});
// Load the plugin(s)
@ -235,6 +248,7 @@ module.exports = function(grunt) {
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.loadNpmTasks('grunt-contrib-copy');
grunt.loadNpmTasks('grunt-contrib-compress');
grunt.loadNpmTasks('grunt-node-webkit-builder');
// Build tasks
grunt.registerTask('dist-npm', ['copy:npm', 'copy:npmDev', 'copy:cryptoLib']);

View File

@ -33,6 +33,7 @@
"grunt-autoprefixer": "~0.3.0",
"grunt-contrib-watch": "~0.5.3",
"grunt-contrib-copy": "~0.4.1",
"grunt-contrib-compress": "~0.5.2"
"grunt-contrib-compress": "~0.5.2",
"grunt-node-webkit-builder": "~0.1.17"
}
}
}

View File

@ -1,7 +1,7 @@
// hey Angular, we're bootstrapping manually!
window.name = 'NG_DEFER_BOOTSTRAP!';
require([
requirejs([
'angular',
'js/controller/dialog',
'js/controller/popover',
@ -18,7 +18,21 @@ require([
'cryptoLib/util',
'angularRoute',
'angularTouch'
], function(angular, DialogCtrl, PopoverCtrl, AddAccountCtrl, AccountCtrl, LoginCtrl, LoginInitialCtrl, LoginNewDeviceCtrl, LoginExistingCtrl, MailListCtrl, ReadCtrl, WriteCtrl, NavigationCtrl, util) {
], function(
angular,
DialogCtrl,
PopoverCtrl,
AddAccountCtrl,
AccountCtrl,
LoginCtrl,
LoginInitialCtrl,
LoginNewDeviceCtrl,
LoginExistingCtrl,
MailListCtrl,
ReadCtrl,
WriteCtrl,
NavigationCtrl,
util) {
'use strict';
// reset window.name

10
src/package.json Normal file
View File

@ -0,0 +1,10 @@
{
"name": "Whiteout Mail",
"version": "0.0.1",
"main": "chrome.html",
"window": {
"toolbar": false,
"width": 1024,
"height": 768
}
}

View File

@ -1,7 +1,8 @@
(function() {
'use strict';
require.config({
requirejs.config({
nodeRequire: (typeof module !== 'undefined' && module.exports) ? require : undefined,
baseUrl: 'lib',
paths: {
js: '../js',