Skip to content
This repository was archived by the owner on Nov 4, 2024. It is now read-only.

Commit 33a9234

Browse files
committed
1.11.2
1 parent 350e065 commit 33a9234

5 files changed

+55
-6765
lines changed

.gitignore

+2
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@
1818
/build/local
1919
/build/dist
2020
/build/tmp
21+
/build/docker
22+
/dist
2123
/data
2224
.DS_Store
2325
/tests/fix.php

docker-compose.yml

+24
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
version: '2'
2+
services:
3+
node:
4+
image: node:8.4-alpine
5+
working_dir: /usr/app
6+
command: sh -c 'yarn install && yarn global add [email protected] && gulp all:docker'
7+
volumes:
8+
- ./dev:/usr/app/dev
9+
- ./rainloop:/usr/app/rainloop
10+
- ./assets:/usr/app/assets
11+
- ./vendors:/usr/app/vendors
12+
- ./build/owncloud:/usr/app/build/owncloud
13+
- ./dist:/usr/app/dist
14+
15+
- ./.eslintrc.js:/usr/app/.eslintrc.js
16+
- ./gulpfile.js:/usr/app/gulpfile.js
17+
- ./index.php:/usr/app/index.php
18+
- ./package.json:/usr/app/package.json
19+
- ./webpack.config.builder.js:/usr/app/webpack.config.builder.js
20+
- ./webpack.config.js:/usr/app/webpack.config.js
21+
- ./yarn.lock:/usr/app/yarn.lock
22+
23+
- ./build/docker/node_modules:/usr/app/node_modules
24+
- ./build/docker/tmp:/tmp

gulpfile.js

+26-35
Original file line numberDiff line numberDiff line change
@@ -130,37 +130,6 @@ function copyFile(sFile, sNewFile, callback)
130130
callback();
131131
}
132132

133-
function signFile(sFile, callback)
134-
{
135-
var exec = require('child_process').exec;
136-
exec('gpg2 --openpgp -u 87DA4591 -a -b ' + sFile, function(err) {
137-
if (err) {
138-
gutil.log('gpg error: skip');
139-
}
140-
callback();
141-
});
142-
}
143-
144-
function signFileTask(callback) {
145-
if (argv.sign)
146-
{
147-
signFile(cfg.destPath + cfg.zipFile, function() {
148-
if (cfg.zipFileShort)
149-
{
150-
signFile(cfg.destPath + cfg.zipFileShort, callback);
151-
}
152-
else
153-
{
154-
callback();
155-
}
156-
});
157-
}
158-
else
159-
{
160-
callback();
161-
}
162-
};
163-
164133
cfg.paths.globjs = 'dev/**/*.js';
165134
cfg.paths.static = 'rainloop/v/' + cfg.devVersion + '/static/';
166135
cfg.paths.staticJS = 'rainloop/v/' + cfg.devVersion + '/static/js/';
@@ -521,7 +490,13 @@ gulp.task('rainloop:shortname', ['rainloop:zip'], function(callback) {
521490
copyFile(cfg.destPath + cfg.zipFile, cfg.destPath + cfg.zipFileShort, callback);
522491
});
523492

524-
gulp.task('rainloop:sign', ['rainloop:shortname'], signFileTask);
493+
gulp.task('rainloop:copy-dist', ['rainloop:shortname'], function(callback) {
494+
var newPath = cfg.destPath.replace('build/dist/releases', 'dist/releases');
495+
fs.mkdirSync(newPath, '0777', true);
496+
copyFile(cfg.destPath + cfg.zipFile, newPath + cfg.zipFile, function() {
497+
copyFile(cfg.destPath + cfg.zipFileShort, newPath + cfg.zipFileShort, callback);
498+
});
499+
});
525500

526501
// build (OwnCloud)
527502
gulp.task('rainloop:owncloud:copy', function() {
@@ -594,7 +569,13 @@ gulp.task('rainloop:owncloud:shortname', ['rainloop:owncloud:zip'], function(cal
594569
copyFile(cfg.destPath + cfg.zipFile, cfg.destPath + cfg.zipFileShort, callback);
595570
});
596571

597-
gulp.task('rainloop:owncloud:sign', ['rainloop:owncloud:shortname'], signFileTask);
572+
gulp.task('rainloop:owncloud:copy-dist', ['rainloop:owncloud:shortname'], function(callback) {
573+
var newPath = cfg.destPath.replace('build/dist/releases', 'dist/releases');
574+
fs.mkdirSync(newPath, '0777', true);
575+
copyFile(cfg.destPath + cfg.zipFile, newPath + cfg.zipFile, function() {
576+
copyFile(cfg.destPath + cfg.zipFileShort, newPath + cfg.zipFileShort, callback);
577+
});
578+
});
598579

599580
// main
600581
gulp.task('moment', ['moment:locales']);
@@ -607,11 +588,13 @@ gulp.task('clean', ['js:clean', 'css:clean', 'assets:clean']);
607588

608589
gulp.task('rainloop:start', ['rainloop:copy', 'rainloop:setup']);
609590

610-
gulp.task('rainloop', ['rainloop:start', 'rainloop:zip', 'rainloop:clean', 'rainloop:shortname', 'rainloop:sign']);
591+
gulp.task('rainloop', ['rainloop:start', 'rainloop:zip', 'rainloop:clean', 'rainloop:shortname']);
592+
gulp.task('rainloop:docker', ['rainloop', 'rainloop:copy-dist']);
611593

612594
gulp.task('owncloud', ['rainloop:owncloud:copy',
613595
'rainloop:owncloud:copy-rainloop', 'rainloop:owncloud:copy-rainloop:clean',
614-
'rainloop:owncloud:setup', 'rainloop:owncloud:zip', 'rainloop:owncloud:clean', 'rainloop:owncloud:shortname', 'rainloop:owncloud:sign']);
596+
'rainloop:owncloud:setup', 'rainloop:owncloud:zip', 'rainloop:owncloud:clean', 'rainloop:owncloud:shortname']);
597+
gulp.task('owncloud:docker', ['owncloud', 'rainloop:owncloud:copy-dist']);
615598

616599
// default
617600
gulp.task('default', function(callback) {
@@ -629,6 +612,14 @@ gulp.task('watch', ['css:main', 'js:validate'], function() {
629612
// aliases
630613
gulp.task('build', ['rainloop']);
631614

615+
gulp.task('all', function(callback) {
616+
runSequence('rainloop', 'owncloud', callback);
617+
});
618+
619+
gulp.task('all:docker', function(callback) {
620+
runSequence('rainloop:docker', 'owncloud:docker', callback);
621+
});
622+
632623
gulp.task('d', ['default']);
633624
gulp.task('w', ['watch']);
634625
gulp.task('l', ['js:libs']);

0 commit comments

Comments
 (0)