Skip to content

Commit

Permalink
Remove the web directory (concretecms#3809)
Browse files Browse the repository at this point in the history
* Remove the web directory

* Update grunt tasks after folder reorganization

* Fix tests after folder reorganization

* Keep the build folder

So that we can build the needed JS/CSS assets


Former-commit-id: 44187d3
Former-commit-id: 7427f726a4128994b3e23b02cbd2ea6cb35c28f5
  • Loading branch information
KorvinSzanto authored and aembler committed May 17, 2016
1 parent dd87db5 commit b59e5da
Show file tree
Hide file tree
Showing 4,967 changed files with 1,941 additions and 126 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
11 changes: 11 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -39,3 +39,14 @@
*.ttf binary
*.TTF binary
*.woff binary

#
# Exclude from archives created from the source code
#
/.* export-ignore
/tests/ export-ignore
/CHANGELOG.md export-ignore
/CONTRIBUTING.md export-ignore
/INSTALL.md export-ignore
/phpunit.xml export-ignore
/README.md export-ignore
170 changes: 85 additions & 85 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,26 +11,26 @@ __MACOSX
composer.phar

# ignore the config
/web/application/config/*
/application/config/*

# ignore everything but the index.html
/web/application/files/*
!/web/application/files/index.html
/application/files/*
!/application/files/index.html

/web/concrete/vendor
/concrete/vendor

# ignore updates folder
/web/updates/*
/updates/*

# ignore packages folder
/web/packages/*
/web/concrete/packages/*
/packages/*
/concrete/packages/*

# more stuff
/web/application/languages/*
/application/languages/*

# ignore sitemap.xml
/web/sitemap.xml
/sitemap.xml

# ignore the error log and .htaccess and others
error_log
Expand All @@ -47,8 +47,8 @@ error_log
/.buildpath

# ignore JavaScript source maps
/web/concrete/js/*.js.map
/web/concrete/js/bootstrap/*.js.map
/concrete/js/*.js.map
/concrete/js/bootstrap/*.js.map

# ignore node modules used for building
/build/node_modules
Expand All @@ -63,79 +63,79 @@ __IDE_SYMBOLS__.php

# Built assets
# JS
/web/concrete/js/frontend
/web/concrete/js/account.js
/web/concrete/js/app.js
/web/concrete/js/backstretch.js
/web/concrete/js/bootstrap-editable.js
/web/concrete/js/bootstrap/alert.js
/web/concrete/js/bootstrap/button.js
/web/concrete/js/bootstrap/dropdown.js
/web/concrete/js/bootstrap/popover.js
/web/concrete/js/bootstrap/tooltip.js
/web/concrete/js/bootstrap/transition.js
/web/concrete/js/conversations.js
/web/concrete/js/dashboard.js
/web/concrete/js/dropzone.js
/web/concrete/js/dynatree.js
/web/concrete/js/express.js
/web/concrete/js/events.js
/web/concrete/js/file-manager.js
/web/concrete/js/gathering.js
/web/concrete/js/groups.js
/web/concrete/js/frontend/parallax-image.js
/web/concrete/js/help.js
/web/concrete/js/backbone.js
/web/concrete/js/image-editor.js
/web/concrete/js/jquery-cookie.js
/web/concrete/js/jquery-tristate.js
/web/concrete/js/jquery-fileupload.js
/web/concrete/js/jquery-form.js
/web/concrete/js/jquery-magnific-popup.js
/web/concrete/js/kinetic.js
/web/concrete/js/layouts.js
/web/concrete/js/redactor.js
/web/concrete/js/jquery-awesome-rating.js
/web/concrete/js/sitemap.js
/web/concrete/js/tree.js
/web/concrete/js/autosize.js
/web/concrete/js/express.js
/web/concrete/js/spectrum.js
/web/concrete/js/style-customizer.js
/web/concrete/js/topics.js
/web/concrete/js/underscore.js
/web/concrete/js/lightbox.js
/web/concrete/js/select2.js
/web/concrete/js/translator.js
/web/concrete/js/textcounter.js
/web/concrete/js/tree.js
/concrete/js/frontend
/concrete/js/account.js
/concrete/js/app.js
/concrete/js/backstretch.js
/concrete/js/bootstrap-editable.js
/concrete/js/bootstrap/alert.js
/concrete/js/bootstrap/button.js
/concrete/js/bootstrap/dropdown.js
/concrete/js/bootstrap/popover.js
/concrete/js/bootstrap/tooltip.js
/concrete/js/bootstrap/transition.js
/concrete/js/conversations.js
/concrete/js/dashboard.js
/concrete/js/dropzone.js
/concrete/js/dynatree.js
/concrete/js/express.js
/concrete/js/events.js
/concrete/js/file-manager.js
/concrete/js/gathering.js
/concrete/js/groups.js
/concrete/js/frontend/parallax-image.js
/concrete/js/help.js
/concrete/js/backbone.js
/concrete/js/image-editor.js
/concrete/js/jquery-cookie.js
/concrete/js/jquery-tristate.js
/concrete/js/jquery-fileupload.js
/concrete/js/jquery-form.js
/concrete/js/jquery-magnific-popup.js
/concrete/js/kinetic.js
/concrete/js/layouts.js
/concrete/js/redactor.js
/concrete/js/jquery-awesome-rating.js
/concrete/js/sitemap.js
/concrete/js/tree.js
/concrete/js/autosize.js
/concrete/js/express.js
/concrete/js/spectrum.js
/concrete/js/style-customizer.js
/concrete/js/topics.js
/concrete/js/underscore.js
/concrete/js/lightbox.js
/concrete/js/select2.js
/concrete/js/translator.js
/concrete/js/textcounter.js
/concrete/js/tree.js

# CSS
/web/concrete/css/select2.css
/web/concrete/css/account.css
/web/concrete/css/app.css
/web/concrete/css/conversations.css
/web/concrete/css/dynatree.css
/web/concrete/css/editable-fields.css
/web/concrete/css/file-manager.css
/web/concrete/css/font-awesome.css
/web/concrete/css/frontend/pagination.css
/web/concrete/css/gathering/base.css
/web/concrete/css/gathering/display.css
/web/concrete/css/image-editor.css
/web/concrete/css/jquery-magnific-popup.css
/web/concrete/css/help.css
/web/concrete/css/jquery-awesome-rating.css
/web/concrete/css/jquery-ui.css
/web/concrete/css/dropzone.css
/web/concrete/css/redactor.css
/web/concrete/css/sitemap.css
/web/concrete/css/spectrum.css
/web/concrete/css/style-customizer.css
/web/concrete/css/topics.css
/web/concrete/css/views/install.css
/web/concrete/themes/concrete/main.css
/web/concrete/themes/dashboard/main.css
/web/concrete/themes/elemental/css/bootstrap-modified.css
/web/concrete/css/translator.css
/web/concrete/css/build/vendor/bootstrap/bootstrap.css
/concrete/css/select2.css
/concrete/css/account.css
/concrete/css/app.css
/concrete/css/conversations.css
/concrete/css/dynatree.css
/concrete/css/editable-fields.css
/concrete/css/file-manager.css
/concrete/css/font-awesome.css
/concrete/css/frontend/pagination.css
/concrete/css/gathering/base.css
/concrete/css/gathering/display.css
/concrete/css/image-editor.css
/concrete/css/jquery-magnific-popup.css
/concrete/css/help.css
/concrete/css/jquery-awesome-rating.css
/concrete/css/jquery-ui.css
/concrete/css/dropzone.css
/concrete/css/redactor.css
/concrete/css/sitemap.css
/concrete/css/spectrum.css
/concrete/css/style-customizer.css
/concrete/css/topics.css
/concrete/css/views/install.css
/concrete/themes/concrete/main.css
/concrete/themes/dashboard/main.css
/concrete/themes/elemental/css/bootstrap-modified.css
/concrete/css/translator.css
/concrete/css/build/vendor/bootstrap/bootstrap.css
4 changes: 2 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ php:

before_script:
- bash -c 'if [ "$TRAVIS_PHP_VERSION" != "hhvm" ]; then echo "short_open_tag = On" >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini; fi;'
- cd web/concrete
- cd concrete
- travis_retry composer install --no-interaction
- cd ../../tests
- cd ..
- phpunit --version

script: phpunit
Expand Down
File renamed without changes.
File renamed without changes.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ Just log in to the documentation site with your concrete5.org account and edit a
git clone https://github.com/concrete5/concrete5.git
cd concrete5/

3. Use [Composer](https://getcomposer.org/) to install the third party dependencies in `/web/concrete`
3. Use [Composer](https://getcomposer.org/) to install the third party dependencies in `/concrete`

cd web/concrete
cd concrete
composer install
cd ../../

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion build/Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ module.exports = function(grunt) {
var config = {};

config.DIR_REL = ('DIR_REL' in parameters) ? parameters.DIR_REL : '';
config.DIR_BASE = ('DIR_BASE' in parameters) ? parameters.DIR_BASE : '../web';
config.DIR_BASE = ('DIR_BASE' in parameters) ? parameters.DIR_BASE : '..';

// Options for the tool that will merge the files
var concatOptions = {
Expand Down
2 changes: 1 addition & 1 deletion build/Gruntfile.parameters-sample.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ module.exports = {
// config.DIR_REL = '/c5subfolder';
DIR_REL: '',
// The path to the web folder, relative to this Gruntfile
DIR_BASE: '../web',
DIR_BASE: '..',
// The path to the cli folder, relative to this Gruntfile
DIR_CLI: '../cli',

Expand Down
2 changes: 1 addition & 1 deletion build/libraries/generate-constants.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
if (isset($argv) && is_array($argv) && isset($argv[1])) {
define('DIR_BASE', $argv[1]);
} else {
define('DIR_BASE', dirname(dirname(dirname(__FILE__))) . DIRECTORY_SEPARATOR . 'web');
define('DIR_BASE', dirname(dirname(dirname(__FILE__))));
}
$corePath = DIR_BASE . '/concrete';
$cms = require_once $corePath . '/dispatcher.php';
Expand Down
2 changes: 1 addition & 1 deletion build/tasks/build-release/build.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ module.exports = function(grunt, config, parameters, done) {
exec(
'composer install --prefer-dist --no-dev',
{
cwd: path.join(workFolder, 'web/concrete')
cwd: path.join(workFolder, 'concrete')
},
function(error, stdout, stderr) {
if(error) {
Expand Down
2 changes: 1 addition & 1 deletion build/tasks/build-release/clean.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module.exports = function(grunt, config, parameters, done) {
var workFolder = parameters.releaseWorkFolder || './release/source/web';
var workFolder = parameters.releaseWorkFolder || './release/source';

var remove = {
file: {
Expand Down
16 changes: 10 additions & 6 deletions build/tasks/build-release/create-zip.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ module.exports = function(grunt, config, parameters, done) {
shell = require('shelljs'),
c5fs = require('../../libraries/fs');
process.stdout.write('Determining concrete5 version... ');
var str = fs.readFileSync(path.join(workFolder, 'web/concrete/config/concrete.php'), 'utf8');
var str = fs.readFileSync(path.join(workFolder, 'concrete/config/concrete.php'), 'utf8');
// Remove comments and new lines
str = str.replace(/\/\/.*?($|\r|\n)/g, '').replace(/[\r\n]/g, ' ').replace(/\/\*.*?\*\//g, '');
var version = str.match(/["']version["']\s*=>\s*['"](.*?)['"]/);
Expand All @@ -31,11 +31,15 @@ module.exports = function(grunt, config, parameters, done) {
version = version[1];
process.stdout.write(version + '\n');
var dirname = 'concrete5-' + version;
fs.renameSync(path.join(workFolder, 'web'), path.join(workFolder, dirname));
var workFolderParent = path.join(workFolder, '..');
var folderToZip = path.join(workFolderParent, dirname);
fs.renameSync(workFolder, folderToZip);
fs.renameSync(path.join(folderToZip, 'build'), path.join(workFolderParent, 'build-source'));
revert = function() {
fs.renameSync(path.join(workFolder, dirname), path.join(workFolder, 'web'));
fs.renameSync(path.join(workFolderParent, 'build-source'), path.join(folderToZip, 'build'));
fs.renameSync(folderToZip, workFolder);
}
shell.pushd(workFolder);
shell.pushd(workFolderParent);
process.stdout.write('Creating zip file... ');
shell.exec(
'zip -r ' + c5fs.escapeShellArg(dirname + '.zip') + ' ' + c5fs.escapeShellArg(dirname),
Expand All @@ -50,7 +54,7 @@ module.exports = function(grunt, config, parameters, done) {
return;
}
process.stdout.write('done.\n');
fs.renameSync(path.join(workFolder, dirname + '.zip'), './' + dirname + '.zip');
fs.renameSync(path.join(workFolderParent, dirname + '.zip'), './' + dirname + '.zip');
revert();
done();
}
Expand All @@ -60,4 +64,4 @@ module.exports = function(grunt, config, parameters, done) {
endForError(e);
return;
}
};
};
2 changes: 1 addition & 1 deletion build/tasks/build-release/remove-short-tags.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module.exports = function(grunt, config, parameters, done) {
var workFolder = parameters.releaseWorkFolder || './release/source/web';
var workFolder = parameters.releaseWorkFolder || './release/source';
function endForError(e) {
process.stderr.write(e.message || e);
done(false);
Expand Down
2 changes: 1 addition & 1 deletion build/tasks/build-release/translations.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module.exports = function(grunt, config, parameters, done) {
var workFolder = parameters.releaseWorkFolder || './release/source/web';
var workFolder = parameters.releaseWorkFolder || './release/source';

function endForError(e) {
process.stderr.write(e.message || e);
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
Loading

0 comments on commit b59e5da

Please sign in to comment.