Jump to content

Karma/Bundle layout: Difference between revisions

From Sugar Labs
ChristophD (talk | contribs)
No edit summary
BryanWB (talk | contribs)
 
(58 intermediate revisions by 3 users not shown)
Line 1: Line 1:
== Karma activity bundle ==
== The Main Karma Package ==


'''consists of an HTML5 capable browser (activity) and a lesson bundle'''
''A set of tools that will help you start working with Karma quickly''


similar to E-Paath layout
This is what is contained in the repository at http://git.sugarlabs.org/projects/karma/


== Karma lesson bundle ==
* Includes script for Karma activity generation, xo bundle generation
* includes "platform" files, i.e. a basic html5-capable browser that can be used to create an xo bundle


'''consists of multiple lesson in a single bundle'''
ROOT/                              ( ROOT is not actually a directory name, it just labels the top-level of this package )
    assets/                        ( images, audio, and text common to karma.html, examples, and the lessons for the launch page for all lessons )
          image/
          audio/
          locale_name/
                    image/           
                    locale_name.json  ( karma actually needs the .po file to be converted to .json )
                    audio/
    AUTHORS                        ( Should include names of everyone that has contributed to Karma main package )
    css/                          ( css/ and js/ contain the code common to all examples, lessons )
    COPYING                        ( Licensing information, should default to MIT License  ? how distinguish b/w code licensing and content licensing )
    docs/
    examples/                      ( working examples of karma lessons )
    index.html                    ( The starting page for accessing Karma lessons, should include links to the examples, known as the CHAKRA )
    js/                            ( css/ and js/ contain the code common to all examples, lessons, and karma.html )
    README
    tests/                          unit tests


== Karma XO bundle ==
* similar to E-Paath layout and uses the standard [[Development_Team/Almanac/Activity_Bundles|Sugar bundle structure]]
* It is still undecided whether karma will default to using Browse which is based on Firefox or [http://dev.laptop.org/~bobbyp/surf/Surf-106.xo Surf] which based on webkit (Safari/Chrome). Surf requires that you install the rpms for pywebkitgtk and webkitgtk
The '''Below information is out-of-date'''
<strike>
  activity/
        activity.info                          (activity info file)
        activity-web.svg                      (icon for activity as specified in activity.info)
        mimetypes.xml                          (map documents to MIME types)
        text-plain.svg                        (icons for documents, e.g. "text-plain.svg" for "text/plain")
        text-html.svg
        contents                              (manifest for bundle contents)
        contents.sig                          (credentials for signed bundle)
        permissions.info                      (optional; '''not a stable API''')
  assets/
  AUTHORS
  bin/
        launch.sh                          (launcher script)
  browser.dtd
  browser.py
  cert8.db
  clickToView.xml
  COPYING
  css/
  downloadmanager.py
  edittoolbar.py
  globalhistory.py
  icons
  index.html
  js/
  linkbutton.py
  karma
  karmaactivity.py
  lessons/
  locale
  MANIFEST
  messenger.py
  model.py
  palettes.py
  places.py
  po/
  promptservice.py
  README
  securitydialogs.py
  sessionhistory.py
  sessionstore.py
  setup.py
  viewtoolbar.py
  utils/
  webtoolbar.py
</strike>
== Lesson ==
== Lesson ==


'''consists of a single lesson'''
''consists of a single lesson''
 
  lesson_name/
              assets/
                      {langCode}/        (files specific to langCode: en-US, en, es-MX, es, ....) and not the default locale
                      image/
                      audio/
                      svg/
                      video/
             
              css/
                    lesson.css
              index.html           
              js/
                  lesson.js      main logic of program
              kDoc.html  (viewer for lesson plan and teacher's Note)
              lessonPlan.html
              teachersNote.html
              start.html    (start page)
           
 
*Notes:
# {langCode} represents the lang code and country code
# which will be the template language for assets/docs/* ?, English suggested
# suggestion: rename assets/{langCode}/docs/ to docs/{langCode}/ . This is based that at this moment there are no other kind of files under assets/ than 'docs'
 
The following is out of date but kept for history
<strike>
 
== Reading, Game and Exercise ==
''consist of a single 'reading', 'game' or 'exercise' ''


  lesson_name/
{type}/
               index.html              # valid html5 -- markup only includes visual elements and links in other resources, no inline code or styling
               index.html              (valid html5 -- markup only includes visual elements and links in other resources, no inline code or styling )
               css/                     # css files  -- all control of presentation done in CSS
               css/{type}.css          ( css files  -- specific to the lesson )
                  karma.css            # default stylesheet for Karma
               js/{type}.js            ( javascript controlling logic for the lesson )
                  lesson_name.css      # custom stylesheet for lesson
               po/                      ( translation files )
               js/                     # javascript files
                   ne-NP.po            ( example translation file for Nepal - Nepali )
                  karma.js            # common javascript functions for a Karma lesson
                   sp-ES.po            ( example translation file for traditional Spanish )
                  jquery.js, jquery.growl.js    # utility functions from jQuery
                  {langCode}.po        ( translation file )
                  lesson_name.js      # javascript controlling logic for the lesson        
               po/                      # translation files
                   ne_NP.po            # example translation file for Nepal - Nepali
                   sp_ES.po            # example translation file for traditional Spanish
               assets/
               assets/
                    generic/          ( for language independent assets (e.g. arrows, background images, etc.) )
                        images/
                            preview.jpg  ( screenshot for Chakra  )
                        sounds/
                        videos/
                        docs/
                     ne/
                     ne/
                         images/
                         images/
                         audio/
                         sounds/
                        videos/
                         docs/
                         docs/
                            lesson plan?
                            teachers note?
                     en/
                     en/
                         images/
                         images/
                         audio/
                         sounds/
                        videos/
                        docs/
                    {langCode}/
                        images/
                        sounds/
                        videos/
                        docs/
* Notes
# {type} represents 'game' or 'exercise' or 'reading'
# does docs/ is used?
</stike>

Latest revision as of 23:55, 9 March 2010

The Main Karma Package

A set of tools that will help you start working with Karma quickly

This is what is contained in the repository at http://git.sugarlabs.org/projects/karma/

  • Includes script for Karma activity generation, xo bundle generation
  • includes "platform" files, i.e. a basic html5-capable browser that can be used to create an xo bundle
ROOT/                              ( ROOT is not actually a directory name, it just labels the top-level of this package )
   assets/                         ( images, audio, and text common to karma.html, examples, and the lessons for the launch page for all lessons )
          image/
          audio/
          locale_name/
                   image/            
                   locale_name.json   ( karma actually needs the .po file to be converted to .json )
                   audio/
   AUTHORS                         ( Should include names of everyone that has contributed to Karma main package )
   css/                           ( css/ and js/ contain the code common to all examples, lessons )
   COPYING                         ( Licensing information, should default to MIT License   ? how distinguish b/w code licensing and content licensing )
   docs/
   examples/                       ( working examples of karma lessons )
   index.html                     ( The starting page for accessing Karma lessons, should include links to the examples, known as the CHAKRA )
   js/                             ( css/ and js/ contain the code common to all examples, lessons, and karma.html )
   README
   tests/                          unit tests

Karma XO bundle

  • similar to E-Paath layout and uses the standard Sugar bundle structure
  • It is still undecided whether karma will default to using Browse which is based on Firefox or Surf which based on webkit (Safari/Chrome). Surf requires that you install the rpms for pywebkitgtk and webkitgtk

The Below information is out-of-date

 activity/
        activity.info                          (activity info file)
        activity-web.svg                       (icon for activity as specified in activity.info)
        mimetypes.xml                          (map documents to MIME types)
        text-plain.svg                         (icons for documents, e.g. "text-plain.svg" for "text/plain")
        text-html.svg
        contents                               (manifest for bundle contents)
        contents.sig                           (credentials for signed bundle)
        permissions.info                       (optional; not a stable API)
 assets/
 AUTHORS
 bin/
        launch.sh                           (launcher script)
 browser.dtd
 browser.py
 cert8.db
 clickToView.xml
 COPYING
 css/
 downloadmanager.py
 edittoolbar.py
 globalhistory.py
 icons
 index.html
 js/
 linkbutton.py
 karma
 karmaactivity.py
 lessons/
 locale
 MANIFEST
 messenger.py
 model.py
 palettes.py
 places.py
 po/ 
 promptservice.py
 README
 securitydialogs.py
 sessionhistory.py
 sessionstore.py
 setup.py
 viewtoolbar.py
 utils/
 webtoolbar.py

Lesson

consists of a single lesson

  lesson_name/
             assets/
                     {langCode}/         (files specific to langCode: en-US, en, es-MX, es, ....) and not the default locale
                     image/
                     audio/
                     svg/
                     video/
             
             css/
                    lesson.css
             index.html             
             js/
                 lesson.js      main logic of program
             kDoc.html   (viewer for lesson plan and teacher's Note)
             lessonPlan.html
             teachersNote.html
             start.html     (start page)
            
  • Notes:
  1. {langCode} represents the lang code and country code
  2. which will be the template language for assets/docs/* ?, English suggested
  3. suggestion: rename assets/{langCode}/docs/ to docs/{langCode}/ . This is based that at this moment there are no other kind of files under assets/ than 'docs'

The following is out of date but kept for history

Reading, Game and Exercise

consist of a single 'reading', 'game' or 'exercise'

{type}/
             index.html               (valid html5 -- markup only includes visual elements and links in other resources, no inline code or styling )
             css/{type}.css           ( css files   -- specific to the lesson )
             js/{type}.js             ( javascript controlling logic for the lesson )
             po/                      ( translation files )
                 ne-NP.po             ( example translation file for Nepal - Nepali )
                 sp-ES.po             ( example translation file for traditional Spanish )
                 {langCode}.po        ( translation file )
             assets/
                    generic/          ( for language independent assets (e.g. arrows, background images, etc.) )
                       images/
                           preview.jpg  ( screenshot for Chakra  )
                       sounds/
                       videos/
                       docs/
                    ne/
                       images/
                       sounds/
                       videos/
                       docs/
                    en/
                       images/
                       sounds/
                       videos/
                       docs/
                    {langCode}/
                       images/
                       sounds/
                       videos/
                       docs/
  • Notes
  1. {type} represents 'game' or 'exercise' or 'reading'
  2. does docs/ is used?

</stike>