repo_name stringlengths 5 100 | ref stringlengths 12 67 | path stringlengths 4 244 | copies stringlengths 1 8 | content stringlengths 0 1.05M ⌀ |
|---|---|---|---|---|
danielvdao/facebookMacBot | refs/heads/master | venv/lib/python2.7/site-packages/sleekxmpp/plugins/xep_0279/stanza.py | 13 | """
SleekXMPP: The Sleek XMPP Library
Copyright (C) 2012 Nathanael C. Fritz, Lance J.T. Stout
This file is part of SleekXMPP.
See the file LICENSE for copying permission.
"""
from sleekxmpp.xmlstream import ElementBase
class IPCheck(ElementBase):
name = 'ip'
namespace = 'urn:xmpp:sic:0'
... |
jelugbo/hebs_repo | refs/heads/master | common/lib/xmodule/xmodule/foldit_module.py | 56 | import logging
from lxml import etree
from pkg_resources import resource_string
from xmodule.editing_module import EditingDescriptor
from xmodule.x_module import XModule
from xmodule.xml_module import XmlDescriptor
from xblock.fields import Scope, Integer, String
from .fields import Date
from .util.duedate import get... |
Pluto-tv/chromium-crosswalk | refs/heads/master | chrome/test/chromedriver/chrome_paths.py | 118 | # Copyright (c) 2012 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
"""Paths to common resources in the Chrome repository."""
import os
_THIS_DIR = os.path.abspath(os.path.dirname(__file__))
def GetSrc():
"""Return... |
maikelvl/django-boilerplate | refs/heads/master | src/main/templatetags/mathtags.py | 3 | from math import ceil
from django import template
register = template.Library()
@register.filter("mult", is_safe=False)
def mult(value, arg):
"""Multiplies the arg and the value"""
return float(value) * int(arg)
@register.filter("sub", is_safe=False)
def sub(value, arg):
"""Subtracts the arg from the v... |
xiaojunwu/crosswalk-test-suite | refs/heads/master | webapi/tct-csp-w3c-tests/csp-py/csp_font-src_cross-origin_allowed-manual.py | 30 | def main(request, response):
import simplejson as json
f = file('config.json')
source = f.read()
s = json.JSONDecoder().decode(source)
url1 = "http://" + s['host'] + ":" + str(s['ports']['http'][1])
_CSP = "font-src " + url1
response.headers.set("Content-Security-Policy", _CSP)
response.... |
mecwerks/fofix | refs/heads/master | src/views/MainMenu/MainMenu.py | 3 | #####################################################################
# -*- coding: iso-8859-1 -*- #
# #
# Frets on Fire #
# Copyright (C) 2006 Sami Ky�stil� ... |
ceache/treadmill | refs/heads/master | lib/python/treadmill/sproc/presence.py | 2 | """Runs Treadmill application register daemon.
"""
# TODO: it no longer registers anything, just refreshes tickets. Need to
# rename.
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from __future__ import unicode_literals
import logging
import os
imp... |
tinfoil/phantomjs | refs/heads/master | src/breakpad/src/tools/gyp/test/actions/src/subdir2/make-file.py | 973 | #!/usr/bin/env python
# Copyright (c) 2009 Google Inc. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import sys
contents = "Hello from make-file.py\n"
open(sys.argv[1], 'wb').write(contents)
|
TalShafir/ansible | refs/heads/devel | lib/ansible/utils/module_docs_fragments/decrypt.py | 43 | # (c) 2017, Brian Coca <bcoca@redhat.com>
#
# This file is part of Ansible
#
# Ansible is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
... |
kartikluke/cron | refs/heads/master | lib/flask/testsuite/test_apps/flaskext/__init__.py | 12133432 | |
iambibhas/django | refs/heads/master | tests/test_utils/__init__.py | 12133432 | |
supergis/micropython | refs/heads/master | tests/basics/getattr.py | 100 | # test __getattr__
class A:
def __init__(self, d):
self.d = d
def __getattr__(self, attr):
return self.d[attr]
a = A({'a':1, 'b':2})
print(a.a, a.b)
|
EWol234/osmc | refs/heads/master | package/mediacenter-skin-osmc/files/usr/share/kodi/addons/script.module.unidecode/lib/unidecode/x0af.py | 253 | data = (
'ggyeols', # 0x00
'ggyeolt', # 0x01
'ggyeolp', # 0x02
'ggyeolh', # 0x03
'ggyeom', # 0x04
'ggyeob', # 0x05
'ggyeobs', # 0x06
'ggyeos', # 0x07
'ggyeoss', # 0x08
'ggyeong', # 0x09
'ggyeoj', # 0x0a
'ggyeoc', # 0x0b
'ggyeok', # 0x0c
'ggyeot', # 0x0d
'ggyeop', # 0x0e
'ggy... |
jhbradley/moose | refs/heads/devel | python/ClusterLauncher/PBSJob.py | 7 | from FactorySystem import InputParameters
from Job import Job
import os, sys, subprocess, shutil, re
class PBSJob(Job):
def validParams():
params = Job.validParams()
params.addRequiredParam('chunks', "The number of PBS chunks.")
# Only one of either of the next two paramteres can be specified
param... |
ride90/Booktype | refs/heads/master | lib/booktype/apps/core/templatetags/__init__.py | 12133432 | |
viki9698/jizhanggroup | refs/heads/master | django/conf/locale/nl/__init__.py | 12133432 | |
mihaisoloi/conpaas | refs/heads/master | conpaas-services/src/conpaas/core/clouds/__init__.py | 12133432 | |
mickelangelo/carve | refs/heads/master | regression/compare_runs.py | 5 | import sys
import os
import sre
from sets import Set
output = sre.compile(r"test_(.*).out")
RUN_1_DIR = sys.argv[1]
RUN_2_DIR = sys.argv[2]
run_1_files = os.listdir(RUN_1_DIR)
run_2_files = os.listdir(RUN_2_DIR)
tests_1 = []
tests_2 = []
for _ in run_1_files:
m = output.match(_)
if m is None: continue
tests... |
echoi/snac_bmi | refs/heads/master | pythia-0.8/packages/pyre/pyre/__init__.py | 2 | #!/usr/bin/env python
#
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#
# Michael A.G. Aivazis
# California Institute of Technology
# (C) 1998-2005 All Rights Reserved
#
# {LicenseText}
#
# ~~~~~~~~~~~~~~~~~~~~~~~~... |
piasek1906/Piasek-KK | refs/heads/master | tools/perf/scripts/python/sched-migration.py | 11215 | #!/usr/bin/python
#
# Cpu task migration overview toy
#
# Copyright (C) 2010 Frederic Weisbecker <fweisbec@gmail.com>
#
# perf script event handlers have been generated by perf script -g python
#
# This software is distributed under the terms of the GNU General
# Public License ("GPL") version 2 as published by the Fre... |
Ingenico-ePayments/connect-sdk-python2 | refs/heads/master | ingenico/connect/sdk/domain/payment/definitions/payment_product840_customer_account.py | 2 | # -*- coding: utf-8 -*-
#
# This class was auto-generated from the API references found at
# https://epayments-api.developer-ingenico.com/s2sapi/v1/
#
from ingenico.connect.sdk.data_object import DataObject
class PaymentProduct840CustomerAccount(DataObject):
"""
| PayPal account details as returned by PayPal
... |
SweetheartSquad/REST-Services | refs/heads/master | scenarioEditor/forms.py | 2 | from django import forms
from api.models import ComponentSet, Asset, TriggerArgument
from django.core.exceptions import ValidationError
class TagField(forms.CharField):
def clean(self, value):
try:
if value is not None:
return value.split(",")
return ""
exce... |
Magicking/pycoin | refs/heads/master | pycoin/tx/pay_to/ScriptPayToPublicKey.py | 4 | from ..script import tools
from ... import encoding
from ...networks import address_prefix_for_netcode
from ...serialize import b2h
from ..exceptions import SolvingError
from .ScriptType import ScriptType
class ScriptPayToPublicKey(ScriptType):
"""
This is generally used in coinbase transactions only.
... |
WindCanDie/spark | refs/heads/master | sql/hive/src/test/resources/data/scripts/escapedcarriagereturn.py | 131 | #
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not u... |
victorbergelin/scikit-learn | refs/heads/master | examples/cluster/plot_feature_agglomeration_vs_univariate_selection.py | 218 | """
==============================================
Feature agglomeration vs. univariate selection
==============================================
This example compares 2 dimensionality reduction strategies:
- univariate feature selection with Anova
- feature agglomeration with Ward hierarchical clustering
Both metho... |
squarewave24/rafalbuch.com | refs/heads/master | node_modules/grunt-docker/node_modules/docker/node_modules/pygmentize-bundled/vendor/pygments/pygments/formatters/latex.py | 264 | # -*- coding: utf-8 -*-
"""
pygments.formatters.latex
~~~~~~~~~~~~~~~~~~~~~~~~~
Formatter for LaTeX fancyvrb output.
:copyright: Copyright 2006-2013 by the Pygments team, see AUTHORS.
:license: BSD, see LICENSE for details.
"""
from pygments.formatter import Formatter
from pygments.token import T... |
davenpcj5542009/eucalyptus | refs/heads/testing | clc/eucadmin/eucadmin/describeclusters.py | 7 | # Copyright 2011-2012 Eucalyptus Systems, Inc.
#
# Redistribution and use of this software in source and binary forms,
# with or without modification, are permitted provided that the following
# conditions are met:
#
# Redistributions of source code must retain the above copyright notice,
# this list of conditions ... |
CARocha/asocam | refs/heads/master | asocam/wsgi.py | 1 | """
WSGI config for asocam project.
This module contains the WSGI application used by Django's development server
and any production WSGI deployments. It should expose a module-level variable
named ``application``. Django's ``runserver`` and ``runfcgi`` commands discover
this application via the ``WSGI_APPLICATION`` s... |
163gal/Time-Line | refs/heads/master | autopilot/autopilotlib/instructions/__init__.py | 12133432 | |
froyobin/horizon | refs/heads/our_branch | openstack_dashboard/dashboards/project/volumes/volumes/__init__.py | 12133432 | |
zdary/intellij-community | refs/heads/master | python/helpers/pycharm/django_manage.py | 21 | #!/usr/bin/env python
import os
import sys
from _jb_utils import FileChangesTracker, jb_escape_output
from fix_getpass import fixGetpass
from pycharm_run_utils import adjust_django_sys_path
try:
from runpy import run_module
except ImportError:
from runpy_compat import run_module
adjust_django_sys_path()
base... |
supersven/intellij-community | refs/heads/master | python/testData/completion/isInstanceAssert.after.py | 83 | class Foo:
def xyzzy(self): pass
def bar(): pass
f = bar()
assert isinstance(f, Foo)
f.xyzzy() |
RPI-OPENEDX/edx-platform | refs/heads/RPI-DEV | common/djangoapps/xblock_django/__init__.py | 12133432 | |
lepistone/odoo | refs/heads/master | addons/web_calendar/__init__.py | 12133432 | |
jylaxp/django | refs/heads/master | tests/project_template/views.py | 1387 | from django.http import HttpResponse
def empty_view(request, *args, **kwargs):
return HttpResponse('')
|
xwolf12/django | refs/heads/master | tests/migrations/test_migrations_run_before/__init__.py | 12133432 | |
vaygr/ansible | refs/heads/devel | lib/ansible/modules/database/vertica/__init__.py | 12133432 | |
pcm17/tensorflow | refs/heads/master | tensorflow/examples/learn/iris_with_pipeline.py | 62 | # Copyright 2016 The TensorFlow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by appl... |
bewiwi/sauna | refs/heads/master | sauna/plugins/ext/memory.py | 2 | from sauna.plugins.base import PsutilPlugin
from sauna.plugins import human_to_bytes, bytes_to_human, PluginRegister
my_plugin = PluginRegister('Memory')
@my_plugin.plugin()
class Memory(PsutilPlugin):
def __init__(self, config):
super().__init__(config)
self._virtual_memory = None
self.... |
EliotBerriot/django | refs/heads/master | django/contrib/admindocs/utils.py | 411 | "Misc. utility functions/classes for admin documentation generator."
import re
from email.errors import HeaderParseError
from email.parser import HeaderParser
from django.core.urlresolvers import reverse
from django.utils.encoding import force_bytes
from django.utils.safestring import mark_safe
try:
import docut... |
cnsoft/kbengine-cocos2dx | refs/heads/cocos2dx-cnsoft | kbe/src/lib/python/Lib/lib2to3/pgen2/__init__.py | 655 | # Copyright 2004-2005 Elemental Security, Inc. All Rights Reserved.
# Licensed to PSF under a Contributor Agreement.
"""The pgen2 package."""
|
knehez/edx-platform | refs/heads/memooc | lms/djangoapps/certificates/migrations/0014_adding_whitelist.py | 188 | # -*- coding: utf-8 -*-
import datetime
from south.db import db
from south.v2 import SchemaMigration
from django.db import models
class Migration(SchemaMigration):
def forwards(self, orm):
# Adding model 'CertificateWhitelist'
db.create_table('certificates_certificatewhitelist', (
('i... |
jason-weirather/Au-public | refs/heads/master | iron/utilities/optimize_qc.py | 2 | #!/usr/bin/python
import sys, os, subprocess, multiprocessing, re, zlib, argparse
import SamBasics
from SequenceBasics import GenericFastqFileReader, read_fasta_into_hash
from random import randint
from shutil import rmtree
# Test qc decisions on a fastq file for parameters such as
# (1) Left trim
# (2) Right trim
# (... |
gannetson/django | refs/heads/master | tests/migrations/test_base.py | 292 | import os
import shutil
import tempfile
from contextlib import contextmanager
from importlib import import_module
from django.apps import apps
from django.db import connection
from django.db.migrations.recorder import MigrationRecorder
from django.test import TransactionTestCase
from django.test.utils import extend_sy... |
pombo-lab/gamtools | refs/heads/master | lib/gamtools/tests/test_call_windows.py | 1 | import io
import pytest
from numpy.testing import assert_array_equal
import numpy as np
from gamtools import call_windows, segregation
fixture_two_samples = io.StringIO(
u"""chrom start stop Sample_A Sample_B
chr1 0 50000 4 0
chr1 50000 100000 0 5
chr1 100000 150000 3 0
chr1 150000... |
camradal/ansible | refs/heads/devel | lib/ansible/modules/cloud/cloudstack/cs_affinitygroup.py | 48 | #!/usr/bin/python
# -*- coding: utf-8 -*-
#
# (c) 2015, René Moser <mail@renemoser.net>
#
# This file is part of Ansible
#
# Ansible is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the Lice... |
yqian1991/Django | refs/heads/master | django-articles/articles/urls.py | 5 | from django.conf.urls.defaults import *
from articles import views
from articles.feeds import TagFeed, LatestEntries, TagFeedAtom, LatestEntriesAtom
tag_rss = TagFeed()
latest_rss = LatestEntries()
tag_atom = TagFeedAtom()
latest_atom = LatestEntriesAtom()
urlpatterns = patterns('',
(r'^(?P<year>\d{4})/(?P<month... |
smmribeiro/intellij-community | refs/heads/master | python/testData/inspections/RemoveUnsupportedPrefixFromGluedStringNodesWithSlash_after.py | 79 | s = "string\n" \
"next line" |
divya-csekar/flask-microblog-server | refs/heads/master | flask/Lib/site-packages/flask_wtf/recaptcha/fields.py | 195 | from wtforms.fields import Field
from . import widgets
from .validators import Recaptcha
__all__ = ["RecaptchaField"]
class RecaptchaField(Field):
widget = widgets.RecaptchaWidget()
# error message if recaptcha validation fails
recaptcha_error = None
def __init__(self, label='', validators=None, *... |
drepetto/chiplotle | refs/heads/master | chiplotle/tools/shapetools/get_shapes_with_tag.py | 1 | from chiplotle.geometry.core.tagsvisitor import TagsVisitor
def get_shapes_with_tag(shape, tag):
'''Returns all the shapes with the given tag.'''
v = TagsVisitor()
v.visit(shape)
return v.tags.get(tag) or []
if __name__ == '__main__':
from chiplotle import *
c1 = circle(1000)
c1.meta.ta... |
mer-hybris/android_kernel_samsung_tuna | refs/heads/hybris-10.1 | tools/perf/scripts/python/sched-migration.py | 11215 | #!/usr/bin/python
#
# Cpu task migration overview toy
#
# Copyright (C) 2010 Frederic Weisbecker <fweisbec@gmail.com>
#
# perf script event handlers have been generated by perf script -g python
#
# This software is distributed under the terms of the GNU General
# Public License ("GPL") version 2 as published by the Fre... |
gregdek/ansible | refs/heads/devel | lib/ansible/modules/web_infrastructure/jboss.py | 55 | #!/usr/bin/python
# -*- coding: utf-8 -*-
# (c) 2013, Jeroen Hoekx <jeroen.hoekx@dsquare.be>
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
from __future__ import absolute_import, division, print_function
__metaclass__ = type
ANSIBLE_METADATA = {'metadata_version': '1.1... |
ShwoognationHQ/bitcoin | refs/heads/master | contrib/spendfrom/setup.py | 2104 | from distutils.core import setup
setup(name='btcspendfrom',
version='1.0',
description='Command-line utility for bitcoin "coin control"',
author='Gavin Andresen',
author_email='gavin@bitcoinfoundation.org',
requires=['jsonrpc'],
scripts=['spendfrom.py'],
)
|
anurag03/integration_tests | refs/heads/master | cfme/fixtures/single_appliance_sprout.py | 12133432 | |
Endika/odoo | refs/heads/8.0 | openerp/addons/base/res/res_font.py | 322 | # -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2013 OpenERP SA (<http://openerp.com>).
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU... |
52ai/django-ccsds | refs/heads/master | tests/auth_tests/test_auth_backends.py | 13 | from __future__ import unicode_literals
from datetime import date
from django.conf import settings
from django.contrib.auth import (
BACKEND_SESSION_KEY, SESSION_KEY, authenticate, get_user,
)
from django.contrib.auth.backends import ModelBackend
from django.contrib.auth.hashers import MD5PasswordHasher
from djan... |
readhub/readhub_hackaton | refs/heads/master | dlib/admin.py | 1 | from django.contrib import admin
from django.contrib.sites.models import Site
from models import Book, Borrow
admin.site.unregister(Site)
admin.site.register(Book)
admin.site.register(Borrow) |
mobo95/pyload | refs/heads/stable | module/plugins/hooks/WindowsPhoneNotify.py | 1 | # -*- coding: utf-8 -*-
import httplib
from time import time
from module.plugins.Hook import Hook
class WindowsPhoneNotify(Hook):
__name__ = "WindowsPhoneNotify"
__type__ = "hook"
__version__ = "0.06"
__config__ = [("id" , "str" , "Push ID" , "" ... |
ddaan/django-arctic | refs/heads/develop | arctic/tests/test_models.py | 1 | # from django.db import models
# import pytest
# from mixer.backend.django import mixer
# pytestmark = pytest.mark.django_db
# class Book(models.Model):
# title = models.CharField("Title", max_length=255, null=False)
# description = models.TextField("Description", blank=True, null=False)
# category = mod... |
msarana/selenium_python | refs/heads/master | ENV/Lib/encodings/iso8859_6.py | 593 | """ Python Character Mapping Codec iso8859_6 generated from 'MAPPINGS/ISO8859/8859-6.TXT' with gencodec.py.
"""#"
import codecs
### Codec APIs
class Codec(codecs.Codec):
def encode(self,input,errors='strict'):
return codecs.charmap_encode(input,errors,encoding_table)
def decode(self,input,errors='... |
duqiao/django | refs/heads/master | tests/expressions/tests.py | 171 | from __future__ import unicode_literals
import datetime
import uuid
from copy import deepcopy
from django.core.exceptions import FieldError
from django.db import DatabaseError, connection, models, transaction
from django.db.models import TimeField, UUIDField
from django.db.models.aggregates import (
Avg, Count, M... |
FreshXOpenSource/wallaby-frontend-qt | refs/heads/master | wallaby/apps/template/deploy/app.py | 1 | # Copyright (c) by it's authors.
# Some rights reserved. See LICENSE, AUTHORS.
class Options:
def __init__(self):
self.server = "127.0.0.1"
self.app = "$appname$"
self.db = "$appname$"
self.module = "WallabyApp2"
self.password = self.username = None
self.fx = True
... |
OCA/stock-logistics-workflow | refs/heads/12.0 | stock_picking_operation_quick_change/__manifest__.py | 1 | # © 2017 Sergio Teruel <sergio.teruel@tecnativa.com>
# License AGPL-3.0 or later (http://www.gnu.org/licenses/lgpl).
{
"name": "Stock Picking Operation Quick Change",
"summary": "Change location of all picking operations",
"version": "12.0.1.0.0",
"category": "Warehouse",
"website": "https://github... |
djbaldey/django | refs/heads/master | tests/m2m_intermediary/__init__.py | 12133432 | |
litchfield/django | refs/heads/master | tests/servers/another_app/__init__.py | 12133432 | |
rebost/django | refs/heads/master | django/conf/locale/ru/__init__.py | 12133432 | |
shridarpatil/RestApiz | refs/heads/master | dashboard/__init__.py | 12133432 | |
wetneb/django | refs/heads/master | tests/invalid_models_tests/__init__.py | 12133432 | |
neilLasrado/erpnext | refs/heads/develop | erpnext/support/doctype/service_day/__init__.py | 12133432 | |
Henry-Pump/Pycomm-Helper | refs/heads/master | pycomm_helper/micro800.py | 1 | """Hold utilities to read/write from a Micro800 PLC."""
from pycomm.ab_comm.clx import Driver as plcDriver
import sys
def readMicroTag(addr, tag):
"""Read a tag value from a Micro800 PLC."""
addr = str(addr)
tag = str(tag)
c = plcDriver()
if c.open(addr, True):
try:
v = c.read... |
TangXT/edx-platform | refs/heads/master | lms/djangoapps/certificates/__init__.py | 12133432 | |
xu6148152/Binea_Python_Project | refs/heads/master | PythonCookbook/text_str/__init__.py | 12133432 | |
tseaver/google-cloud-python | refs/heads/master | trace/google/cloud/trace_v1/gapic/transports/__init__.py | 12133432 | |
philoniare/horizon | refs/heads/master | openstack_dashboard/dashboards/admin/hypervisors/compute/__init__.py | 12133432 | |
AndrewGrossman/django | refs/heads/master | tests/project_template/__init__.py | 12133432 | |
iamwucheng/xml_models2 | refs/heads/master | xml_models/xpath_finder.py | 2 | from lxml import etree
import sys
if sys.version < '3':
def unicode(string):
"""
Fake unicode function
"""
import codecs
if not string:
return
return codecs.unicode_escape_decode(string)[0]
else:
def unicode(string):
"""
Fake unicode ... |
PLyczkowski/Sticky-Keymap | refs/heads/master | 2.74/scripts/addons/ice_tools.py | 1 | bl_info = {
"name": "Ice Tools",
"author": "Ian Lloyd Dela Cruz",
"version": (2, 0),
"blender": (2, 7, 0),
"location": "3d View > Tool shelf",
"description": "Retopology support",
"warning": "",
"wiki_url": "",
"tracker_url": "",
"category": "Retopology"}
import bpy
import math
... |
thesamet/webilder | refs/heads/master | src/webilder/webilder_unity_indicator.py | 1 | #!/usr/bin/env python
'''
File : webilder_gnome_applet.py
Author : Nadav Samet
Contact : thesamet@gmail.com
Date : 2011 May 7
Description : Webilder panel indicator for Ubuntu Unity.
'''
import pygtk
pygtk.require('2.0')
import pkg_resources
from webilder.base_applet import BaseApplet
from webilder.config impo... |
gabrielelanaro/emacs-starter-kit | refs/heads/master | python-libs/rope/refactor/sourceutils.py | 91 | from rope.base import ast, codeanalyze
def get_indents(lines, lineno):
return codeanalyze.count_line_indents(lines.get_line(lineno))
def find_minimum_indents(source_code):
result = 80
lines = source_code.split('\n')
for line in lines:
if line.strip() == '':
continue
resul... |
patilsangram/erpnext | refs/heads/develop | erpnext/stock/doctype/item_variant/item_variant.py | 121 | # Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and Contributors and contributors
# For license information, please see license.txt
from __future__ import unicode_literals
import frappe
from frappe.model.document import Document
class ItemVariant(Document):
pass
|
mineo/picard | refs/heads/master | picard/ui/options/about.py | 1 | # -*- coding: utf-8 -*-
#
# Picard, the next-generation MusicBrainz tagger
# Copyright (C) 2006-2014 Lukáš Lalinský
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the Li... |
kkdd/arangodb | refs/heads/devel | 3rdParty/V8-4.3.61/build/gyp/pylib/gyp/MSVSSettings.py | 437 | # Copyright (c) 2012 Google Inc. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
"""Code to validate and convert settings of the Microsoft build tools.
This file contains code to validate and convert settings of the Microsoft
build tools. The... |
cmallwitz/Sunflower | refs/heads/develop | application/main.py | 1 | import os
import sys
try:
# check if gtk is available
import gi
gi.require_version('Gtk', '3.0')
gi.require_version('Notify', '0.7')
except:
# print error and die
print 'Error starting Sunflower, missing GTK 3.0+'
sys.exit(1)
else:
# import required modules
from gi.repository import Gtk, Gdk, GObject, Gio,... |
gsmaxwell/phase_offset_rx | refs/heads/master | grc/base/Constants.py | 46 | """
Copyright 2008, 2009 Free Software Foundation, Inc.
This file is part of GNU Radio
GNU Radio Companion is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2
of the License, or (at your option) any ... |
kiszk/spark | refs/heads/master | python/pyspark/worker.py | 5 | #
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not us... |
seecloud/ceagle | refs/heads/master | setup.py | 334 | # Copyright (c) 2013 Hewlett-Packard Development Company, L.P.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applica... |
Brainiq7/Ananse | refs/heads/master | ananse_dl/extractor/canalplus.py | 1 | # encoding: utf-8
from __future__ import unicode_literals
import re
from .common import InfoExtractor
from ..utils import (
unified_strdate,
url_basename,
qualities,
)
class CanalplusIE(InfoExtractor):
IE_DESC = 'canalplus.fr, piwiplus.fr and d8.tv'
_VALID_URL = r'https?://(?:www\.(?P<site>canal... |
drmrd/ansible | refs/heads/devel | lib/ansible/modules/cloud/openstack/os_nova_flavor.py | 15 | #!/usr/bin/python
# Copyright (c) 2015 Hewlett-Packard Development Company, L.P.
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
from __future__ import absolute_import, division, print_function
__metaclass__ = type
ANSIBLE_METADATA = {'metadata_version': '1.1',
... |
4022321818/w16b_test | refs/heads/master | static/Brython3.1.1-20150328-091302/Lib/sre_parse.py | 630 | #
# Secret Labs' Regular Expression Engine
#
# convert re-style regular expression to sre pattern
#
# Copyright (c) 1998-2001 by Secret Labs AB. All rights reserved.
#
# See the sre.py file for information on usage and redistribution.
#
"""Internal support module for sre"""
# XXX: show string offset and offending ch... |
AngryBork/apex-sigma-plugins | refs/heads/master | minigames/other/eightball.py | 3 | import secrets
import discord
positive = [
'Absolutely.',
'I am certain that that\'s a yes.',
'Of course.',
'Yes.',
'No shit Sherlock.',
'Is water wet?',
'Maybe, probably, certainly, yeah.',
'Yup.',
'Yeah.',
'For sure.',
'Undoubtedly.',
'100% Certainty.',
'This is ... |
drxaero/calibre | refs/heads/master | src/calibre/ebooks/conversion/plugins/snb_output.py | 23 | # -*- coding: utf-8 -*-
__license__ = 'GPL 3'
__copyright__ = '2010, Li Fanxi <lifanxi@freemindworld.com>'
__docformat__ = 'restructuredtext en'
import os, string
from calibre.customize.conversion import OutputFormatPlugin, OptionRecommendation
from calibre.ptempfile import TemporaryDirectory
from calibre.constants ... |
maelnor/cinder | refs/heads/master | cinder/scheduler/manager.py | 1 | # vim: tabstop=4 shiftwidth=4 softtabstop=4
# Copyright (c) 2010 OpenStack, LLC.
# Copyright 2010 United States Government as represented by the
# Administrator of the National Aeronautics and Space Administration.
# All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# ... |
blackms/myTelegramBot | refs/heads/master | myTelegramBot/libs/gmail/__init__.py | 17 |
"""
GMail! Woo!
"""
__title__ = 'gmail'
__version__ = '0.1'
__author__ = 'Charlie Guo'
__build__ = 0x0001
__license__ = 'Apache 2.0'
__copyright__ = 'Copyright 2013 Charlie Guo'
from .gmail import Gmail
from .mailbox import Mailbox
from .message import Message
from .exceptions import GmailException, ConnectionE... |
shuangshuangwang/spark | refs/heads/master | python/pyspark/mllib/stat/__init__.py | 2 | #
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not us... |
inocybe/odl-bgpcep | refs/heads/master | pcep/pcepy/__init__.py | 1 | # PCEPY - library for simulating peers of the Path Computation Element Protocol
#
# Copyright (c) 2012,2013 Cisco Systems, Inc. and others. All rights reserved.
#
# This program and the accompanying materials are made available under the
# terms of the Eclipse Public License v1.0 which accompanies this distribution,
#... |
puttarajubr/commcare-hq | refs/heads/master | corehq/apps/domain/tasks.py | 2 | from celery.schedules import crontab
from celery.task import periodic_task
from django.conf import settings
from django.core.urlresolvers import reverse
from django.template.loader import render_to_string
from corehq.apps.domain.views import EditBasicProjectInfoView
from corehq.apps.es.domains import DomainES
from co... |
shurihell/testasia | refs/heads/test1 | lms/djangoapps/course_wiki/__init__.py | 12133432 | |
fujunwei/chromium-crosswalk | refs/heads/master | tools/accessibility/dump_accessibility_tree_auralinux.py | 3 | #!/usr/bin/env python
# Copyright 2015 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
"""Dump Chrome's ATK accessibility tree to the command line.
Accerciser is slow and buggy. This is a quick way to check that Chrome is... |
mancoast/CPythonPyc_test | refs/heads/master | fail/334_test_stringprep.py | 165 | # To fully test this module, we would need a copy of the stringprep tables.
# Since we don't have them, this test checks only a few codepoints.
import unittest
from test import support
from stringprep import *
class StringprepTests(unittest.TestCase):
def test(self):
self.assertTrue(in_table_a1("\u0221")... |
xyproto/gosignal | refs/heads/master | pyo/examples/utilities/01_get_example.py | 12 | #!/usr/bin/env python
# encoding: utf-8
"""
The PyoObject.get() method can be used to convert audio stream to usable python data.
"""
from pyo import *
s = Server(sr=44100, nchnls=2, buffersize=512, duplex=0).boot()
lfos = Sine(freq=[.1,.2,.4,.3], mul=100, add=500)
synth = SineLoop(freq=lfos, feedback=.07, mul=.05)... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.