Skip to content

Instantly share code, notes, and snippets.

#!/usr/bin/python
# -*- coding: utf-8 -*-
"""
EXTRA TASK
==============
* nur cod zeilen (und nachfolgende) und außerung darüber, alles andere löschen.
* alles in ein file, headers per file

This is a very short tutorial on how to install and start using RingoJS.

Which Version

We try to release often - at least every 2 months - but Ringo is moving fast and with the git version you will always get the newest features. All Ringo developers use the git version for their projects and the git master is usually very stable.

But, using the most recent git version means you should keep an eye on the Ringo [mailing list][group] - big changes that might break your code will be discussed on the list beforehand.

// in apps/ringojs.org/
include('./config');
include('./jsdoc/doc');
renderRepository(webHookConfig.jsdoc.repository, webHookConfig.jsdoc.exportDirectory);
RingoJs
Ease of use
+ Easy deployment (as deb or to appengine)
+ REPL with auto-completion & history
+ Mostly implemented in JS (ongoing effort)
+ Jetty webserver (out-of-box serving)
+ Graphical debugger
o API docs, open Wiki (still a lot missing)
- ...
var signpost = Packages.oauth.signpost;
// app keys
var CONSUMER_KEY = 'KKKKKKKKKKKKKKKKKEY';
var CONSUMER_SECRET = 'SEEEEEEEEEEEECRET';
// user keys - we got those earlier with provider.retrieveAccessToken
var ACCESS_TOKEN = 'TOOOOOOOOKEN';
var TOKEN_SECRET = 'SEEEEEEEEEECRET';
// create a consumer object and configure it with the access
/**
* @fileOverview
*
* Montage single sprite images from Reiner's Tileset into a single spritemap.
*
* Every Sprite has multiple images: one per animation (e.g., walk, shoot, etc).
* Each row of the spritemap corresponds to a direction (n,s,w) in alphabetical order.
* The columns are the steps of a particular animation for a direction.
*
* requires ImageMagick
{{ infobox software
| name = RingoJs
| logo = [[File:RingoJs.png|150px|RingoJs Logo]]
| screenshot =
| caption =
| author = Hannes Wallnöfer
| developer = [http://ringojs.org/wiki/Contributors/ RingoJs Developers]
| operating system = [[Mac OS X]], [[Linux]], [[Solaris (operating system)|Solaris]], [[FreeBSD]], [[OpenBSD]], [[Windows]], [[webOS]]
| status = Active
| released =
var YUIC = com.yahoo.platform.yui.compressor;
var YUIJ = com.yahoo.platform.yui.org.mozilla.javascript;
var fakeOutStream = new Packages.java.io.Writer({
data: [],
write : function(text) { this.data.push(text);},
readAll : function() { return this.data.join("\n\n");},
});
var errorReporter = new YUIJ.ErrorReporter({
/*
// compressed
Server=require("ringo/httpserver").Server;a=require("stick").Application();a.configure("route");a.get("/",function(){return{status:200,headers:{},body:["hello world"]}});(new Server({app:a})).start();
*/
// less compressed
var Server = require("ringo/httpserver").Server;
var app = require('stick').Application();
app.configure("route");
app.get('/', function() {
@oberhamsi
oberhamsi / dersoldat.main.js
Created December 20, 2010 14:15
dersoldat gamejs file
var gamejs = require('gamejs');
var $v = require('gamejs/utils/vectors');
function main() {
gamejs.display.setCaption("Der Soldat");
// create background
var screen = gamejs.display.setMode([850, 500]);
var displayRect = screen.rect;
var bg = gamejs.image.load('images/ground.png');