Giter VIP home page Giter VIP logo

scorm's Introduction

SCORM is a Ruby library for reading and extracting Shareable Content Object Reference Model (SCORM) files. SCORM is a standardized package format used mainly by e-learning software to help with the exchange of course material between systems in an interoperable way. This gem supports SCORM 1.2 and SCORM 2004.

The gem can both be used as a library in your application or as a command line tool. This gem does NOT handle the run-time part of the SCORM standard, only the so called "Content Aggregation Model".

Usage

create <name>               # create a new package skeleton
bundle [<path to directory>]# creates a package from the current directory
check <path to zip file>    # runs a test suite against your package
extract <path to zip file>  # extracts and checks the specified package

Example Workflow

scorm create mypackage        # Create a new package skeleton
cd mypackage                  # 
scorm bundle                  # Create .zip file from current directory
scorm check mypackage.zip     # Verify that the package is valid SCORM
scorm extract mypackage.zip   # Extract the mypackage.zip package

Installation

gem install scorm

To use the SCORM gem as a library in your application to extract and read SCORM files you can simply require the 'scorm/package' file.

require 'scorm/package'

Scorm::Package.open('mypackage.zip') do |pkg|
  # Read stuff from the package...
  puts pkg.manifest.identifier
  puts pkg.manifest.default_organization.title
  puts pkg.manifest.metadata.general.title.value
  pkg.manifest.resources.each do |resource|
    puts resource.href
    puts resource.scorm_type
    if pkg.exists?(resource.files.first)
      puts resource.files.first
      puts pkg.file(resource.files.first)
    end
  end
  # etc...
end

See the RDOC documentation for more info about what you can read from the package manifest.

About

Created and maintained by Niklas Holmgren. Released under the MIT license. http://github.com/mindset/scorm

scorm's People

Watchers

Murat GUZEL avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.