You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by ry...@apache.org on 2013/05/11 07:49:04 UTC
[51/51] [partial] git commit: updated
refs/heads/fauxton-simpler-build to 4615a78
Restructure to simpler jam/erica style.
- compile less files, templates into compiled requirejs
- Add simple rebuild command, to control minification,
- Add simple push command, to eash couchapp push.
Slight readme improvement
Project: http://git-wip-us.apache.org/repos/asf/couchdb/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb/commit/4615a788
Tree: http://git-wip-us.apache.org/repos/asf/couchdb/tree/4615a788
Diff: http://git-wip-us.apache.org/repos/asf/couchdb/diff/4615a788
Branch: refs/heads/fauxton-simpler-build
Commit: 4615a788dcc1ab00d0f63b43530aa6921654c538
Parents: 6510766
Author: Ryan Ramage <ry...@gmail.com>
Authored: Fri May 10 09:10:02 2013 -0600
Committer: Ryan Ramage <ry...@gmail.com>
Committed: Fri May 10 23:41:32 2013 -0600
----------------------------------------------------------------------
src/fauxton/Gruntfile.js | 356 -
src/fauxton/_ddoc/rewrites.json | 10 +
src/fauxton/_ddoc/validate_doc_update.js | 39 +
src/fauxton/app/addons/config/base.js | 28 -
src/fauxton/app/addons/config/resources.js | 175 -
src/fauxton/app/addons/config/routes.js | 44 -
.../app/addons/config/templates/dashboard.html | 52 -
src/fauxton/app/addons/config/templates/item.html | 31 -
src/fauxton/app/addons/contribute/base.js | 33 -
src/fauxton/app/addons/logs/base.js | 28 -
src/fauxton/app/addons/logs/resources.js | 225 -
src/fauxton/app/addons/logs/routes.js | 47 -
.../app/addons/logs/templates/dashboard.html | 46 -
.../app/addons/logs/templates/filterItem.html | 16 -
src/fauxton/app/addons/logs/templates/sidebar.html | 27 -
.../app/addons/stats/assets/less/stats.less | 20 -
src/fauxton/app/addons/stats/base.js | 28 -
src/fauxton/app/addons/stats/resources.js | 37 -
src/fauxton/app/addons/stats/routes.js | 59 -
.../app/addons/stats/templates/by_method.html | 16 -
.../app/addons/stats/templates/pie_table.html | 56 -
src/fauxton/app/addons/stats/templates/stats.html | 16 -
.../app/addons/stats/templates/statselect.html | 22 -
src/fauxton/app/addons/stats/views.js | 172 -
src/fauxton/app/api.js | 101 -
src/fauxton/app/app.js | 75 -
src/fauxton/app/config.js | 53 -
src/fauxton/app/helpers.js | 35 -
src/fauxton/app/initialize.js | 62 -
src/fauxton/app/load_addons.js.underscore | 27 -
src/fauxton/app/main.js | 38 -
src/fauxton/app/modules/databases/base.js | 36 -
src/fauxton/app/modules/databases/resources.js | 148 -
src/fauxton/app/modules/databases/routes.js | 70 -
src/fauxton/app/modules/databases/views.js | 186 -
src/fauxton/app/modules/documents/base.js | 24 -
src/fauxton/app/modules/documents/resources.js | 261 -
src/fauxton/app/modules/documents/routes.js | 426 -
src/fauxton/app/modules/documents/views.js | 950 --
src/fauxton/app/modules/fauxton/base.js | 155 -
src/fauxton/app/modules/fauxton/layout.js | 96 -
src/fauxton/app/modules/pouchdb/base.js | 57 -
src/fauxton/app/modules/pouchdb/pouch.collate.js | 115 -
.../app/modules/pouchdb/pouchdb.mapreduce.js | 286 -
src/fauxton/app/router.js | 164 -
src/fauxton/app/templates/databases/item.html | 20 -
src/fauxton/app/templates/databases/list.html | 30 -
src/fauxton/app/templates/databases/sidebar.html | 31 -
.../app/templates/documents/all_docs_item.html | 26 -
.../app/templates/documents/all_docs_list.html | 141 -
src/fauxton/app/templates/documents/changes.html | 36 -
src/fauxton/app/templates/documents/doc.html | 24 -
.../app/templates/documents/doc_field_editor.html | 60 -
.../templates/documents/doc_field_editor_tabs.html | 26 -
.../app/templates/documents/index_menu_item.html | 17 -
.../app/templates/documents/index_row_docular.html | 26 -
.../app/templates/documents/index_row_tabular.html | 25 -
src/fauxton/app/templates/documents/search.html | 15 -
src/fauxton/app/templates/documents/sidebar.html | 29 -
src/fauxton/app/templates/documents/tabs.html | 39 -
.../app/templates/documents/view_editor.html | 92 -
src/fauxton/app/templates/fauxton/api_bar.html | 30 -
src/fauxton/app/templates/fauxton/breadcrumbs.html | 24 -
src/fauxton/app/templates/fauxton/footer.html | 15 -
src/fauxton/app/templates/fauxton/nav_bar.html | 49 -
.../app/templates/fauxton/notification.html | 18 -
src/fauxton/app/templates/fauxton/pagination.html | 31 -
src/fauxton/app/templates/layouts/one_pane.html | 28 -
src/fauxton/app/templates/layouts/two_pane.html | 29 -
.../app/templates/layouts/with_right_sidebar.html | 27 -
.../app/templates/layouts/with_sidebar.html | 27 -
src/fauxton/app/templates/layouts/with_tabs.html | 27 -
.../app/templates/layouts/with_tabs_sidebar.html | 28 -
src/fauxton/assets/css/codemirror.css | 169 -
src/fauxton/assets/css/nv.d3.css | 656 -
src/fauxton/assets/img/couchdblogo.png | Bin 2738 -> 0 bytes
.../assets/img/glyphicons-halflings-white.png | Bin 8777 -> 0 bytes
src/fauxton/assets/img/glyphicons-halflings.png | Bin 13826 -> 0 bytes
src/fauxton/assets/index.underscore | 53 -
src/fauxton/assets/js/libs/almond.js | 314 -
src/fauxton/assets/js/libs/backbone.js | 1571 --
src/fauxton/assets/js/libs/bootstrap.js | 2025 ---
src/fauxton/assets/js/libs/codemirror.js | 3231 ----
src/fauxton/assets/js/libs/d3.js | 7026 ---------
src/fauxton/assets/js/libs/jquery.js | 9404 ------------
src/fauxton/assets/js/libs/jshint.js | 4529 ------
src/fauxton/assets/js/libs/lodash.js | 4355 ------
src/fauxton/assets/js/libs/nv.d3.js |11286 --------------
src/fauxton/assets/js/libs/require.js | 2037 ---
.../assets/js/plugins/backbone.layoutmanager.js | 875 --
.../assets/js/plugins/codemirror-javascript.js | 361 -
src/fauxton/assets/js/plugins/prettify.js | 28 -
src/fauxton/assets/less/bootstrap/accordion.less | 34 -
src/fauxton/assets/less/bootstrap/alerts.less | 65 -
src/fauxton/assets/less/bootstrap/bootstrap.less | 63 -
src/fauxton/assets/less/bootstrap/breadcrumbs.less | 24 -
.../assets/less/bootstrap/button-groups.less | 242 -
src/fauxton/assets/less/bootstrap/buttons.less | 232 -
src/fauxton/assets/less/bootstrap/carousel.less | 131 -
src/fauxton/assets/less/bootstrap/close.less | 31 -
src/fauxton/assets/less/bootstrap/code.less | 58 -
.../less/bootstrap/component-animations.less | 22 -
src/fauxton/assets/less/bootstrap/dropdowns.less | 237 -
src/fauxton/assets/less/bootstrap/forms.less | 683 -
src/fauxton/assets/less/bootstrap/grid.less | 21 -
src/fauxton/assets/less/bootstrap/hero-unit.less | 25 -
.../assets/less/bootstrap/labels-badges.less | 74 -
src/fauxton/assets/less/bootstrap/layouts.less | 16 -
src/fauxton/assets/less/bootstrap/media.less | 55 -
src/fauxton/assets/less/bootstrap/mixins.less | 686 -
src/fauxton/assets/less/bootstrap/modals.less | 94 -
src/fauxton/assets/less/bootstrap/navbar.less | 475 -
src/fauxton/assets/less/bootstrap/navs.less | 385 -
src/fauxton/assets/less/bootstrap/pager.less | 41 -
src/fauxton/assets/less/bootstrap/pagination.less | 121 -
src/fauxton/assets/less/bootstrap/popovers.less | 117 -
.../assets/less/bootstrap/progress-bars.less | 122 -
src/fauxton/assets/less/bootstrap/reset.less | 138 -
.../less/bootstrap/responsive-1200px-min.less | 28 -
.../less/bootstrap/responsive-767px-max.less | 193 -
.../less/bootstrap/responsive-768px-979px.less | 19 -
.../assets/less/bootstrap/responsive-navbar.less | 185 -
.../less/bootstrap/responsive-utilities.less | 43 -
src/fauxton/assets/less/bootstrap/responsive.less | 48 -
src/fauxton/assets/less/bootstrap/scaffolding.less | 52 -
src/fauxton/assets/less/bootstrap/sprites.less | 193 -
src/fauxton/assets/less/bootstrap/tables.less | 236 -
.../assets/less/bootstrap/tests/buttons.html | 139 -
.../assets/less/bootstrap/tests/css-tests.css | 139 -
.../assets/less/bootstrap/tests/css-tests.html | 1296 --
.../less/bootstrap/tests/forms-responsive.html | 71 -
src/fauxton/assets/less/bootstrap/tests/forms.html | 179 -
.../less/bootstrap/tests/navbar-fixed-top.html | 104 -
.../less/bootstrap/tests/navbar-static-top.html | 107 -
.../assets/less/bootstrap/tests/navbar.html | 107 -
src/fauxton/assets/less/bootstrap/thumbnails.less | 52 -
src/fauxton/assets/less/bootstrap/tooltip.less | 70 -
src/fauxton/assets/less/bootstrap/type.less | 227 -
src/fauxton/assets/less/bootstrap/utilities.less | 30 -
src/fauxton/assets/less/bootstrap/variables.less | 301 -
src/fauxton/assets/less/bootstrap/wells.less | 29 -
src/fauxton/assets/less/config.less | 46 -
src/fauxton/assets/less/couchdb.less | 72 -
src/fauxton/assets/less/database.less | 163 -
src/fauxton/assets/less/fauxton.less | 95 -
src/fauxton/assets/less/logs.less | 24 -
src/fauxton/assets/less/prettyprint.less | 38 -
src/fauxton/bin/grunt | 18 -
src/fauxton/couchapp.js | 27 -
src/fauxton/css/codemirror.css | 169 +
src/fauxton/css/config.less | 46 +
src/fauxton/css/couchdb.less | 72 +
src/fauxton/css/database.less | 163 +
src/fauxton/css/fauxton.less | 95 +
src/fauxton/css/logs.less | 24 +
src/fauxton/css/main.less | 2 +
src/fauxton/css/nv.d3.css | 656 +
src/fauxton/css/prettyprint.less | 38 +
src/fauxton/img/couchdblogo.png | Bin 0 -> 2738 bytes
src/fauxton/img/glyphicons-halflings-white.png | Bin 0 -> 8777 bytes
src/fauxton/img/glyphicons-halflings.png | Bin 0 -> 13826 bytes
src/fauxton/index.html | 21 +-
.../backbone.layoutmanager.js | 961 ++
.../jam/backbone.layoutmanager/package.json | 43 +
src/fauxton/jam/backbone/backbone.js | 1573 ++
src/fauxton/jam/backbone/package.json | 28 +
src/fauxton/jam/bootstrap/CONTRIBUTING.md | 75 +
src/fauxton/jam/bootstrap/LICENSE | 176 +
src/fauxton/jam/bootstrap/README.md | 112 +
src/fauxton/jam/bootstrap/component.json | 8 +
src/fauxton/jam/bootstrap/composer.json | 10 +
.../docs/assets/css/bootstrap-responsive.css | 1092 ++
.../jam/bootstrap/docs/assets/css/bootstrap.css | 6039 ++++++++
src/fauxton/jam/bootstrap/docs/assets/css/docs.css | 1064 ++
.../ico/apple-touch-icon-114-precomposed.png | Bin 0 -> 11392 bytes
.../ico/apple-touch-icon-144-precomposed.png | Bin 0 -> 16780 bytes
.../assets/ico/apple-touch-icon-57-precomposed.png | Bin 0 -> 4026 bytes
.../assets/ico/apple-touch-icon-72-precomposed.png | Bin 0 -> 5681 bytes
.../jam/bootstrap/docs/assets/ico/favicon.ico | Bin 0 -> 1150 bytes
.../jam/bootstrap/docs/assets/ico/favicon.png | Bin 0 -> 2711 bytes
.../docs/assets/img/bootstrap-docs-readme.png | Bin 0 -> 225976 bytes
.../docs/assets/img/bootstrap-mdo-sfmoma-01.jpg | Bin 0 -> 125346 bytes
.../docs/assets/img/bootstrap-mdo-sfmoma-02.jpg | Bin 0 -> 81284 bytes
.../docs/assets/img/bootstrap-mdo-sfmoma-03.jpg | Bin 0 -> 49063 bytes
.../docs/assets/img/bs-docs-bootstrap-features.png | Bin 0 -> 11244 bytes
.../docs/assets/img/bs-docs-masthead-pattern.png | Bin 0 -> 6450 bytes
.../img/bs-docs-responsive-illustrations.png | Bin 0 -> 10572 bytes
.../docs/assets/img/bs-docs-twitter-github.png | Bin 0 -> 30968 bytes
.../docs/assets/img/example-sites/8020select.png | Bin 0 -> 62853 bytes
.../assets/img/example-sites/adoptahydrant.png | Bin 0 -> 136480 bytes
.../docs/assets/img/example-sites/breakingnews.png | Bin 0 -> 72725 bytes
.../docs/assets/img/example-sites/fleetio.png | Bin 0 -> 39837 bytes
.../assets/img/example-sites/gathercontent.png | Bin 0 -> 76560 bytes
.../docs/assets/img/example-sites/jshint.png | Bin 0 -> 7258 bytes
.../docs/assets/img/example-sites/kippt.png | Bin 0 -> 48259 bytes
.../docs/assets/img/example-sites/soundready.png | Bin 0 -> 50225 bytes
.../img/examples/bootstrap-example-carousel.png | Bin 0 -> 53908 bytes
.../img/examples/bootstrap-example-fluid.jpg | Bin 0 -> 23408 bytes
.../assets/img/examples/bootstrap-example-hero.jpg | Bin 0 -> 19805 bytes
.../bootstrap-example-marketing-narrow.png | Bin 0 -> 21869 bytes
.../img/examples/bootstrap-example-signin.png | Bin 0 -> 4202 bytes
.../img/examples/bootstrap-example-starter.jpg | Bin 0 -> 5584 bytes
.../examples/bootstrap-example-sticky-footer.png | Bin 0 -> 9749 bytes
.../assets/img/examples/browser-icon-chrome.png | Bin 0 -> 55522 bytes
.../assets/img/examples/browser-icon-firefox.png | Bin 0 -> 175994 bytes
.../assets/img/examples/browser-icon-safari.png | Bin 0 -> 209527 bytes
.../docs/assets/img/examples/slide-01.jpg | Bin 0 -> 83303 bytes
.../docs/assets/img/examples/slide-02.jpg | Bin 0 -> 137070 bytes
.../docs/assets/img/examples/slide-03.jpg | Bin 0 -> 137378 bytes
.../docs/assets/img/glyphicons-halflings-white.png | Bin 0 -> 8777 bytes
.../docs/assets/img/glyphicons-halflings.png | Bin 0 -> 12799 bytes
.../docs/assets/img/grid-baseline-20px.png | Bin 0 -> 84 bytes
.../bootstrap/docs/assets/img/less-logo-large.png | Bin 0 -> 12824 bytes
.../docs/assets/img/responsive-illustrations.png | Bin 0 -> 1008 bytes
src/fauxton/jam/bootstrap/docs/assets/js/README.md | 106 +
.../jam/bootstrap/docs/assets/js/application.js | 154 +
.../bootstrap/docs/assets/js/bootstrap-affix.js | 117 +
.../bootstrap/docs/assets/js/bootstrap-alert.js | 99 +
.../bootstrap/docs/assets/js/bootstrap-button.js | 105 +
.../bootstrap/docs/assets/js/bootstrap-carousel.js | 185 +
.../bootstrap/docs/assets/js/bootstrap-collapse.js | 167 +
.../bootstrap/docs/assets/js/bootstrap-dropdown.js | 161 +
.../bootstrap/docs/assets/js/bootstrap-modal.js | 245 +
.../bootstrap/docs/assets/js/bootstrap-popover.js | 114 +
.../docs/assets/js/bootstrap-scrollspy.js | 162 +
.../jam/bootstrap/docs/assets/js/bootstrap-tab.js | 144 +
.../bootstrap/docs/assets/js/bootstrap-tooltip.js | 287 +
.../docs/assets/js/bootstrap-transition.js | 60 +
.../docs/assets/js/bootstrap-typeahead.js | 323 +
.../jam/bootstrap/docs/assets/js/bootstrap.js | 2159 +++
.../jam/bootstrap/docs/assets/js/bootstrap.min.js | 6 +
.../assets/js/google-code-prettify/prettify.css | 30 +
.../assets/js/google-code-prettify/prettify.js | 28 +
.../jam/bootstrap/docs/assets/js/holder/holder.js | 342 +
src/fauxton/jam/bootstrap/docs/assets/js/jquery.js | 2 +
src/fauxton/jam/bootstrap/docs/base-css.html | 2193 +++
src/fauxton/jam/bootstrap/docs/build/index.js | 44 +
src/fauxton/jam/bootstrap/docs/build/package.json | 6 +
src/fauxton/jam/bootstrap/docs/components.html | 2606 ++++
src/fauxton/jam/bootstrap/docs/customize.html | 514 +
.../jam/bootstrap/docs/examples/carousel.html | 452 +
src/fauxton/jam/bootstrap/docs/examples/fluid.html | 154 +
src/fauxton/jam/bootstrap/docs/examples/hero.html | 126 +
.../docs/examples/marketing-alternate.html | 172 +
.../bootstrap/docs/examples/marketing-narrow.html | 137 +
.../jam/bootstrap/docs/examples/signin.html | 94 +
.../bootstrap/docs/examples/starter-template.html | 79 +
.../jam/bootstrap/docs/examples/sticky-footer.html | 124 +
src/fauxton/jam/bootstrap/docs/extend.html | 290 +
.../jam/bootstrap/docs/getting-started.html | 368 +
src/fauxton/jam/bootstrap/docs/index.html | 221 +
src/fauxton/jam/bootstrap/docs/javascript.html | 1759 +++
src/fauxton/jam/bootstrap/docs/scaffolding.html | 602 +
.../jam/bootstrap/docs/templates/layout.mustache | 151 +
.../docs/templates/pages/base-css.mustache | 2080 +++
.../docs/templates/pages/components.mustache | 2485 ++++
.../docs/templates/pages/customize.mustache | 393 +
.../bootstrap/docs/templates/pages/extend.mustache | 169 +
.../docs/templates/pages/getting-started.mustache | 247 +
.../bootstrap/docs/templates/pages/index.mustache | 100 +
.../docs/templates/pages/javascript.mustache | 1639 ++
.../docs/templates/pages/scaffolding.mustache | 485 +
.../bootstrap/img/glyphicons-halflings-white.png | Bin 0 -> 8777 bytes
.../jam/bootstrap/img/glyphicons-halflings.png | Bin 0 -> 12799 bytes
src/fauxton/jam/bootstrap/js/bootstrap-affix.js | 117 +
src/fauxton/jam/bootstrap/js/bootstrap-alert.js | 99 +
src/fauxton/jam/bootstrap/js/bootstrap-button.js | 105 +
src/fauxton/jam/bootstrap/js/bootstrap-carousel.js | 185 +
src/fauxton/jam/bootstrap/js/bootstrap-collapse.js | 167 +
src/fauxton/jam/bootstrap/js/bootstrap-dropdown.js | 161 +
src/fauxton/jam/bootstrap/js/bootstrap-modal.js | 245 +
src/fauxton/jam/bootstrap/js/bootstrap-popover.js | 114 +
.../jam/bootstrap/js/bootstrap-scrollspy.js | 162 +
src/fauxton/jam/bootstrap/js/bootstrap-tab.js | 144 +
src/fauxton/jam/bootstrap/js/bootstrap-tooltip.js | 287 +
.../jam/bootstrap/js/bootstrap-transition.js | 60 +
.../jam/bootstrap/js/bootstrap-typeahead.js | 323 +
src/fauxton/jam/bootstrap/js/tests/index.html | 56 +
src/fauxton/jam/bootstrap/js/tests/phantom.js | 63 +
src/fauxton/jam/bootstrap/js/tests/server.js | 14 +
.../jam/bootstrap/js/tests/unit/bootstrap-affix.js | 25 +
.../jam/bootstrap/js/tests/unit/bootstrap-alert.js | 62 +
.../bootstrap/js/tests/unit/bootstrap-button.js | 102 +
.../bootstrap/js/tests/unit/bootstrap-carousel.js | 69 +
.../bootstrap/js/tests/unit/bootstrap-collapse.js | 94 +
.../bootstrap/js/tests/unit/bootstrap-dropdown.js | 151 +
.../jam/bootstrap/js/tests/unit/bootstrap-modal.js | 120 +
.../bootstrap/js/tests/unit/bootstrap-phantom.js | 21 +
.../bootstrap/js/tests/unit/bootstrap-popover.js | 113 +
.../bootstrap/js/tests/unit/bootstrap-scrollspy.js | 37 +
.../jam/bootstrap/js/tests/unit/bootstrap-tab.js | 86 +
.../bootstrap/js/tests/unit/bootstrap-tooltip.js | 159 +
.../js/tests/unit/bootstrap-transition.js | 13 +
.../bootstrap/js/tests/unit/bootstrap-typeahead.js | 231 +
.../jam/bootstrap/js/tests/vendor/jquery.js | 2 +
.../jam/bootstrap/js/tests/vendor/qunit.css | 232 +
src/fauxton/jam/bootstrap/js/tests/vendor/qunit.js | 1510 ++
src/fauxton/jam/bootstrap/less/accordion.less | 34 +
src/fauxton/jam/bootstrap/less/alerts.less | 79 +
src/fauxton/jam/bootstrap/less/bootstrap.less | 63 +
src/fauxton/jam/bootstrap/less/breadcrumbs.less | 24 +
src/fauxton/jam/bootstrap/less/button-groups.less | 227 +
src/fauxton/jam/bootstrap/less/buttons.less | 230 +
src/fauxton/jam/bootstrap/less/carousel.less | 131 +
src/fauxton/jam/bootstrap/less/close.less | 31 +
src/fauxton/jam/bootstrap/less/code.less | 61 +
.../jam/bootstrap/less/component-animations.less | 22 +
src/fauxton/jam/bootstrap/less/dropdowns.less | 233 +
src/fauxton/jam/bootstrap/less/forms.less | 687 +
src/fauxton/jam/bootstrap/less/grid.less | 21 +
src/fauxton/jam/bootstrap/less/hero-unit.less | 25 +
src/fauxton/jam/bootstrap/less/labels-badges.less | 82 +
src/fauxton/jam/bootstrap/less/layouts.less | 16 +
src/fauxton/jam/bootstrap/less/media.less | 55 +
src/fauxton/jam/bootstrap/less/mixins.less | 686 +
src/fauxton/jam/bootstrap/less/modals.less | 95 +
src/fauxton/jam/bootstrap/less/navbar.less | 490 +
src/fauxton/jam/bootstrap/less/navs.less | 391 +
src/fauxton/jam/bootstrap/less/pager.less | 41 +
src/fauxton/jam/bootstrap/less/pagination.less | 121 +
src/fauxton/jam/bootstrap/less/popovers.less | 129 +
src/fauxton/jam/bootstrap/less/progress-bars.less | 122 +
src/fauxton/jam/bootstrap/less/reset.less | 216 +
.../jam/bootstrap/less/responsive-1200px-min.less | 28 +
.../jam/bootstrap/less/responsive-767px-max.less | 193 +
.../jam/bootstrap/less/responsive-768px-979px.less | 19 +
.../jam/bootstrap/less/responsive-navbar.less | 185 +
.../jam/bootstrap/less/responsive-utilities.less | 43 +
src/fauxton/jam/bootstrap/less/responsive.less | 57 +
src/fauxton/jam/bootstrap/less/scaffolding.less | 52 +
src/fauxton/jam/bootstrap/less/sprites.less | 193 +
src/fauxton/jam/bootstrap/less/tables.less | 237 +
src/fauxton/jam/bootstrap/less/tests/buttons.html | 139 +
src/fauxton/jam/bootstrap/less/tests/css-tests.css | 139 +
.../jam/bootstrap/less/tests/css-tests.html | 1345 ++
.../jam/bootstrap/less/tests/forms-responsive.html | 71 +
src/fauxton/jam/bootstrap/less/tests/forms.html | 179 +
.../jam/bootstrap/less/tests/navbar-fixed-top.html | 104 +
.../bootstrap/less/tests/navbar-static-top.html | 107 +
src/fauxton/jam/bootstrap/less/tests/navbar.html | 107 +
src/fauxton/jam/bootstrap/less/thumbnails.less | 52 +
src/fauxton/jam/bootstrap/less/tooltip.less | 70 +
src/fauxton/jam/bootstrap/less/type.less | 235 +
src/fauxton/jam/bootstrap/less/utilities.less | 30 +
src/fauxton/jam/bootstrap/less/variables.less | 301 +
src/fauxton/jam/bootstrap/less/wells.less | 29 +
src/fauxton/jam/bootstrap/package.json | 26 +
src/fauxton/jam/codemirror/LICENSE | 23 +
src/fauxton/jam/codemirror/README.md | 8 +
src/fauxton/jam/codemirror/keymap/emacs.js | 30 +
src/fauxton/jam/codemirror/keymap/vim.js | 847 ++
src/fauxton/jam/codemirror/lib/codemirror.css | 174 +
src/fauxton/jam/codemirror/lib/codemirror.js | 3186 ++++
src/fauxton/jam/codemirror/lib/util/closetag.js | 164 +
src/fauxton/jam/codemirror/lib/util/dialog.css | 27 +
src/fauxton/jam/codemirror/lib/util/dialog.js | 70 +
src/fauxton/jam/codemirror/lib/util/foldcode.js | 196 +
src/fauxton/jam/codemirror/lib/util/formatting.js | 196 +
.../jam/codemirror/lib/util/javascript-hint.js | 134 +
src/fauxton/jam/codemirror/lib/util/loadmode.js | 51 +
.../jam/codemirror/lib/util/match-highlighter.js | 44 +
src/fauxton/jam/codemirror/lib/util/multiplex.js | 77 +
src/fauxton/jam/codemirror/lib/util/overlay.js | 59 +
src/fauxton/jam/codemirror/lib/util/pig-hint.js | 123 +
.../jam/codemirror/lib/util/runmode-standalone.js | 90 +
src/fauxton/jam/codemirror/lib/util/runmode.js | 53 +
src/fauxton/jam/codemirror/lib/util/search.js | 118 +
.../jam/codemirror/lib/util/searchcursor.js | 119 +
.../jam/codemirror/lib/util/simple-hint.css | 16 +
src/fauxton/jam/codemirror/lib/util/simple-hint.js | 102 +
src/fauxton/jam/codemirror/lib/util/xml-hint.js | 131 +
src/fauxton/jam/codemirror/mode/clike/clike.js | 285 +
src/fauxton/jam/codemirror/mode/clike/index.html | 102 +
src/fauxton/jam/codemirror/mode/clike/scala.html | 766 +
src/fauxton/jam/codemirror/mode/clojure/clojure.js | 206 +
src/fauxton/jam/codemirror/mode/clojure/index.html | 67 +
.../jam/codemirror/mode/coffeescript/LICENSE | 22 +
.../codemirror/mode/coffeescript/coffeescript.js | 346 +
.../jam/codemirror/mode/coffeescript/index.html | 728 +
.../jam/codemirror/mode/commonlisp/commonlisp.js | 101 +
.../jam/codemirror/mode/commonlisp/index.html | 165 +
src/fauxton/jam/codemirror/mode/css/css.js | 448 +
src/fauxton/jam/codemirror/mode/css/index.html | 58 +
src/fauxton/jam/codemirror/mode/css/test.js | 501 +
src/fauxton/jam/codemirror/mode/diff/diff.js | 32 +
src/fauxton/jam/codemirror/mode/diff/index.html | 105 +
src/fauxton/jam/codemirror/mode/ecl/ecl.js | 203 +
src/fauxton/jam/codemirror/mode/ecl/index.html | 42 +
src/fauxton/jam/codemirror/mode/erlang/erlang.js | 463 +
src/fauxton/jam/codemirror/mode/erlang/index.html | 63 +
src/fauxton/jam/codemirror/mode/gfm/gfm.js | 94 +
src/fauxton/jam/codemirror/mode/gfm/index.html | 71 +
src/fauxton/jam/codemirror/mode/gfm/test.js | 225 +
src/fauxton/jam/codemirror/mode/go/go.js | 170 +
src/fauxton/jam/codemirror/mode/go/index.html | 73 +
src/fauxton/jam/codemirror/mode/groovy/groovy.js | 210 +
src/fauxton/jam/codemirror/mode/groovy/index.html | 72 +
src/fauxton/jam/codemirror/mode/haskell/haskell.js | 242 +
src/fauxton/jam/codemirror/mode/haskell/index.html | 61 +
src/fauxton/jam/codemirror/mode/haxe/haxe.js | 429 +
src/fauxton/jam/codemirror/mode/haxe/index.html | 91 +
.../codemirror/mode/htmlembedded/htmlembedded.js | 73 +
.../jam/codemirror/mode/htmlembedded/index.html | 50 +
.../jam/codemirror/mode/htmlmixed/htmlmixed.js | 84 +
.../jam/codemirror/mode/htmlmixed/index.html | 52 +
.../jam/codemirror/mode/javascript/index.html | 85 +
.../jam/codemirror/mode/javascript/javascript.js | 427 +
.../jam/codemirror/mode/javascript/typescript.html | 48 +
src/fauxton/jam/codemirror/mode/jinja2/index.html | 38 +
src/fauxton/jam/codemirror/mode/jinja2/jinja2.js | 42 +
src/fauxton/jam/codemirror/mode/less/index.html | 740 +
src/fauxton/jam/codemirror/mode/less/less.js | 266 +
src/fauxton/jam/codemirror/mode/lua/index.html | 73 +
src/fauxton/jam/codemirror/mode/lua/lua.js | 140 +
.../jam/codemirror/mode/markdown/index.html | 343 +
.../jam/codemirror/mode/markdown/markdown.js | 481 +
src/fauxton/jam/codemirror/mode/markdown/test.js | 1266 ++
src/fauxton/jam/codemirror/mode/mysql/index.html | 42 +
src/fauxton/jam/codemirror/mode/mysql/mysql.js | 203 +
.../jam/codemirror/mode/ntriples/index.html | 33 +
.../jam/codemirror/mode/ntriples/ntriples.js | 172 +
src/fauxton/jam/codemirror/mode/ocaml/index.html | 130 +
src/fauxton/jam/codemirror/mode/ocaml/ocaml.js | 114 +
src/fauxton/jam/codemirror/mode/pascal/LICENSE | 7 +
src/fauxton/jam/codemirror/mode/pascal/index.html | 49 +
src/fauxton/jam/codemirror/mode/pascal/pascal.js | 94 +
src/fauxton/jam/codemirror/mode/perl/LICENSE | 19 +
src/fauxton/jam/codemirror/mode/perl/index.html | 63 +
src/fauxton/jam/codemirror/mode/perl/perl.js | 816 +
src/fauxton/jam/codemirror/mode/php/index.html | 49 +
src/fauxton/jam/codemirror/mode/php/php.js | 148 +
src/fauxton/jam/codemirror/mode/pig/index.html | 43 +
src/fauxton/jam/codemirror/mode/pig/pig.js | 172 +
src/fauxton/jam/codemirror/mode/plsql/index.html | 63 +
src/fauxton/jam/codemirror/mode/plsql/plsql.js | 217 +
.../jam/codemirror/mode/properties/index.html | 41 +
.../jam/codemirror/mode/properties/properties.js | 63 +
src/fauxton/jam/codemirror/mode/python/LICENSE.txt | 21 +
src/fauxton/jam/codemirror/mode/python/index.html | 123 +
src/fauxton/jam/codemirror/mode/python/python.js | 340 +
src/fauxton/jam/codemirror/mode/r/LICENSE | 24 +
src/fauxton/jam/codemirror/mode/r/index.html | 74 +
src/fauxton/jam/codemirror/mode/r/r.js | 141 +
.../jam/codemirror/mode/rpm/changes/changes.js | 19 +
.../jam/codemirror/mode/rpm/changes/index.html | 54 +
.../jam/codemirror/mode/rpm/spec/index.html | 100 +
src/fauxton/jam/codemirror/mode/rpm/spec/spec.css | 5 +
src/fauxton/jam/codemirror/mode/rpm/spec/spec.js | 66 +
src/fauxton/jam/codemirror/mode/rst/index.html | 526 +
src/fauxton/jam/codemirror/mode/rst/rst.js | 326 +
src/fauxton/jam/codemirror/mode/ruby/LICENSE | 24 +
src/fauxton/jam/codemirror/mode/ruby/index.html | 172 +
src/fauxton/jam/codemirror/mode/ruby/ruby.js | 195 +
src/fauxton/jam/codemirror/mode/rust/index.html | 49 +
src/fauxton/jam/codemirror/mode/rust/rust.js | 432 +
src/fauxton/jam/codemirror/mode/scheme/index.html | 65 +
src/fauxton/jam/codemirror/mode/scheme/scheme.js | 230 +
src/fauxton/jam/codemirror/mode/shell/index.html | 50 +
src/fauxton/jam/codemirror/mode/shell/shell.js | 118 +
src/fauxton/jam/codemirror/mode/sieve/LICENSE | 23 +
src/fauxton/jam/codemirror/mode/sieve/index.html | 81 +
src/fauxton/jam/codemirror/mode/sieve/sieve.js | 156 +
.../jam/codemirror/mode/smalltalk/index.html | 56 +
.../jam/codemirror/mode/smalltalk/smalltalk.js | 139 +
src/fauxton/jam/codemirror/mode/smarty/index.html | 83 +
src/fauxton/jam/codemirror/mode/smarty/smarty.js | 148 +
src/fauxton/jam/codemirror/mode/sparql/index.html | 41 +
src/fauxton/jam/codemirror/mode/sparql/sparql.js | 143 +
src/fauxton/jam/codemirror/mode/stex/index.html | 98 +
src/fauxton/jam/codemirror/mode/stex/stex.js | 182 +
src/fauxton/jam/codemirror/mode/stex/test.js | 343 +
.../jam/codemirror/mode/tiddlywiki/index.html | 141 +
.../jam/codemirror/mode/tiddlywiki/tiddlywiki.css | 14 +
.../jam/codemirror/mode/tiddlywiki/tiddlywiki.js | 384 +
src/fauxton/jam/codemirror/mode/tiki/index.html | 83 +
src/fauxton/jam/codemirror/mode/tiki/tiki.css | 26 +
src/fauxton/jam/codemirror/mode/tiki/tiki.js | 309 +
src/fauxton/jam/codemirror/mode/vb/LICENSE.txt | 21 +
src/fauxton/jam/codemirror/mode/vb/index.html | 89 +
src/fauxton/jam/codemirror/mode/vb/vb.js | 260 +
.../jam/codemirror/mode/vbscript/index.html | 43 +
.../jam/codemirror/mode/vbscript/vbscript.js | 26 +
.../jam/codemirror/mode/velocity/index.html | 104 +
.../jam/codemirror/mode/velocity/velocity.js | 146 +
src/fauxton/jam/codemirror/mode/verilog/index.html | 211 +
src/fauxton/jam/codemirror/mode/verilog/verilog.js | 194 +
src/fauxton/jam/codemirror/mode/xml/index.html | 45 +
src/fauxton/jam/codemirror/mode/xml/xml.js | 319 +
src/fauxton/jam/codemirror/mode/xquery/LICENSE | 20 +
src/fauxton/jam/codemirror/mode/xquery/index.html | 223 +
.../jam/codemirror/mode/xquery/test/index.html | 27 +
.../jam/codemirror/mode/xquery/test/testBase.js | 42 +
.../mode/xquery/test/testEmptySequenceKeyword.js | 16 +
.../codemirror/mode/xquery/test/testMultiAttr.js | 16 +
.../codemirror/mode/xquery/test/testNamespaces.js | 91 +
.../mode/xquery/test/testProcessingInstructions.js | 16 +
.../jam/codemirror/mode/xquery/test/testQuotes.js | 19 +
src/fauxton/jam/codemirror/mode/xquery/xquery.js | 451 +
src/fauxton/jam/codemirror/mode/yaml/index.html | 68 +
src/fauxton/jam/codemirror/mode/yaml/yaml.js | 95 +
src/fauxton/jam/codemirror/mode/z80/index.html | 39 +
src/fauxton/jam/codemirror/mode/z80/z80.js | 113 +
src/fauxton/jam/codemirror/package.json | 32 +
.../jam/codemirror/theme/ambiance-mobile.css | 6 +
src/fauxton/jam/codemirror/theme/ambiance.css | 81 +
src/fauxton/jam/codemirror/theme/blackboard.css | 25 +
src/fauxton/jam/codemirror/theme/cobalt.css | 18 +
src/fauxton/jam/codemirror/theme/eclipse.css | 25 +
src/fauxton/jam/codemirror/theme/elegant.css | 10 +
src/fauxton/jam/codemirror/theme/erlang-dark.css | 21 +
src/fauxton/jam/codemirror/theme/lesser-dark.css | 44 +
src/fauxton/jam/codemirror/theme/monokai.css | 28 +
src/fauxton/jam/codemirror/theme/neat.css | 9 +
src/fauxton/jam/codemirror/theme/night.css | 21 +
src/fauxton/jam/codemirror/theme/rubyblue.css | 21 +
src/fauxton/jam/codemirror/theme/vibrant-ink.css | 27 +
src/fauxton/jam/codemirror/theme/xq-dark.css | 46 +
src/fauxton/jam/d3/d3.js | 7790 ++++++++++
src/fauxton/jam/d3/package.json | 42 +
src/fauxton/jam/jquery/dist/jquery.js | 8755 +++++++++++
src/fauxton/jam/jquery/dist/jquery.min.js | 6 +
src/fauxton/jam/jquery/dist/jquery.min.map | 1 +
src/fauxton/jam/jquery/dist/jquery.pre-min.js | 8734 +++++++++++
src/fauxton/jam/jquery/package.json | 41 +
src/fauxton/jam/jquery/src/sizzle/package.json | 37 +
.../src/sizzle/speed/benchmark.js/package.json | 54 +
src/fauxton/jam/jquery/test/qunit/package.json | 37 +
src/fauxton/jam/lessc/README.md | 22 +
src/fauxton/jam/lessc/less-rhino.js | 3670 +++++
src/fauxton/jam/lessc/less.js | 3492 +++++
src/fauxton/jam/lessc/lessc.js | 116 +
src/fauxton/jam/lessc/package.json | 33 +
src/fauxton/jam/lodash/dist/lodash.backbone.js | 3162 ++++
src/fauxton/jam/lodash/dist/lodash.backbone.min.js | 26 +
src/fauxton/jam/lodash/dist/lodash.compat.js | 5543 +++++++
src/fauxton/jam/lodash/dist/lodash.compat.min.js | 47 +
src/fauxton/jam/lodash/dist/lodash.js | 5264 +++++++
src/fauxton/jam/lodash/dist/lodash.legacy.js | 5469 +++++++
src/fauxton/jam/lodash/dist/lodash.legacy.min.js | 45 +
src/fauxton/jam/lodash/dist/lodash.min.js | 44 +
src/fauxton/jam/lodash/dist/lodash.mobile.js | 5342 +++++++
src/fauxton/jam/lodash/dist/lodash.mobile.min.js | 44 +
src/fauxton/jam/lodash/dist/lodash.underscore.js | 4407 ++++++
.../jam/lodash/dist/lodash.underscore.min.js | 35 +
src/fauxton/jam/lodash/lodash.js | 5557 +++++++
src/fauxton/jam/lodash/package.json | 39 +
src/fauxton/jam/nvd3/nv.d3.css | 671 +
src/fauxton/jam/nvd3/nv.d3.js |11502 +++++++++++++++
src/fauxton/jam/nvd3/package.json | 21 +
src/fauxton/jam/require.config.js | 196 +
src/fauxton/jam/require.js | 2197 +++
src/fauxton/jam/text/LICENSE | 58 +
src/fauxton/jam/text/README.md | 194 +
src/fauxton/jam/text/package.json | 32 +
src/fauxton/jam/text/text.js | 308 +
src/fauxton/jam/underscore/LICENSE | 22 +
src/fauxton/jam/underscore/README.md | 19 +
src/fauxton/jam/underscore/package.json | 24 +
src/fauxton/jam/underscore/underscore.js | 1226 ++
src/fauxton/js/addons/config/base.js | 28 +
src/fauxton/js/addons/config/resources.js | 177 +
src/fauxton/js/addons/config/routes.js | 44 +
.../js/addons/config/templates/dashboard.html | 52 +
src/fauxton/js/addons/config/templates/item.html | 31 +
src/fauxton/js/addons/contribute/base.js | 33 +
src/fauxton/js/addons/logs/base.js | 28 +
src/fauxton/js/addons/logs/resources.js | 228 +
src/fauxton/js/addons/logs/routes.js | 47 +
.../js/addons/logs/templates/dashboard.html | 46 +
.../js/addons/logs/templates/filterItem.html | 16 +
src/fauxton/js/addons/logs/templates/sidebar.html | 27 +
src/fauxton/js/addons/stats/assets/less/stats.less | 20 +
src/fauxton/js/addons/stats/base.js | 28 +
src/fauxton/js/addons/stats/resources.js | 37 +
src/fauxton/js/addons/stats/routes.js | 59 +
.../js/addons/stats/templates/by_method.html | 16 +
.../js/addons/stats/templates/pie_table.html | 56 +
src/fauxton/js/addons/stats/templates/stats.html | 16 +
.../js/addons/stats/templates/statselect.html | 22 +
src/fauxton/js/addons/stats/views.js | 173 +
src/fauxton/js/api.js | 101 +
src/fauxton/js/app.js | 76 +
src/fauxton/js/helpers.js | 35 +
src/fauxton/js/initialize.js | 61 +
src/fauxton/js/load_addons.js | 27 +
src/fauxton/js/load_addons.js.underscore | 27 +
src/fauxton/js/main.js | 40 +
src/fauxton/js/modules/databases/base.js | 36 +
src/fauxton/js/modules/databases/resources.js | 148 +
src/fauxton/js/modules/databases/routes.js | 70 +
src/fauxton/js/modules/databases/views.js | 190 +
src/fauxton/js/modules/documents/base.js | 24 +
src/fauxton/js/modules/documents/resources.js | 261 +
src/fauxton/js/modules/documents/routes.js | 428 +
src/fauxton/js/modules/documents/views.js | 958 ++
src/fauxton/js/modules/fauxton/base.js | 161 +
src/fauxton/js/modules/fauxton/layout.js | 96 +
src/fauxton/js/modules/pouchdb/base.js | 57 +
src/fauxton/js/modules/pouchdb/pouch.collate.js | 115 +
.../js/modules/pouchdb/pouchdb.mapreduce.js | 286 +
src/fauxton/js/router.js | 164 +
src/fauxton/js/templates/databases/item.html | 20 +
src/fauxton/js/templates/databases/list.html | 30 +
src/fauxton/js/templates/databases/sidebar.html | 31 +
.../js/templates/documents/all_docs_item.html | 26 +
.../js/templates/documents/all_docs_list.html | 141 +
src/fauxton/js/templates/documents/changes.html | 36 +
src/fauxton/js/templates/documents/doc.html | 24 +
.../js/templates/documents/doc_field_editor.html | 60 +
.../templates/documents/doc_field_editor_tabs.html | 26 +
.../js/templates/documents/index_menu_item.html | 17 +
.../js/templates/documents/index_row_docular.html | 26 +
.../js/templates/documents/index_row_tabular.html | 25 +
src/fauxton/js/templates/documents/search.html | 15 +
src/fauxton/js/templates/documents/sidebar.html | 29 +
src/fauxton/js/templates/documents/tabs.html | 39 +
.../js/templates/documents/view_editor.html | 92 +
src/fauxton/js/templates/fauxton/api_bar.html | 30 +
src/fauxton/js/templates/fauxton/breadcrumbs.html | 24 +
src/fauxton/js/templates/fauxton/footer.html | 15 +
src/fauxton/js/templates/fauxton/nav_bar.html | 49 +
src/fauxton/js/templates/fauxton/notification.html | 18 +
src/fauxton/js/templates/fauxton/pagination.html | 31 +
src/fauxton/js/templates/layouts/one_pane.html | 28 +
src/fauxton/js/templates/layouts/two_pane.html | 29 +
.../js/templates/layouts/with_right_sidebar.html | 27 +
src/fauxton/js/templates/layouts/with_sidebar.html | 27 +
src/fauxton/js/templates/layouts/with_tabs.html | 27 +
.../js/templates/layouts/with_tabs_sidebar.html | 28 +
src/fauxton/package.json | 43 -
src/fauxton/push | 5 +
src/fauxton/readme.md | 40 +-
src/fauxton/rebuild | 9 +
src/fauxton/settings.json.default | 27 -
src/fauxton/settings.json.sample_external | 10 -
src/fauxton/tasks/addon/rename.json | 5 -
src/fauxton/tasks/addon/root/base.js.underscore | 21 -
.../tasks/addon/root/resources.js.underscore | 21 -
src/fauxton/tasks/addon/root/route.js.underscore | 21 -
src/fauxton/tasks/addon/template.js | 70 -
src/fauxton/tasks/couchserver.js | 72 -
src/fauxton/tasks/fauxton.js | 92 -
src/fauxton/tasks/helper.js | 32 -
src/fauxton/test/jasmine/index.html | 44 -
src/fauxton/test/jasmine/spec/example.js | 73 -
src/fauxton/test/jasmine/vendor/MIT.LICENSE | 20 -
src/fauxton/test/jasmine/vendor/jasmine-html.js | 190 -
src/fauxton/test/jasmine/vendor/jasmine.css | 166 -
src/fauxton/test/jasmine/vendor/jasmine.js | 2476 ----
.../test/jasmine/vendor/jasmine_favicon.png | Bin 905 -> 0 bytes
src/fauxton/test/qunit/index.html | 47 -
src/fauxton/test/qunit/tests/example.js | 54 -
src/fauxton/test/qunit/vendor/qunit.css | 228 -
src/fauxton/test/qunit/vendor/qunit.js | 1589 --
src/fauxton/writing_addons.md | 163 -
655 files changed, 166585 insertions(+), 67805 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/couchdb/blob/4615a788/src/fauxton/Gruntfile.js
----------------------------------------------------------------------
diff --git a/src/fauxton/Gruntfile.js b/src/fauxton/Gruntfile.js
deleted file mode 100644
index b76ae24..0000000
--- a/src/fauxton/Gruntfile.js
+++ /dev/null
@@ -1,356 +0,0 @@
-// Licensed under the Apache License, Version 2.0 (the "License"); you may not
-// use this file except in compliance with the License. You may obtain a copy of
-// the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
-// WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
-// License for the specific language governing permissions and limitations under
-// the License.
-
-
-// This is the main application configuration file. It is a Grunt
-// configuration file, which you can learn more about here:
-// https://github.com/cowboy/grunt/blob/master/docs/configuring.md
-
-module.exports = function(grunt) {
- var helper = require('./tasks/helper').init(grunt),
- path = require('path');
-
- var couch_config = function () {
-
- var default_couch_config = {
- fauxton: {
- db: 'http://localhost:5984/fauxton',
- app: './couchapp.js',
- options: {
- okay_if_missing: true
- }
- }
- };
-
- var settings_couch_config = helper.readSettingsFile().couch_config;
- return settings_couch_config || default_couch_config;
- }();
-
- var cleanable = function(){
- // Whitelist files and directories to be cleaned
-
- // You'll always want to clean these two directories
- var theListToClean = ["dist/", "app/load_addons.js"];
- // Now find the external addons you have and add them for cleaning up
- helper.processAddons(function(addon){
- // Only clean addons that are included from a local dir
- if (addon.path){
- theListToClean.push("app/addons/" + addon.name);
- }
- });
- return theListToClean;
- }();
-
- var assets = function(){
- // Base assets
- var theAssets = {
- less:{
- paths: ["assets/less"],
- files: {
- "dist/debug/css/fauxton.css": "assets/less/fauxton.less"
- }
- },
- img: ["assets/img/**"]
- };
- helper.processAddons(function(addon){
- // Less files from addons
- var root = addon.path || "app/addons/" + addon.name;
- var lessPath = root + "/assets/less";
- if(path.existsSync(lessPath)){
- // .less files exist for this addon
- theAssets.less.paths.push(lessPath);
- theAssets.less.files["dist/debug/css/" + addon.name + ".css"] =
- lessPath + "/" + addon.name + ".less";
- }
- // Images
- root = addon.path || "app/addons/" + addon.name;
- var imgPath = root + "/assets/img";
- if(path.existsSync(imgPath)){
- theAssets.img.push(imgPath + "/**");
- }
- });
- grunt.log.write(theAssets.img[0]);
- return theAssets;
- }();
-
- var templateSettings = function(){
- var defaultSettings = {
- "src": "assets/index.underscore",
- "dest": "dist/debug/index.html",
- "variables": {
- "assets_root": "./",
- "requirejs": "require.js",
- "base": null
- }
- };
- var settings = helper.readSettingsFile();
- return {template: settings.template || defaultSettings};
- }();
-
- grunt.initConfig({
-
- // The clean task ensures all files are removed from the dist/ directory so
- // that no files linger from previous builds.
- clean: cleanable,
-
- // The lint task will run the build configuration and the application
- // JavaScript through JSHint and report any errors. You can change the
- // options for this task, by reading this:
- // https://github.com/cowboy/grunt/blob/master/docs/task_lint.md
- lint: {
- files: [
- "build/config.js", "app/**/*.js"
- ]
- },
-
- less: {
- compile: {
- options: {
- paths: assets.less.paths
- },
- files: assets.less.files
- }
- },
-
- // The jshint option for scripturl is set to lax, because the anchor
- // override inside main.js needs to test for them so as to not accidentally
- // route.
- jshint: {
- all: ['app/**/*.js', 'Gruntfile.js'],
- options: {
- scripturl: true,
- evil: true
- }
- },
-
- // The jst task compiles all application templates into JavaScript
- // functions with the underscore.js template function from 1.2.4. You can
- // change the namespace and the template options, by reading this:
- // https://github.com/gruntjs/grunt-contrib/blob/master/docs/jst.md
- //
- // The concat task depends on this file to exist, so if you decide to
- // remove this, ensure concat is updated accordingly.
- jst: {
- "dist/debug/templates.js": [
- "app/templates/**/*.html",
- "app/addons/**/templates/**/*.html"
- ]
- },
-
- template: templateSettings,
-
- // The concatenate task is used here to merge the almond require/define
- // shim and the templates into the application code. It's named
- // dist/debug/require.js, because we want to only load one script file in
- // index.html.
- concat: {
- requirejs: {
- src: ["assets/js/libs/almond.js", "dist/debug/templates.js", "dist/debug/require.js"],
- dest: "dist/debug/js/require.js"
- },
-
- index_css: {
- src: ["dist/debug/css/*.css", 'assets/css/*.css'],
- dest: 'dist/debug/css/index.css'
- }
-
- },
-
- cssmin: {
- compress: {
- files: {
- "dist/release/css/index.css": [
- "dist/debug/css/index.css", 'assets/css/*.css',
- "app/addons/**/assets/css/*.css"
- ]
- },
- options: {
- report: 'min'
- }
- }
- },
-
- uglify: {
- release: {
- files: {
- "dist/release/js/require.js": [
- "dist/debug/js/require.js"
- ]
- }
- }
- },
-
- // Runs a proxy server for easier development, no need to keep deploying to couchdb
- couchserver: {
- dist: './dist/debug/',
- port: 8000,
- proxy: {
- target: {
- host: 'localhost',
- port: 5984,
- https: false
- },
- // This sets the Host header in the proxy so that you can use external
- // CouchDB instances and not have the Host set to 'localhost'
- changeOrigin: true
- }
- },
-
- watch: {
- files: './app/**/*',
- tasks: ['debug', 'template']
- },
-
- requirejs: {
- compile: {
- options: {
- baseUrl: 'app',
- // Include the main configuration file.
- mainConfigFile: "app/config.js",
-
- // Output file.
- out: "dist/debug/require.js",
-
- // Root application module.
- name: "config",
-
- // Do not wrap everything in an IIFE.
- wrap: false,
- optimize: "none"
- }
- }
- },
-
- // The headless QUnit testing environment is provided for "free" by Grunt.
- // Simply point the configuration to your test directory.
- qunit: {
- all: ["test/qunit/*.html"]
- },
-
- // The headless Jasmine testing is provided by grunt-jasmine-task. Simply
- // point the configuration to your test directory.
- jasmine: {
- all: ["test/jasmine/*.html"]
- },
-
- // Copy build artifacts and library code into the distribution
- // see - http://gruntjs.com/configuring-tasks#building-the-files-object-dynamically
- copy: {
- couchdb: {
- files: [
- // this gets built in the template task
- {src: "dist/release/index.html", dest: "../../share/www/fauxton/index.html"},
- {src: ["**"], dest: "../../share/www/fauxton/js/", cwd:'dist/release/js/', expand: true},
- {src: ["**"], dest: "../../share/www/fauxton/img/", cwd:'dist/release/img/', expand: true},
- {src: ["**"], dest: "../../share/www/fauxton/css/", cwd:"dist/release/css/", expand: true}
- ]
- },
- couchdebug: {
- files: [
- // this gets built in the template task
- {src: "dist/debug/index.html", dest: "../../share/www/fauxton/index.html"},
- {src: ["**"], dest: "../../share/www/fauxton/js/", cwd:'dist/debug/js/', expand: true},
- {src: ["**"], dest: "../../share/www/fauxton/img/", cwd:'dist/debug/img/', expand: true},
- {src: ["**"], dest: "../../share/www/fauxton/css/", cwd:"dist/debug/css/", expand: true}
- ]
- },
- dist:{
- files:[
- {src: "dist/debug/index.html", dest: "dist/release/index.html"},
- {src: assets.img, dest: "dist/release/img/", flatten: true, expand: true}
- ]
- },
- debug:{
- files:[
- {src: assets.img, dest: "dist/debug/img/", flatten: true, expand: true}
- ]
- }
- },
-
- get_deps: {
- "default": {
- src: "settings.json"
- }
- },
-
- gen_load_addons: {
- "default": {
- src: "settings.json"
- }
- },
-
- mkcouchdb: couch_config,
- rmcouchdb: couch_config,
- couchapp: couch_config
-
- });
-
- /*
- * Load Grunt plugins
- */
- // Load fauxton specific tasks
- grunt.loadTasks('tasks');
- // Load the couchapp task
- grunt.loadNpmTasks('grunt-couchapp');
- // Load the copy task
- grunt.loadNpmTasks('grunt-contrib');
- // Load the exec task
- grunt.loadNpmTasks('grunt-exec');
- // Load Require.js task
- grunt.loadNpmTasks('grunt-requirejs');
- // Load UglifyJS task
- grunt.loadNpmTasks('grunt-contrib-uglify');
- // Load CSSMin task
- grunt.loadNpmTasks('grunt-contrib-cssmin');
-
- /*
- * Default task
- */
- // defult task - install minified app to local CouchDB
- grunt.registerTask('default', 'couchdb');
-
- /*
- * Transformation tasks
- */
- // clean out previous build artefacts, lint and unit test
- grunt.registerTask('test', ['clean', 'jshint']); //qunit
- // Fetch dependencies (from git or local dir), lint them and make load_addons
- grunt.registerTask('dependencies', ['get_deps', 'jshint', 'gen_load_addons:default']);
- // build templates, js and css
- grunt.registerTask('build', ['jst', 'requirejs', 'concat:requirejs', 'less', 'concat:index_css', 'template']);
- // minify code and css, ready for release.
- grunt.registerTask('minify', ['uglify', 'cssmin:compress']);
-
- /*
- * Build the app in either dev, debug, or release mode
- */
- // dev server
- grunt.registerTask('dev', ['debug', 'couchserver']);
- // build a debug release
- grunt.registerTask('debug', ['test', 'dependencies', 'build', 'copy:debug']);
- // build a release
- grunt.registerTask('release', ['test' ,'dependencies', 'build', 'minify', 'copy:dist']);
-
- /*
- * Install into CouchDB in either debug, release, or couchapp mode
- */
- // make a development install that is server by mochiweb under _utils
- grunt.registerTask('couchdebug', ['debug', 'copy:couchdebug']);
- // make a minimized install that is server by mochiweb under _utils
- grunt.registerTask('couchdb', ['release', 'copy:couchdb']);
- // make an install that can be deployed as a couchapp
- grunt.registerTask('couchapp_setup', ['build', 'minify', 'copy:dist']);
- // install fauxton as couchapp
- grunt.registerTask('couchapp_install', ['rmcouchdb:fauxton', 'mkcouchdb:fauxton', 'couchapp:fauxton']);
- // setup and install fauxton as couchapp
- grunt.registerTask('couchapp_deploy', ['couchapp_setup', 'couchapp_install']);
-};
http://git-wip-us.apache.org/repos/asf/couchdb/blob/4615a788/src/fauxton/_ddoc/rewrites.json
----------------------------------------------------------------------
diff --git a/src/fauxton/_ddoc/rewrites.json b/src/fauxton/_ddoc/rewrites.json
new file mode 100644
index 0000000..eb21885
--- /dev/null
+++ b/src/fauxton/_ddoc/rewrites.json
@@ -0,0 +1,10 @@
+[
+ { "description": "Access to this database" , "from": "_db" , "to" : "../.." },
+ { "from": "_db/*" , "to" : "../../*" },
+ { "from": "_ddoc/plugin_config.js" , "to" : "_list/plugin_config/plugins" },
+ { "description": "Access to this design document" , "from": "_ddoc" , "to" : "" },
+ { "from": "_ddoc/*" , "to" : "*"},
+
+ { "from": "/", "to": "index.html"},
+ { "from": "/*", "to": "*"}
+]
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/couchdb/blob/4615a788/src/fauxton/_ddoc/validate_doc_update.js
----------------------------------------------------------------------
diff --git a/src/fauxton/_ddoc/validate_doc_update.js b/src/fauxton/_ddoc/validate_doc_update.js
new file mode 100644
index 0000000..0d089d3
--- /dev/null
+++ b/src/fauxton/_ddoc/validate_doc_update.js
@@ -0,0 +1,39 @@
+/**
+ * This function as it is only allows logged in users, or admins to create,update or delete documents
+ * @param newDoc
+ * @param oldDoc
+ * @param userCtx
+ * @param secObj
+ */
+
+function validate (newDoc, oldDoc, userCtx, secObj) {
+ var ddoc = this;
+
+ secObj.admins = secObj.admins || {};
+ secObj.admins.names = secObj.admins.names || [];
+ secObj.admins.roles = secObj.admins.roles || [];
+
+ var IS_DB_ADMIN = false;
+ if(~ userCtx.roles.indexOf('_admin')) {
+ IS_DB_ADMIN = true;
+ }
+ if(~ secObj.admins.names.indexOf(userCtx.name)) {
+ IS_DB_ADMIN = true;
+ }
+ for(var i = 0; i < userCtx.roles; i++) {
+ if(~ secObj.admins.roles.indexOf(userCtx.roles[i])) {
+ IS_DB_ADMIN = true;
+ }
+ }
+
+ var IS_LOGGED_IN_USER = false;
+ if (userCtx.name !== null) {
+ IS_LOGGED_IN_USER = true;
+ }
+
+
+ if(IS_DB_ADMIN || IS_LOGGED_IN_USER)
+ log('User : ' + userCtx.name + ' changing document: ' + newDoc._id);
+ else
+ throw {'forbidden':'Only admins and users can alter documents'};
+}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/couchdb/blob/4615a788/src/fauxton/app/addons/config/base.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/config/base.js b/src/fauxton/app/addons/config/base.js
deleted file mode 100644
index f589b16..0000000
--- a/src/fauxton/app/addons/config/base.js
+++ /dev/null
@@ -1,28 +0,0 @@
-// Licensed under the Apache License, Version 2.0 (the "License"); you may not
-// use this file except in compliance with the License. You may obtain a copy of
-// the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
-// WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
-// License for the specific language governing permissions and limitations under
-// the License.
-
-define([
- "app",
-
- "api",
-
- // Modules
- "addons/config/routes"
-],
-
-function(app, FauxtonAPI, Config) {
- Config.initialize = function() {
- FauxtonAPI.addHeaderLink({title: "Config", href: "#_config"});
- };
-
- return Config;
-});
http://git-wip-us.apache.org/repos/asf/couchdb/blob/4615a788/src/fauxton/app/addons/config/resources.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/config/resources.js b/src/fauxton/app/addons/config/resources.js
deleted file mode 100644
index db26bb7..0000000
--- a/src/fauxton/app/addons/config/resources.js
+++ /dev/null
@@ -1,175 +0,0 @@
-// Licensed under the Apache License, Version 2.0 (the "License"); you may not
-// use this file except in compliance with the License. You may obtain a copy of
-// the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
-// WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
-// License for the specific language governing permissions and limitations under
-// the License.
-
-define([
- "app",
- "api"
-],
-
-function (app, FauxtonAPI) {
-
- var Config = FauxtonAPI.addon();
-
- Config.Model = Backbone.Model.extend({});
- Config.OptionModel = Backbone.Model.extend({
-
- url: function () {
- return app.host + '/_config/' + this.get("section") + '/' + this.get("name");
- },
-
- isNew: function () { return false; },
-
- sync: function (method, model, options) {
-
- var params = {
- url: model.url(),
- contentType: 'application/json',
- dataType: 'json',
- data: JSON.stringify(model.get('value'))
- };
-
- if (method === 'delete') {
- params.type = 'DELETE';
- } else {
- params.type = 'PUT';
- }
-
- return $.ajax(params);
- }
- });
-
- Config.Collection = Backbone.Collection.extend({
- model: Config.Model,
-
- url: function () {
- return app.host + '/_config';
- },
-
- parse: function (resp) {
- return _.map(resp, function (section, section_name) {
- return {
- section: section_name,
- options: _.map(section, function (option, option_name) {
- return {
- name: option_name,
- value: option
- };
- })
- };
- });
- }
- });
-
- Config.ViewItem = FauxtonAPI.View.extend({
- tagName: "tr",
- className: "config-item",
- template: "addons/config/templates/item",
-
- events: {
- "click .edit-button": "editValue",
- "click #delete-value": "deleteValue",
- "click #cancel-value": "cancelEdit",
- "click #save-value": "saveValue"
- },
-
- deleteValue: function (event) {
- var result = confirm("Are you sure you want to delete this configuration value?");
-
- if (!result) { return; }
-
- this.model.destroy();
- this.remove();
- },
-
- editValue: function (event) {
- this.$("#show-value").hide();
- this.$("#edit-value-form").show();
- },
-
- saveValue: function (event) {
- this.model.save({value: this.$(".value-input").val()});
- this.render();
- },
-
- cancelEdit: function (event) {
- this.$("#edit-value-form").hide();
- this.$("#show-value").show();
- },
-
- serialize: function () {
- return {option: this.model.toJSON()};
- }
-
- });
-
- Config.View = FauxtonAPI.View.extend({
- template: "addons/config/templates/dashboard",
-
- events: {
- "click #add-section": "addSection",
- "submit #add-section-form": "submitForm"
- },
-
- submitForm: function (event) {
- event.preventDefault();
- var option = new Config.OptionModel({
- section: this.$('input[name="section"]').val(),
- name: this.$('input[name="name"]').val(),
- value: this.$('input[name="value"]').val()
- });
-
- option.save();
-
- var section = this.collection.find(function (section) {
- return section.get("section") === option.get("section");
- });
-
- if (section) {
- section.get("options").push(option.attributes);
- } else {
- this.collection.add({
- section: option.get("section"),
- options: [option.attributes]
- });
- }
-
- this.$("#add-section-modal").modal('hide');
- this.render();
- },
-
- addSection: function (event) {
- event.preventDefault();
- this.$("#add-section-modal").modal({show:true});
- },
-
- beforeRender: function() {
- this.collection.each(function(config) {
- _.each(config.get("options"), function (option, index) {
- this.insertView("table.config tbody", new Config.ViewItem({
- model: new Config.OptionModel({
- section: config.get("section"),
- name: option.name,
- value: option.value,
- index: index
- })
- }));
- }, this);
- }, this);
- },
-
- establish: function() {
- return [this.collection.fetch()];
- }
- });
-
- return Config;
-});
http://git-wip-us.apache.org/repos/asf/couchdb/blob/4615a788/src/fauxton/app/addons/config/routes.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/config/routes.js b/src/fauxton/app/addons/config/routes.js
deleted file mode 100644
index 7ed6498..0000000
--- a/src/fauxton/app/addons/config/routes.js
+++ /dev/null
@@ -1,44 +0,0 @@
-// Licensed under the Apache License, Version 2.0 (the "License"); you may not
-// use this file except in compliance with the License. You may obtain a copy of
-// the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
-// WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
-// License for the specific language governing permissions and limitations under
-// the License.
-
-define([
- "app",
-
- "api",
-
- // Modules
- "addons/config/resources"
-],
-
-function(app, FauxtonAPI, Config) {
- var configRoute = function () {
- var configs = new Config.Collection();
-
- return {
- layout: "one_pane",
- crumbs: [
- {"name": "Config","link": "_config"}
- ],
- views: {
- "#dashboard-content": new Config.View({collection: configs})
- },
- apiUrl: configs.url()
- };
- };
-
- Config.Routes = {
- "_config": configRoute
- };
-
- return Config;
-
-});
http://git-wip-us.apache.org/repos/asf/couchdb/blob/4615a788/src/fauxton/app/addons/config/templates/dashboard.html
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/config/templates/dashboard.html b/src/fauxton/app/addons/config/templates/dashboard.html
deleted file mode 100644
index 7cff90a..0000000
--- a/src/fauxton/app/addons/config/templates/dashboard.html
+++ /dev/null
@@ -1,52 +0,0 @@
-<!--
-Licensed under the Apache License, Version 2.0 (the "License"); you may not
-use this file except in compliance with the License. You may obtain a copy of
-the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
-License for the specific language governing permissions and limitations under
-the License.
--->
-
-<div class="row">
- <div class="span2 offset10">
- <button id="add-section" href="#" class="btn btn-primary button-margin">
- <i class="icon-plus icon-white"> </i>
- Add Section
- </button>
- </div>
-</div>
-<table class="config table table-striped table-bordered">
- <thead>
- <th> Section </th>
- <th> Option </th>
- <th> Value </th>
- <th></th>
- </thead>
- <tbody>
- </tbody>
-</table>
-<div id="add-section-modal" class="modal hide fade">
- <div class="modal-header">
- <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
- <h3>Create Config Option</h3>
- </div>
- <div class="modal-body">
- <form id="add-section-form" class="form well">
- <label>Section</label>
- <input type="text" name="section" placeholder="Section">
- <span class="help-block">Enter an existing section name to add to it.</span>
- <input type="text" name="name" placeholder="Name">
- <br/>
- <input type="text" name="value" placeholder="Value">
- <div class="modal-footer">
- <button type="button" class="btn" data-dismiss="modal">Cancel</button>
- <button type="submit" class="btn btn-primary"> Save </button>
- </div>
- </form>
- </div>
-</div>
http://git-wip-us.apache.org/repos/asf/couchdb/blob/4615a788/src/fauxton/app/addons/config/templates/item.html
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/config/templates/item.html b/src/fauxton/app/addons/config/templates/item.html
deleted file mode 100644
index 3e6e4ee..0000000
--- a/src/fauxton/app/addons/config/templates/item.html
+++ /dev/null
@@ -1,31 +0,0 @@
-<!--
-Licensed under the Apache License, Version 2.0 (the "License"); you may not
-use this file except in compliance with the License. You may obtain a copy of
-the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
-License for the specific language governing permissions and limitations under
-the License.
--->
-
-<% if (option.index === 0) {%>
-<th> <%= option.section %> </th>
-<% } else { %>
-<td></td>
-<% } %>
-<td> <%= option.name %> </td>
-<td>
- <div id="show-value">
- <%= option.value %> <button class="edit-button"> Edit </button>
- </div>
- <div id="edit-value-form" style="display:none">
- <input class="value-input" type="text" value="<%= option.value %>" />
- <button id="save-value" class="btn btn-success btn-small"> Save </button>
- <button id="cancel-value" class="btn btn-danger btn-small"> Cancel </button>
- </div>
-</td>
-<td id="delete-value"> <i class="icon-trash"> </i> </td>
http://git-wip-us.apache.org/repos/asf/couchdb/blob/4615a788/src/fauxton/app/addons/contribute/base.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/contribute/base.js b/src/fauxton/app/addons/contribute/base.js
deleted file mode 100644
index 8f622fe..0000000
--- a/src/fauxton/app/addons/contribute/base.js
+++ /dev/null
@@ -1,33 +0,0 @@
-// Licensed under the Apache License, Version 2.0 (the "License"); you may not
-// use this file except in compliance with the License. You may obtain a copy of
-// the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
-// WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
-// License for the specific language governing permissions and limitations under
-// the License.
-
-define([
- // Libraries.
- "jquery",
- "lodash"
-],
-function($, _){
- $.contribute = function(message, file){
- /*
- var JST = window.JST = window.JST || {};
- var template = JST['app/addons/contribute/templates/modal.html'];
- console.log(template);
- var compiled = template({message: message, file: file});
- */
- console.log('contribute!contribute!monorail!contribute!');
- /*
- console.log(compiled);
- var elem = $(compiled);
- elem.modal('show');
- */
- };
-});
http://git-wip-us.apache.org/repos/asf/couchdb/blob/4615a788/src/fauxton/app/addons/logs/base.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/logs/base.js b/src/fauxton/app/addons/logs/base.js
deleted file mode 100644
index c17e159..0000000
--- a/src/fauxton/app/addons/logs/base.js
+++ /dev/null
@@ -1,28 +0,0 @@
-// Licensed under the Apache License, Version 2.0 (the "License"); you may not
-// use this file except in compliance with the License. You may obtain a copy of
-// the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
-// WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
-// License for the specific language governing permissions and limitations under
-// the License.
-
-define([
- "app",
-
- "api",
-
- // Modules
- "addons/logs/routes"
-],
-
-function(app, FauxtonAPI, Log) {
- Log.initialize = function() {
- FauxtonAPI.addHeaderLink({title: "Log", href: "#_log"});
- };
-
- return Log;
-});
http://git-wip-us.apache.org/repos/asf/couchdb/blob/4615a788/src/fauxton/app/addons/logs/resources.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/logs/resources.js b/src/fauxton/app/addons/logs/resources.js
deleted file mode 100644
index d1e6d20..0000000
--- a/src/fauxton/app/addons/logs/resources.js
+++ /dev/null
@@ -1,225 +0,0 @@
-// Licensed under the Apache License, Version 2.0 (the "License"); you may not
-// use this file except in compliance with the License. You may obtain a copy of
-// the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
-// WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
-// License for the specific language governing permissions and limitations under
-// the License.
-
-define([
- "app",
- "api",
- "backbone"
-],
-
-function (app, FauxtonAPI, Backbone) {
-
- var Log = FauxtonAPI.addon();
-
- Log.Model = Backbone.Model.extend({
-
- date: function () {
- var date = new Date(this.get('date'));
-
- var formatted_time = date.getHours() + ":" + date.getMinutes() + ":" + date.getSeconds();
- var formatted_date = date.toDateString().slice(4, 10);
-
- return formatted_date + ' ' + formatted_time;
- },
-
- logLevel: function () {
- return this.get('log_level').replace(/ /g,'');
- },
-
- pid: function () {
- return _.escape(this.get('pid'));
- },
-
- args: function () {
- return _.escape(this.get('args'));
- }
-
- });
-
- Log.Collection = Backbone.Collection.extend({
- model: Log.Model,
-
- initialize: function (options) {
- this.params = {bytes: 5000};
- },
-
- url: function () {
- query = "?" + $.param(this.params);
- return app.host + '/_log' + query;
- },
-
- // override fetch because backbone expects json and couchdb sends text/html for logs,
- // I think its more elegant to set the dataType here than where ever fetch is called
- fetch: function (options) {
- options = options ? options : {};
-
- return Backbone.Collection.prototype.fetch.call(this, _.extend(options, {dataType: "html"}));
- },
-
- parse: function (resp) {
- var lines = resp.split(/\n/);
- return _.foldr(lines, function (acc, logLine) {
- var match = logLine.match(/^\[(.*?)\]\s\[(.*?)\]\s\[(.*?)\]\s(.*)/);
-
- if (!match) { return acc;}
-
- acc.push({
- date: match[1],
- log_level: match[2],
- pid: match[3],
- args: match[4]
- });
-
- return acc;
- }, []);
- }
- });
-
- Log.events = {};
- _.extend(Log.events, Backbone.Events);
-
- Log.Views.View = FauxtonAPI.View.extend({
- template: "addons/logs/templates/dashboard",
-
- initialize: function (options) {
- this.refreshTime = options.refreshTime || 5000;
-
- Log.events.on("log:filter", this.filterLogs, this);
- Log.events.on("log:remove", this.removeFilterLogs, this);
-
- this.filters = [];
- this.filteredCollection = new Log.Collection(this.collection.toJSON());
- this.collection.on("add", function () {
- this.createFilteredCollection();
- }, this);
- },
-
- serialize: function () {
- return { logs: this.filteredCollection};
- },
-
- afterRender: function () {
- this.startRefreshInterval();
- },
-
- cleanup: function () {
- this.stopRefreshInterval();
- },
-
- filterLogs: function (filter) {
- this.filters.push(filter);
- this.createFilteredCollection();
- },
-
- resetFilterCollectionAndRender: function (logs) {
- this.filteredCollection.reset(logs);
- this.render();
- },
-
- createFilteredCollection: function () {
- var self = this;
-
- var filtered = _.reduce(this.filters, function (logs, filter) {
-
- return _.filter(logs, function (log) {
- var match = false;
-
- _.each(log, function (value) {
- if (value.toString().match(new RegExp(filter))) {
- match = true;
- }
- });
- return match;
- });
-
-
- }, this.collection.toJSON(), this);
-
- this.resetFilterCollectionAndRender(filtered);
- },
-
- removeFilterLogs: function (filter) {
- this.filters.splice(this.filters.indexOf(filter), 1);
- this.createFilteredCollection();
- },
-
- startRefreshInterval: function () {
- var self = this;
-
- // Interval already set
- if (self.intervalId) { return ; }
-
- self.intervalId = setInterval(function () {
- self.collection.fetch();
- }, self.refreshTime);
-
- },
-
- stopRefreshInterval: function () {
- clearInterval(this.intervalId);
- }
- });
-
- Log.Views.FilterView = FauxtonAPI.View.extend({
- template: "addons/logs/templates/sidebar",
-
- events: {
- "submit #log-filter-form": "filterLogs"
- },
-
- filterLogs: function (event) {
- event.preventDefault();
- var $filter = this.$('input[name="filter"]'),
- filter = $filter.val();
-
- Log.events.trigger("log:filter", filter);
-
- this.insertView("#filter-list", new Log.Views.FilterItemView({
- filter: filter
- })).render();
-
- $filter.val('');
- }
-
- });
-
- Log.Views.FilterItemView = FauxtonAPI.View.extend({
- template: "addons/logs/templates/filterItem",
- tagName: "li",
-
- initialize: function (options) {
- this.filter = options.filter;
- },
-
- events: {
- "click .remove-filter": "removeFilter"
- },
-
- serialize: function () {
- return {
- filter: this.filter
- };
- },
-
- removeFilter: function (event) {
- event.preventDefault();
-
- Log.events.trigger("log:remove", this.filter);
- this.remove();
- }
-
- });
-
-
- return Log;
-
-});
http://git-wip-us.apache.org/repos/asf/couchdb/blob/4615a788/src/fauxton/app/addons/logs/routes.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/logs/routes.js b/src/fauxton/app/addons/logs/routes.js
deleted file mode 100644
index 4e04d08..0000000
--- a/src/fauxton/app/addons/logs/routes.js
+++ /dev/null
@@ -1,47 +0,0 @@
-// Licensed under the Apache License, Version 2.0 (the "License"); you may not
-// use this file except in compliance with the License. You may obtain a copy of
-// the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
-// WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
-// License for the specific language governing permissions and limitations under
-// the License.
-
-define([
- "app",
-
- "api",
-
- // Modules
- "addons/logs/resources"
-],
-
-function(app, FauxtonAPI, Log) {
-
- Log.Routes = {
- "_log": function() {
- var logs = new Log.Collection();
-
- return {
- layout: "with_sidebar",
- crumbs: [
- {"name": "Logs", "link": "_log"}
- ],
- views: {
- "#dashboard-content": new Log.Views.View({collection: logs}),
- "#sidebar-content": new Log.Views.FilterView({})
- },
- apiUrl: logs.url(),
- establish: function() {
- return [logs.fetch()];
- }
- };
- }
- };
-
- return Log;
-
-});
http://git-wip-us.apache.org/repos/asf/couchdb/blob/4615a788/src/fauxton/app/addons/logs/templates/dashboard.html
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/logs/templates/dashboard.html b/src/fauxton/app/addons/logs/templates/dashboard.html
deleted file mode 100644
index 14969c8..0000000
--- a/src/fauxton/app/addons/logs/templates/dashboard.html
+++ /dev/null
@@ -1,46 +0,0 @@
-<!--
-Licensed under the Apache License, Version 2.0 (the "License"); you may not
-use this file except in compliance with the License. You may obtain a copy of
-the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
-License for the specific language governing permissions and limitations under
-the License.
--->
-
- <h2> Couchdb Logs </h2>
- <table class="table table-bordered" >
- <thead>
- <tr>
- <th class="Date">Date</th>
- <th class="Log Level">Log Value</th>
- <th class="Pid">Pid</th>
- <th class="Args">Url</th>
- </tr>
- </thead>
-
- <tbody>
- <% logs.each(function (log) { %>
- <tr class="<%= log.logLevel() %>">
- <td>
- <!-- TODO: better format the date -->
- <%= log.date() %>
- </td>
- <td>
- <%= log.logLevel() %>
- </td>
- <td>
- <%= log.pid() %>
- </td>
- <td>
- <!-- TODO: split the line, maybe put method in it's own column -->
- <%= log.args() %>
- </td>
- </tr>
- <% }); %>
- </tbody>
-</table>
http://git-wip-us.apache.org/repos/asf/couchdb/blob/4615a788/src/fauxton/app/addons/logs/templates/filterItem.html
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/logs/templates/filterItem.html b/src/fauxton/app/addons/logs/templates/filterItem.html
deleted file mode 100644
index c4e885a..0000000
--- a/src/fauxton/app/addons/logs/templates/filterItem.html
+++ /dev/null
@@ -1,16 +0,0 @@
-<!--
-Licensed under the Apache License, Version 2.0 (the "License"); you may not
-use this file except in compliance with the License. You may obtain a copy of
-the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
-License for the specific language governing permissions and limitations under
-the License.
--->
-
-<span class="label label-info"> <%= filter %> </span>
-<a class="label label-info remove-filter" href="#">×</a>
http://git-wip-us.apache.org/repos/asf/couchdb/blob/4615a788/src/fauxton/app/addons/logs/templates/sidebar.html
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/logs/templates/sidebar.html b/src/fauxton/app/addons/logs/templates/sidebar.html
deleted file mode 100644
index 91822e0..0000000
--- a/src/fauxton/app/addons/logs/templates/sidebar.html
+++ /dev/null
@@ -1,27 +0,0 @@
-<!--
-Licensed under the Apache License, Version 2.0 (the "License"); you may not
-use this file except in compliance with the License. You may obtain a copy of
-the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
-License for the specific language governing permissions and limitations under
-the License.
--->
-
-<div id="log-sidebar">
- <form class="form-inline" id="log-filter-form">
- <fieldset>
- <legend>Log Filter</legend>
- <input type="text" name="filter" placeholder="Type a filter to sort the logs by">
- <!-- TODO: filter by method -->
- <!-- TODO: correct removed filter behaviour -->
- <button type="submit" class="btn">Filter</button>
- <span class="help-block"> <h6> Eg. debug or <1.4.1> or any regex </h6> </span>
- </fieldset>
- </form>
- <ul id="filter-list"></ul>
-</div>
http://git-wip-us.apache.org/repos/asf/couchdb/blob/4615a788/src/fauxton/app/addons/stats/assets/less/stats.less
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/stats/assets/less/stats.less b/src/fauxton/app/addons/stats/assets/less/stats.less
deleted file mode 100644
index 8c81f86..0000000
--- a/src/fauxton/app/addons/stats/assets/less/stats.less
+++ /dev/null
@@ -1,20 +0,0 @@
-/* Licensed under the Apache License, Version 2.0 (the "License"); you may not
- * use this file except in compliance with the License. You may obtain a copy of
- * the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
- * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
- * License for the specific language governing permissions and limitations under
- * the License.
- */
-
-.datatypes {
- border: #d3d3d3 1px solid;
- -webkit-border-radius: 5px;
- -moz-border-radius: 5px;
- border-radius: 5px;
- padding: 15px;
-}
http://git-wip-us.apache.org/repos/asf/couchdb/blob/4615a788/src/fauxton/app/addons/stats/base.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/stats/base.js b/src/fauxton/app/addons/stats/base.js
deleted file mode 100644
index 33316c4..0000000
--- a/src/fauxton/app/addons/stats/base.js
+++ /dev/null
@@ -1,28 +0,0 @@
-// Licensed under the Apache License, Version 2.0 (the "License"); you may not
-// use this file except in compliance with the License. You may obtain a copy of
-// the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
-// WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
-// License for the specific language governing permissions and limitations under
-// the License.
-
-define([
- "app",
- "api",
- "addons/stats/routes"
-],
-
-function(app, FauxtonAPI, AddonRoutes) {
- var Stats = new FauxtonAPI.addon();
-
- Stats.initialize = function() {
- FauxtonAPI.addHeaderLink({title: "Statistics", href: "#stats"});
- };
-
- Stats.Routes = AddonRoutes;
- return Stats;
-});
http://git-wip-us.apache.org/repos/asf/couchdb/blob/4615a788/src/fauxton/app/addons/stats/resources.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/stats/resources.js b/src/fauxton/app/addons/stats/resources.js
deleted file mode 100644
index 238a032..0000000
--- a/src/fauxton/app/addons/stats/resources.js
+++ /dev/null
@@ -1,37 +0,0 @@
-// Licensed under the Apache License, Version 2.0 (the "License"); you may not
-// use this file except in compliance with the License. You may obtain a copy of
-// the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
-// WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
-// License for the specific language governing permissions and limitations under
-// the License.
-
-define([
- "app",
- "api",
- "backbone",
- "lodash",
- "modules/fauxton/base"
-],
-
-function (app, FauxtonAPI, backbone, _, Fauxton) {
- var Stats = {};
-
- Stats.Collection = Backbone.Collection.extend({
- model: Backbone.Model,
- url: "/_stats",
- parse: function(resp) {
- return _.flatten(_.map(resp, function(doc, key) {
- return _.map(doc, function(v, k){
- return _.extend({id: k, type: key}, v);
- });
- }), true);
- }
- });
-
- return Stats;
-});
http://git-wip-us.apache.org/repos/asf/couchdb/blob/4615a788/src/fauxton/app/addons/stats/routes.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/stats/routes.js b/src/fauxton/app/addons/stats/routes.js
deleted file mode 100644
index 84947fa..0000000
--- a/src/fauxton/app/addons/stats/routes.js
+++ /dev/null
@@ -1,59 +0,0 @@
-// Licensed under the Apache License, Version 2.0 (the "License"); you may not
-// use this file except in compliance with the License. You may obtain a copy of
-// the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
-// WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
-// License for the specific language governing permissions and limitations under
-// the License.
-
-define([
- "app",
- "api",
- "addons/stats/resources",
- "addons/stats/views"
-],
-
-function(app, FauxtonAPI, Stats, Views) {
- var data = {
- stats: new Stats.Collection()
- };
-
- var deferred = FauxtonAPI.Deferred();
-
- var routeCallback = function() {
- return {
- layout: "with_sidebar",
-
- data: data,
-
- crumbs: [],
-
- views: {
- "#sidebar-content": new Views.StatSelect({
- collection: data.stats
- }),
-
- "#dashboard-content": new Views.Statistics({
- collection: data.stats
- })
- },
-
- establish: function() {
- return [data.stats.fetch()];
- },
-
- apiUrl: "_stats"
- };
- };
-
- Routes = {
- "stats": routeCallback,
- "_stats": routeCallback
- };
-
- return Routes;
-});
http://git-wip-us.apache.org/repos/asf/couchdb/blob/4615a788/src/fauxton/app/addons/stats/templates/by_method.html
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/stats/templates/by_method.html b/src/fauxton/app/addons/stats/templates/by_method.html
deleted file mode 100644
index 099d737..0000000
--- a/src/fauxton/app/addons/stats/templates/by_method.html
+++ /dev/null
@@ -1,16 +0,0 @@
-<!--
-Licensed under the Apache License, Version 2.0 (the "License"); you may not
-use this file except in compliance with the License. You may obtain a copy of
-the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
-License for the specific language governing permissions and limitations under
-the License.
--->
-
-<h2>By Method <small>GET, POST, PUT, DELETE</small></h2>
-<div id="httpd_request_methods"></div>