horizon/horizon/utils
Shaoquan Chen 018b39b84a Utils for auto-file-discovery
This patch creates horizon.utils.file-discovery module which provides
functionalities for automatic file-discovery.  With these infrastructural
helpers, we can build JavaScript and HTML file auto-discovery for horizon
align with th existing plug-in mechanism.

1) discover_files(base_path, sub_path='', ext='', trim_base_path=False):
   Discover all files with certain extension in given paths

2) sort_js_files(js_files):
   Sorts JavaScript files in `js_files` into source files, mock files
   and spec files based on file extension.

   Output:
   * sources: source files for production.  The order of source files
     is significant and should be listed in the below order:
     - First all the files that defines application's angular module.
       Those files have extension of `.module.js`.  The order among them
       is not significant.
     - Followed by all other source code files.  The order among them
       is not significant.

   * mocks: mock files provide mock data/services for tests.  They have
     extension of `.mock.js`. The order among them is not significant.

   * specs: spec files for testing.  They have extension of `.spec.js`.
     The order among them is not significant.

3) discover_static_files(base_path, sub_path=''):
   Discover static files in given paths, returns JavaScript sources,
   mocks, specs and HTML templates files grouped in lists.

Partially-Implements: blueprint auto-js-file-finding
Change-Id: Idd0b69451f81b2f740b10515e3e274d48b681dbe
2015-06-15 23:59:00 -07:00
..
__init__.py Unifies the project packaging into one set of modules. 2012-02-29 00:20:13 -08:00
csvbase.py Remove NotImplementedErrors from "virtual" methods 2014-09-02 11:31:05 +02:00
file_discovery.py Utils for auto-file-discovery 2015-06-15 23:59:00 -07:00
filters.py Remove extraneous vim configuration comments 2014-05-06 15:30:10 +08:00
functions.py Replaced hard coded values with oslo_utils.units constants 2015-02-27 14:49:32 -05:00
html.py Allow access to HTML final class string 2014-08-11 18:19:27 +00:00
memoized.py Invalid instance_snapshot causes KeyError 2014-10-28 15:51:33 -04:00
secret_key.py Replace lockfile by oslo_concurrency 2015-01-26 16:53:43 +01:00
units.py Update metering unit selection to use smaller units for time 2014-11-19 20:44:43 -06:00
urlresolvers.py Remove the urlquote to arguments passed to reverse 2014-09-05 10:47:21 -04:00
validators.py Move validate_metadata to utils/validators 2015-05-31 09:26:52 +08:00