Skip to content

Instantly share code, notes, and snippets.

@viblo
viblo / Character.py
Last active December 10, 2015 22:49 — forked from desophos/Character.py
import sys
sys.path.insert(0,'''../pymunk/trunk''')
from Gun import Gun
from globals import *
import pygame
import pymunk
class Character(pygame.sprite.Sprite):
@viblo
viblo / gist:7407666
Created November 11, 2013 04:06
swagger models problem
package main
import (
"log"
"net/http"
"github.com/emicklei/go-restful"
"github.com/emicklei/go-restful/swagger"
)
type User struct {
@viblo
viblo / gist:7409083
Last active December 27, 2015 23:49
global response object with swagger
package main
import (
"log"
"net/http"
"github.com/emicklei/go-restful"
"github.com/emicklei/go-restful/swagger"
)
"""This module contain functions used to load the chipmunk dll/lib file"""
__version__ = "$Id$"
import os.path
import platform
import sys, imp, os
import ctypes
def platform_specific_functions():
# use stddecl on windows, cdecl on all other platforms
import time
import pyglet
import pymunk
import pymunk.pyglet_util
import sys
window = pyglet.window.Window(width = 800, height = 600)
space = pymunk.Space()
space.gravity = 0, -980
import os, os.path
import platform
import sys
from distutils.command.build_ext import build_ext
import distutils.ccompiler as cc
from setuptools import Extension
from setuptools import setup
def get_arch():
@viblo
viblo / __init__.py
Last active February 25, 2017 16:20
pymunk p4a recipe
from pythonforandroid.toolchain import PythonRecipe
from pythonforandroid.recipe import CompiledComponentsPythonRecipe
import os.path
class PymunkRecipe(CompiledComponentsPythonRecipe):
name = "pymunk"
version = '5.1.0'
url = 'https://pypi.python.org/packages/6e/c3/ac05e3309dc4b4a2f450822fa0de569bf5fe40f57a56e009319f99636955/pymunk-{version}.zip'
@viblo
viblo / run.bat
Last active June 27, 2018 15:30
Metabase config for Azure web app
set MB_JETTY_PORT=%MB_JETTY_PORT: =%
"%JAVA_HOME%\bin\java.exe" -Djava.net.preferIPv4Stack=true -jar ./metabase.jar
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
from os.path import join
from pythonforandroid.recipe import CompiledComponentsPythonRecipe
class PymunkRecipe(CompiledComponentsPythonRecipe):
name = "pymunk"
version = "6.0.0"
url = "https://pypi.python.org/packages/source/p/pymunk/pymunk-{version}.zip"
depends = ["cffi", "setuptools"]