diff --git a/README b/README index cd54b60..cd6d6a6 100644 --- a/README +++ b/README @@ -15,16 +15,12 @@ In order to make use of this application you will need: * A database supported by Django (SQLite, MySQL, etc.). Django takes care of creating the database itself, you just need to ensure that the database server (if not using SQLite) is configured and running. -* On the machine that will run the update script (which does not have to - be the same machine as the web server, however it does still have to - have Django installed and have access to the database used by the web +* On the machine that will run the backend update script (which does not + have to be the same machine as the web server, however it does still + have to have Django installed, have the same or similar configuration + in settings.py and have access to the database used by the web application): * Python 2.6 or Python 2.7 - * A copy of BitBake and OE-Core (or Poky, which includes both) - - the "danny" release or newer is required. It does not need to be - configured specially nor do all of the normal pre-requisites need to - be installed (it is only used for parsing recipes, not actual - building). * GitPython (python-git) version 0.3.1 or later * django-registration * django-reversion @@ -43,31 +39,45 @@ Setup instructions: python manage.py syncdb + You should answer "yes" when asked to create an admin account. + 3. You can test the web application locally by setting DEBUG = True in settings.py and running the following: python manage.py runserver - Then visit http://127.0.0.1:8000/layerindex/ with your browser. This - should only be used for testing - for production you need to use a - proper web server and have DEBUG set to False. + Then visit http://127.0.0.1:8000/layerindex/ with your browser. As + with all Django applications there is an admin interface available + at http://127.0.0.1:8000/admin/ also. -4. You may wish to customise layerindex/about.html to suit your + NOTE: This local server should only be used for testing - for + production you need to use a proper web server and have DEBUG set + to False. + +4. You'll need to add at least the openembedded-core layer to the + database (or some equivalent for use in basic BitBake configuration; + if it's not called "openembedded-core" then you'll need to set + CORE_LAYER_NAME in settings.py to match.) You can use the + "Submit Layer" feature within the interface itself (easiest) or the + admin interface to do this. + +5. You may wish to customise layerindex/about.html to suit your installation. Usage ----- -On a regular basis you need to run the update script within an -environment set up for OE-Core build: +On a regular basis you need to run the update script: -$ cd path/to/oe-core -$ . ./oe-init-build-env -$ path/to/layerindex/update.py +path/to/layerindex/update.py This will fetch all of the layer repositories, analyse their contents -and update the database with the results. +and update the database with the results. Note that if you set up more +than just the master branch in the database, you will need to run the +script once for each branch using -b (or --branch) to specify the +branch name. Run the script with --help for further information on +available options. Maintenance diff --git a/base.html b/base.html index ac9beef..75871fe 100644 --- a/base.html +++ b/base.html @@ -30,6 +30,25 @@
OpenEmbedded metadata index +
+ {% if not layerbranch %} +
+
+ This layer does not exist for branch {{ current_branch }}. +
+
+ {% endif %}
{% for note in layeritem.layernote_set.all %}
@@ -95,24 +102,25 @@ {% if layeritem.vcs_subdir %}

Subdirectory

{{ layeritem.vcs_subdir }} - {% if layeritem.tree_url %} + {% if layerbranch.tree_url %} - web subdirectory + web subdirectory {% endif %}

{% endif %} - {% if layeritem.vcs_last_commit %} + {% if layerbranch.vcs_last_commit %}

- Last commit: {{ layeritem.vcs_last_commit|timesince }} ago + Last commit: {{ layerbranch.vcs_last_commit|timesince }} ago

{% endif %} -

{% if layeritem.active_maintainers|length = 1 %}Maintainer{% else %}Maintainers{% endif %}

+ {% if layerbranch.active_maintainers.count > 0 %} +

{% if layerbranch.active_maintainers|length = 1 %}Maintainer{% else %}Maintainers{% endif %}

    - {% for maintainer in layeritem.active_maintainers %} + {% for maintainer in layerbranch.active_maintainers %}
  • {{ maintainer.name }} {% if maintainer.responsibility %} @@ -125,16 +133,17 @@
  • {% endfor %}
+ {% endif %}
- {% if layeritem.dependencies_set.all %} + {% if layerbranch.dependencies_set.count > 0 %}

Dependencies

The {{ layeritem.name }} layer depends upon:

    - {% for dep in layeritem.dependencies_set.all %} + {% for dep in layerbranch.dependencies_set.all %}
  • {{ dep.dependency.name }}
  • {% endfor %}
@@ -145,11 +154,11 @@
- {% if layeritem.status = 'N' %} + {% if layeritem.status = 'N' and layerbranch %}
{% if layeritem.vcs_web_file_base_url %} - test file link + test file link {% else %} @@ -158,7 +167,7 @@ {% endif %} {% if layeritem.vcs_web_tree_base_url %} - test tree link + test tree link {% else %} @@ -167,7 +176,7 @@ {% endif %}
{% else %} - {% if layeritem.machine_set.count > 0 %} + {% if layerbranch.machine_set.count > 0 %}