repo_name stringlengths 4 116 | path stringlengths 4 379 | size stringlengths 1 7 | content stringlengths 3 1.05M | license stringclasses 15
values |
|---|---|---|---|---|
stygstra/keras-contrib | tests/keras_contrib/layers/crf_test.py | 3039 | import pytest
import numpy as np
from numpy.testing import assert_allclose
from keras.utils.test_utils import keras_test
from keras.layers import Embedding
from keras_contrib.layers import CRF
from keras.models import Sequential, model_from_json
nb_samples, timesteps, embedding_dim, output_dim = 2, 10, 4, 5
embedding... | mit |
TeamLabyrinth5-Telerik/Labyrinth | Source/Labirynth.Logic/Interfaces/IUserInterface.cs | 803 | namespace Labyrinth.Logic.Interfaces
{
using Labyrinth.Common.Enums;
/// <summary>
/// Provides interacting with user methods.
/// </summary>
public interface IUserInterface
{
/// <summary>
/// Retrieves the user input.
/// </summary>
/// <returns>User input as ... | mit |
apparena/docs | readthedocs/builds/models.py | 10155 | import re
import os.path
from django.core.urlresolvers import reverse
from django.conf import settings
from django.db import models
from django.utils.translation import ugettext_lazy as _, ugettext
from guardian.shortcuts import assign
from taggit.managers import TaggableManager
from privacy.loader import VersionMan... | mit |
bountysource/core | app/views/api/v2/cash_outs/csv.json.rb | 56 | @collection.map do |cash_out|
cash_out
end.to_json | mit |
shaonsust/shop | application/views/Sub_project_list_v.php | 13618 | <?php
include 'header.php';
?>
<style>
div.table1
{
height: 400px;
min-width: 100px;
margin: 0 auto;
overflow-x: scroll;
overflow-y: scroll;
}
.table1 td
{
color: #000;
}
@media only screen and (max-width: 995px) {
#back, #erp, #ep, #dp... | mit |
kaby76/swigged-llvm | swigged.llvm/RealPredicate.cs | 651 | //------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 3.0.12
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//----... | mit |
zhenglinj/VirtualGEVCam | src/Inc/Iniparser/ini.cpp | 3678 | #include "ini.h"
namespace INI
{
inline std::string trim(const std::string& s)
{
char p[] = " \t\r\n";
long sp = 0;
long ep = s.length() - 1;
for (; sp <= ep; ++sp)
if (!strchr(p, s[sp])) break;
for (; ep >= 0; --ep)
if (!strchr(p, s[ep])) break;
return s.... | mit |
stbuehler/rust-async-dnssd | src/service/enumerate_domains.rs | 3801 | use std::{
io,
os::raw::{
c_char,
c_void,
},
pin::Pin,
task::{
Context,
Poll,
},
};
use crate::{
cstr,
ffi,
inner,
interface::Interface,
};
type CallbackStream = crate::stream::ServiceStream<inner::OwnedService, EnumerateResult>;
/// Whether to enumerate domains which are browsed or domains for whi... | mit |
diverza/elixir-coolaid | recipe.rb | 3112 | #
# Author(s): Chris McClimans <chris@hippiehacker.org>,
# Taylor Carpenter <taylor@codecafe.com>
# License: Released under the MIT License.
##### attributes / variables
#elixir_release = 'bb4874' # or 'v0.10.2-dev'
elixir_release = 'v0.12.0' # or 'v0.10.2-dev'
rebar_release = '2.0.0'
#dynamo_release = '82... | mit |
zhenyaracheva/TelerikAcademy | DSA/ExamPreparation/Exam2014/GirlsGoneWild/Properties/AssemblyInfo.cs | 1402 | using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("Gi... | mit |
MarinShalamanov/LiteLatexType | js/math.js | 3257 |
function isLetter(l) {
return (/[a-z0-9]/i).test(l);
}
function parseFracLeft(str, idx) {
var leftStart=-1, leftEnd=-1;
var numBrackets = 0;
var word_started = false;
for(var i = idx-1; i >= 0; i--) {
if(numBrackets == 0 && isLetter(str.charAt(i)) && !word_started) {
word_started = true;
leftEnd = i;
... | mit |
wangds/puzzle-solver | tests/kakuro.rs | 3396 | //! Kakuro.
//!
//! https://en.wikipedia.org/wiki/Kakuro
extern crate puzzle_solver;
use puzzle_solver::{LinExpr,Puzzle,Solution,Val,VarToken};
const SIZE: usize = 7;
const X: Val = 0;
type Board = [[Val; SIZE]; SIZE];
type KakuroVars = Vec<Vec<Option<VarToken>>>;
enum Rule {
H{ total: Val, y: usize, x1: usize,... | mit |
andersonsilvade/python_C | Python32/PPWannaHangSomeone.py | 5107 | import urllib.request
import random
forca=['''
+------------¬
| §§
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
==============================''', '''
+------------¬
| §§
| _|_
| ( --)
... | mit |
vkalpias/winterblast | prefabs.js | 2384 | pc.script.create('prefabs', function (context) {
// Creates a new Prefabs instance
var Prefabs = function (entity) {
this.entity = entity;
this.prefabs = {};
this.pools = {};
this.spawned = [];
};
Prefabs.prototype = {
// Called once after all resources are loade... | mit |
bubblewrap-engine/bubblewrap_sfml | include/Bubblewrap/Base/SfmlClock.hpp | 466 | #ifndef BUBBLEWRAP_SFML_BASE_SFMLCLOCK_HPP
#define BUBBLEWRAP_SFML_BASE_SFMLCLOCK_HPP
#include "Bubblewrap/Base/Clock.hpp"
#include "SFML/System.hpp"
namespace Bubblewrap
{
namespace Base
{
/*! An implementation of Clock using SFML's sf::Clock*/
class SfmlClock
: public Clock
{
public:
CREATE_REGISTER_... | mit |
hbussell/pinax-tracker | apps/pyvcal/subversion/revision.py | 3739 | from revisionproperties import RevisionProperties
from resource import Resource
from revisiondiff import RevisionDiff
from subvertpy import repos, ra, NODE_NONE, NODE_DIR, NODE_FILE
from datetime import datetime
import os
class Revision(object):
""" The complete state of a branch at a given time """
def __i... | mit |
PhilSanders/NetfunkTheme | addons/remove-admin-bar/remove-admin-bar.php | 578 | <?php
/*
Plugin Name: Remove The Admin Bar
Plugin Description: Prevents the admin menu bar from displaying on the front home page.
Plugin Version: 1.0
Plugin Date: 12/03/13
Plugin Author: Phil Sanders
Plugin Author URL: http://www.netfunkdesign.com/author/pillform
Plugin URL: http://www.netfunkdesign.com
*/
/... | mit |
jyggen/advent-of-go | 2020/08-handheld-halting/main_test.go | 914 | package main
import (
"fmt"
"testing"
"github.com/jyggen/advent-of-go/internal/solver"
)
var testCases = []*solver.TestCase{
{
Input: "nop +0\nacc +1\njmp +4\nacc +3\njmp -3\nacc -99\nacc +1\njmp -4\nacc +6",
Solvers: []*solver.TestCaseSolver{
{
Solver: SolvePart1,
Output: "5",
},
{
Solv... | mit |
vape1/example_php_symfony | src/Crm/AddressesBundle/Entity/House.php | 11330 | <?php
namespace Crm\AddressesBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
use Crm\AddressesBundle\CrmAddressesBundle;
use Doctrine\ORM\Mapping\OrderBy;
use Symfony\Bridge\Doctrine\Validator\Constraints\UniqueEntity;
use Doctrine\Common\Collections\ArrayCollection;
/**
* House
*
* @ORM\Table(name="address_house... | mit |
prateekmathur1991/algorithms | run/LinkedListTest.java | 498 | package run;
import core.LinkedList;
public class LinkedListTest {
public static void main(String[] args) {
LinkedList<Integer> linkedList = new LinkedList<>();
linkedList.add(10);
linkedList.add(15);
linkedList.add(2);
linkedList.add(20);
linkedList.printList();
linkedList.ins... | mit |
ignaciocases/hermeneumatics | node_modules/scala-node/main/target/streams/compile/externalDependencyClasspath/$global/package-js/extracted-jars/scalajs-library_2.10-0.4.0.jar--29fb2f8b/scala/runtime/Nothing$.js | 1744 | /** @constructor */
ScalaJS.c.scala_runtime_Nothing$ = (function() {
ScalaJS.c.java_lang_Throwable.call(this)
});
ScalaJS.c.scala_runtime_Nothing$.prototype = new ScalaJS.inheritable.java_lang_Throwable();
ScalaJS.c.scala_runtime_Nothing$.prototype.constructor = ScalaJS.c.scala_runtime_Nothing$;
/** @constructor */
S... | mit |
npruehs/slash-framework | Source/Slash.Unity.NGUI/Source/Unity/Assets/NData/NDataExamples/TransformVariant/TransformVariant.cs | 659 | using UnityEngine;
public class TransformVariantContext : EZData.Context
{
#region Property UpsideDown
private readonly EZData.Property<bool> _privateUpsideDownProperty = new EZData.Property<bool>();
public EZData.Property<bool> UpsideDownProperty { get { return _privateUpsideDownProperty; } }
public bool UpsideDo... | mit |
revuniversal/5e-sheets | src/character/sheet/common/index.js | 387 | import Box from './Box';
import BoxFooter from './BoxFooter';
import FlexCell from './FlexCell';
import FlexRow from './FlexRow';
import Labels from './Labels';
import Values from './Values';
import TinyTitle from './TinyTitle';
import displayModifier from './display-modifier';
export {
Box,
BoxFooter,
displayM... | mit |
Azure/azure-sdk-for-java | sdk/resourcemanager/azure-resourcemanager/src/samples/java/com/azure/resourcemanager/privatedns/generated/PrivateZonesGetByResourceGroupSamples.java | 991 | // Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) AutoRest Code Generator.
package com.azure.resourcemanager.privatedns.generated;
import com.azure.core.util.Context;
/** Samples for PrivateZones GetByResourceGroup. */
public final clas... | mit |
dbiesecke/dbiesecke.github.io | repo/script.module.urlresolver/lib/urlresolver/plugins/fembed.py | 2290 | '''
urlresolver Kodi plugin
Copyright (C) 2018
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 3 of the License, or
(at your option) any later version.
Thi... | mit |
sebmck/lerna | commands/version/lib/is-anything-committed.js | 420 | "use strict";
const log = require("npmlog");
const childProcess = require("@lerna/child-process");
module.exports = isAnythingCommitted;
function isAnythingCommitted(opts) {
log.silly("isAnythingCommitted");
const anyCommits = childProcess.execSync("git", ["rev-list", "--count", "--all", "--max-count=1"], opts)... | mit |
touchtechio/starcatcher | midiTestUnity/Assets/Foriero Store/Others/MIDIUnified/Scripts/Settings/MIDISettings.cs | 2070 | using UnityEngine;
using System.Collections;
using ForieroEngine;
#if UNITY_EDITOR
using UnityEditor;
#endif
public partial class MIDISettings : ScriptableObject
{
#if UNITY_EDITOR
[MenuItem ("Foriero/Settings/MIDI")]
public static void MIDISettingsMenu ()
{
MIDISettings s = MIDISettings.instance;
EditorGUIU... | mit |
ylorant/HedgeBot | Plugins/RaffleManager/Entity/Raffle.php | 1924 | <?php
namespace HedgeBot\Plugins\RaffleManager\Entity;
class Raffle
{
/** @var string Raffle ID */
protected $id;
/** @var string Raffle model ID */
protected $raffleModelId;
/** @var string Raffle channel */
protected $channel;
/** @var array Contestants */
protected $contestants;
... | mit |
Amaire/filmy | vendor/symfony/console/Symfony/Component/Console/Tests/Input/InputArgumentTest.php | 4242 | <?php
/*
* This file is part of the Symfony package.
*
* (c) Fabien Potencier <fabien@symfony.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Symfony\Component\Console\Tests\Input;
use Symfony\Component\Console\In... | mit |
jacquelinekay/petra | test/sequential_table.cpp | 2354 | // Copyright Jacqueline Kay 2017
// Distributed under the MIT License.
// See accompanying LICENSE.md or https://opensource.org/licenses/MIT
#include "petra/sequential_table.hpp"
#include "utilities.hpp"
#include <array>
#include <iostream>
template<auto Size>
struct test {
using Integral = decltype(Size);
temp... | mit |
deregenboog/ecd | app/DoctrineMigrations/Version20210827082650.php | 2070 | <?php declare(strict_types=1);
namespace Application\Migrations;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\Migrations\AbstractMigration;
/**
* Auto-generated Migration: Please modify to your needs!
*/
final class Version20210827082650 extends AbstractMigration
{
public function up(Schema $schema) : void
... | mit |
ossimc82/RotMG-Proxy-Alpha- | IProxy/networking/svrPackets/NewTickPacket.cs | 2219 | //The MIT License (MIT)
//
//Copyright (c) 2015 Fabian Fischer
//
//Permission is hereby granted, free of charge, to any person obtaining a copy
//of this software and associated documentation files (the "Software"), to deal
//in the Software without restriction, including without limitation the rights
//to use, copy,... | mit |
dsarfati/OrleansTestKit | test/OrleansTestKit.Tests/Grains/HelloReminders.cs | 889 | using System;
using System.Collections.Generic;
using System.Threading.Tasks;
using Orleans;
using Orleans.Runtime;
namespace TestGrains
{
public class HelloReminders : Grain, IGrainWithIntegerKey, IRemindable
{
public List<string> FiredReminders = new List<string>();
public Task ... | mit |
efaisal/ladang | examples/lowlevel_nonblocking.py | 2242 | #!/usr/bin/env python
import sys
import select
from _ladang import *
# Directory to watch
mydir = 'mydir'
# Initialize module, instead of init() we user init1()
try:
notify_fd = init1(NONBLOCK|CLOEXEC)
except IOError as (errno, strerror):
print "Errno:", errno
print "Strerror:", strerror
sys.exit(1)
... | mit |
2She2/JavaScriptUIAndDOM | 09.jQuery-Overview/jQuery-Overview/scripts/3.StudentsTable.js | 1783 | /// <reference path="E:\Dropbox\Telerik Academy\5.JavaScript\2.JavaScript UI & DOM\2.Homework\09.jQuery-Overview\jQuery-Overview\jQuery-Overview\libs/jquery-2.1.1.min.js" />
// 3.By given an array of students, generate a table that represents these students
// Each student has first name,last name and grade
// U... | mit |
tmilos/lightSAML-1 | tests/LightSaml/Tests/Credential/Criteria/CredentialNameCriteriaTest.php | 630 | <?php
namespace LightSaml\Tests\Credential\Criteria;
use LightSaml\Credential\Criteria\CredentialNameCriteria;
use LightSaml\Credential\Criteria\TrustCriteriaInterface;
class CredentialNameCriteriaTest extends \PHPUnit_Framework_TestCase
{
public function test_implements_trust_criteria_interface()
{
... | mit |
bcb/jsonrpcclient | jsonrpcclient/clients/tornado_client.py | 2030 | """
Tornado Client.
Represents an endpoint to communicate with using Tornado asynchronous HTTP client.
"""
from typing import Any, Optional
from tornado.httpclient import AsyncHTTPClient # type: ignore
from ..async_client import AsyncClient
from ..response import Response
class TornadoClient(AsyncClient):
"""... | mit |
Equilibrium-Games/Flounder | Sources/Bitmaps/Png/PngBitmap.hpp | 355 | #pragma once
#include "Bitmaps/Bitmap.hpp"
namespace acid {
class ACID_EXPORT PngBitmap : public Bitmap::Registrar<PngBitmap> {
inline static const bool Registered = Register(".png");
public:
static void Load(Bitmap *bitmap, const std::filesystem::path &filename);
static void Write(const Bitmap *bitmap, const std:... | mit |
dollarshaveclub/furan | vendor/github.com/jackc/pgtype/text_array.go | 7502 | // Code generated by erb. DO NOT EDIT.
package pgtype
import (
"database/sql/driver"
"encoding/binary"
"github.com/jackc/pgio"
errors "golang.org/x/xerrors"
)
type TextArray struct {
Elements []Text
Dimensions []ArrayDimension
Status Status
}
func (dst *TextArray) Set(src interface{}) error {
// unty... | mit |
danielgerlag/workflow-core | src/WorkflowCore/Models/LifeCycleEvents/WorkflowCompleted.cs | 132 | using System;
namespace WorkflowCore.Models.LifeCycleEvents
{
public class WorkflowCompleted : LifeCycleEvent
{
}
}
| mit |
neckhair/crontainer | cmd/root.go | 2741 | // Copyright © 2017 Philippe Hässig <phil@neckhair.ch>
package cmd
import (
"fmt"
"log"
"math/rand"
"os"
"os/signal"
"sync"
"syscall"
"time"
"github.com/spf13/cobra"
"github.com/spf13/viper"
"github.com/neckhair/crontainer/crontainer"
)
var cfgFile string
func waitForQuit() {
var endWaiter sync.WaitGr... | mit |
vikash-india/JavaScriptNotes2Myself | src/concepts/P037_Functions_ApplyInvocationPattern.js | 1579 | // Description: The Apply Invocation Pattern in JavaScript
// The Apply Invocation Pattern
// 1. Since JavaScript is a functional object-oriented language, functions can have methods.
// 2. The apply method allows us to construct an array of arguments to use to invoke a function.
// 3. It also lets us choose the value... | mit |
greivinlopez/skue | views/json.go | 1089 | package views
import (
"bytes"
"encoding/json"
"github.com/greivinlopez/skue"
"io"
"io/ioutil"
"net/http"
)
type JSONProducer struct {
}
func (producer JSONProducer) MimeType() string {
return skue.MIME_JSON
}
func (producer JSONProducer) Out(w http.ResponseWriter, statusCode int, value interface{}) {
outpu... | mit |
psq/rails-undo-redo | spec/undo_manager_spec.rb | 150 | require File.expand_path(File.dirname(__FILE__) + '/spec_helper')
require 'zlib'
describe "UndoManager" do
it "should description" do
end
end
| mit |
zhengwsh/InplusTrader_Linux | rqalpha/events.py | 4494 | # -*- coding: utf-8 -*-
#
# Copyright 2017 Ricequant, Inc
#
# 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 applicable ... | mit |
onigra/redis-email_signup_verification | lib/redis/email_signup_verification/version.rb | 76 | class Redis
class EmailSignupVerification
VERSION = "0.0.1"
end
end
| mit |
clalimarmo/coherence | build/exposer_spec.js | 690 | 'use strict';
require('core-js');
var expect = require('chai').expect;
var Exposer = require('./exposer');
describe('Exposer', function () {
it('defines attributes whose values can be inspected', function () {
var exposer = Exposer();
var attribute = exposer.expose('attribute');
attribute.push('a value... | mit |
ClaytonSmith/Pcaso | tests/server/system/integration/controller.js | 322 | 'use strict'
// Comments
require('./user-comments');
require('./user-comments-notification');
// FileContainers
require('./user-fileContainer');
require('./user-fileContainer-notification');
// FileContainers and Comments
require('./user-fileContainer-comments');
require('./user-fileContainer-comments-notification')... | mit |
manikandants/node-unleashed | lib/serialnumbers.js | 1295 | 'use strict';
var request = require('request');
var utils = require('./utils.js');
var SerialNumbers = function(options) {
this.apiId = options.apiId;
this.apiKey = options.apiKey;
this.url = options.url + '/SerialNumbers';
};
SerialNumbers.prototype.getAll = function(query, callback) {
var apiMeta = utils.g... | mit |
karstenw/nodebox-pyobjc | art/nodeboxlogo.py | 2464 | size(100,100)
def bar(x, y, w, depth, filled=1.0):
d1 = depth*filled
colormode(HSB)
f = fill()
s = stroke()
if f != None and f.brightness != 1:
s = color(f.hue, f.saturation+0.2, f.brightness-0.4)
nostroke()
#front
if f != None: fill(f)
rect(x, y, w, w)
... | mit |
TailorDev/pauling | mobile/src/PosterCardList/index.js | 351 | /* @flow */
import { connect } from 'react-redux';
import PosterCardList from './presenter';
import type { State } from 'app/types';
const mapStateToProps = (state: State) => {
const { errored, loading, posters } = state.posters;
return {
errored,
loading,
posters,
};
};
export default connect(map... | mit |
xfxdev/xtcp | xconn.go | 8164 | package xtcp
import (
"bytes"
"errors"
"io"
"net"
"sync"
"sync/atomic"
"time"
)
const (
connStateNormal int32 = iota
connStateStopping
connStateStopped
)
var (
errSendToClosedConn = errors.New("send to closed conn")
errSendListFull = errors.New("send list full")
bufferPool1K = &sync.Pool{
New: fu... | mit |
dustin-H/bauhaus-ui | modules/InputDateTime/index.js | 2412 | import React, {PropTypes, Component} from 'react'
import Look, {StyleSheet} from 'react-look'
const c = StyleSheet.combineStyles
import {$, mobile} from 'bauhaus-ui-module-utils'
import Date from './Date'
import Time from './Time'
import styles from './style.js'
import moment from 'moment'
class InputDateTime extends ... | mit |
thenables/requisition | test/response.js | 7189 |
var Promise = require('any-promise');
var cookieParser = require('cookie-parser');
var tmpdir = require('os').tmpdir();
var cat = require('concat-stream');
var express = require('express');
var join = require('path').join;
var assert = require('assert');
var fs = require('fs');
var request = require('..');
describe(... | mit |
gatemedia/gatemedia-data | addon/utils/has-many.js | 4138 | import Ember from 'ember';
import ModelArray from 'gatemedia-data/utils/model-array';
import hasManyMeta from 'gatemedia-data/utils/has-many-meta';
import tooling from 'gatemedia-data/utils/tooling';
var fmt = Ember.String.fmt;
/**
Declares a "to many" relation.
- type: the "many" relation side's entity fully q... | mit |
MarcoAlducinR5/ProyectoFEX | application/views/auditoria/auditoria.php | 2151 | <script type="text/javascript" src="<?=base_url('application/js/auditoria/listarusuarios.js')?>"></script>
<!--********************************************************************************************************-->
<div class="page-header">
<h1><?=$titulo;?> <small></small></h1>
</div>... | mit |
askl56/income-tax | spec/income_tax/countries/brazil_spec.rb | 4782 | describe IncomeTax::Countries::Brazil do
subject(:result) { described_class.new(income: income, income_type: type, tax_year: tax_year) }
let(:type) { :gross }
describe 'from gross income of 0' do
let(:tax_year) { 2015 }
let(:income) { 0 ... | mit |
bugsnag/bugsnag-js | packages/plugin-electron-preload-error/test/fixtures/safe-preload.js | 7 | // :^)
| mit |
bundgus/python-playground | zmq-playground/persistentqueue.py | 2683 | import os
import sqlite3
from pickle import loads, dumps
from time import sleep, time
from threading import get_ident
class persistentqueue(object):
_create = (
'CREATE TABLE IF NOT EXISTS queue '
'('
' id INTEGER PRIMARY KEY AUTOINCREMENT,'
' cid VARCHAR,'
... | mit |
yenbekbay/raffinade | theme/content-audio.php | 1078 | <article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
<div class="ribbon"><a href="<?php echo home_url( '/' ); ?>type/audio/"><div class="shadow"></div></a></div>
<section class="entry-header">
<?php exultic_post_title($post->ID); ?>
</section>
<section class="entry-content">
<div cl... | mit |
hack-duke/hackduke-dayof | src/components/EventInfo/EventInfo.js | 4689 | import React from 'react'
import classes from './EventInfo.scss'
import { Col, Row } from 'react-bootstrap'
import EventInfoSection from 'components/EventInfoSection'
import AlertBubble from 'components/AlertBubble'
import DelimitedStackedInfo from 'components/DelimitedStackedInfo'
import {
lighterGrey,
acceptedBlu... | mit |
lisamarie616/beaches-angular-assessment | app/serializers/simple_comment_serializer.rb | 163 | class SimpleCommentSerializer < ActiveModel::Serializer
attributes :id, :note, :score, :user_id, :beach_id
has_one :user, serializer: SimpleUserSerializer
end
| mit |
dontcallmedom/specberus | lib/profiles/FPWG-NOTE.js | 167 |
exports.name = "FP WG Note";
var wgnote = require("./WG-NOTE");
exports.config = wgnote.config;
exports.config.previousVersion = false;
exports.rules = wgnote.rules;
| mit |
rohansen/Code-Examples | Security/Static Analysis/StaticSecurityScan/StaticSecurityScan/Program.cs | 345 | using System;
using System.Collections.Generic;
using System.Data.SqlClient;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace StaticSecurityScan
{
class Program
{
static void Main(string[] args)
{
SqlCommand cmd = new SqlCommand("SELECT * FROM " + args[... | mit |
ksakuntanak/chinaworld | fuel/app/views/app/gallery.php | 1224 | <div id="menu-bar">
<a class="menu menu-1" href="<?php echo Uri::create('app/upload'); ?>">
<img src="<?php echo Uri::base(); ?>public/assets/img/menu-1.png" alt="" />
</a>
<a class="menu menu-2" href="<?php echo Uri::create('app/rules'); ?>">
<img src="<?php echo Uri::base(); ?>public/asset... | mit |
synel/syndll2 | Syndll2/IConnection.cs | 180 | using System;
using System.IO;
namespace Syndll2
{
internal interface IConnection : IDisposable
{
Stream Stream { get; }
bool Connected { get; }
}
} | mit |
ProfilerTeam/Profiler | protected/vendors/yii/i18n/data/uz_cyrl.php | 4446 | <?php
/**
* Locale data for 'uz_Cyrl'.
*
* This file is automatically generated by yiic cldr command.
*
* © 1991-2007 Unicode, Inc. All rights reserved.
* Distributed under the Terms of Use in http://www.unicode.org/copyright.html.
*
* @copyright 2008-2013 Yii Software LLC (http://www.yiiframework.com/license... | mit |
eleven41/Eleven41.AmazonAWS.Billing | Samples/Csv2Xml/Properties/AssemblyInfo.cs | 1425 | using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("Cs... | mit |
yosisa/fluxion | plugin/out-file/cmd/main.go | 171 | package main
import (
"github.com/yosisa/fluxion/plugin"
"github.com/yosisa/fluxion/plugin/out-file"
)
func main() {
plugin.New("out-file", out_file.Factory).Run()
}
| mit |
springload/madewithwagtail | core/migrations/0003_wagtailsitepage_is_featured.py | 526 | # -*- coding: utf-8 -*-
from django.db import models, migrations
class Migration(migrations.Migration):
dependencies = [
('core', '0002_auto_20150419_2004'),
]
operations = [
migrations.AddField(
model_name='wagtailsitepage',
name='is_featured',
fiel... | mit |
patrickleet/meta-template | __tests__/gitignored.js | 882 | const gitignored = require('gitignored')
const path = require('path')
describe('lib/gitignored', () => {
let arr = gitignored.getGitignored(path.join(process.cwd(), 'example-template', '.gitignore'))
let regExpStr = gitignored.gitignoredRegExpString(arr);
let regExp = gitignored.gitignoreRegExp(arr);
it('.get... | mit |
vadim8kiselev/reflection-ui | src/main/java/com/kiselev/reflection/ui/bytecode/agent/Transformer.java | 934 | package com.kiselev.reflection.ui.bytecode.agent;
import com.kiselev.reflection.ui.bytecode.holder.ByteCodeHolder;
import java.lang.instrument.ClassFileTransformer;
import java.lang.instrument.IllegalClassFormatException;
import java.security.ProtectionDomain;
/**
* Created by Vadim Kiselev on 6/12/2017.
*/
public... | mit |
msullivan/rmc-compiler | examples/ringbuf-cpp.cpp | 1728 | #include <rmc++.h>
#include <atomic>
#define BUF_SIZE (1024*1)
// RMC version
struct ring_buf {
unsigned char buf[BUF_SIZE];
rmc::atomic<unsigned> front, back;
};
int buf_enqueue(ring_buf *buf, unsigned char c)
{
XEDGE(e_check, insert);
VEDGE(insert, e_update);
unsigned back = buf->back;
uns... | mit |
khaled33/my_project_name.github.io | src/EmploiyerBundle/Repository/AdresseRepository.php | 243 | <?php
namespace EmploiyerBundle\Repository;
/**
* AdresseRepository
*
* This class was generated by the Doctrine ORM. Add your own custom
* repository methods below.
*/
class AdresseRepository extends \Doctrine\ORM\EntityRepository
{
}
| mit |
kmod/icbd | icbd/type_analyzer/test.py | 2927 | import _ast
import glob
import os
import re
import subprocess
import sys
from icbd.util import cfa
from icbd.type_analyzer import type_checker
import plugins.sqlalchemy
def parse_annotations(s):
offset, s = s.split(' ', 1)
return {int(offset):s}
def test(fn):
cfa.ADD_IF_ASSERTS = True
fn = os.path.a... | mit |
madoar/ng2-wizard | src/lib/util/step-offset.interface.spec.ts | 6663 | import {Component} from '@angular/core';
import {async, ComponentFixture, fakeAsync, TestBed, tick} from '@angular/core/testing';
import {By} from '@angular/platform-browser';
import {ArchwizardModule} from '../archwizard.module';
import {GoToStepDirective} from '../directives/go-to-step.directive';
import {NavigationM... | mit |
kazuhira-r/scala-js-examples | scala-js-literals/src/main/scala/org/littlewings/scalajs/literals/ScalaJsLiterals.scala | 1433 | package org.littlewings.scalajs.literals
import scala.scalajs.js
import scala.scalajs.js.Dynamic.{global, literal}
object ScalaJsLiterals {
def main(): Unit = {
val array = new js.Array[String]
array(0) = "zero"
array(1) = "one"
array(2) = "two"
array.push("last")
array.foreach(v => global.... | mit |
MarinMarinov/JavaScript-End-to-End-Applications | Homework-4-Express/server/config/routes.js | 984 | var auth = require('./auth'),
controllers = require('../controllers');
module.exports = function(app) {
app.get('/', controllers.home.getHome);
app.get('/register', controllers.users.getRegister);
app.post('/register', controllers.users.postRegister);
app.get('/login', controllers.users.getLogin)... | mit |
nullobject/hexgrid | src/views/ControlsView.js | 569 | import React from 'react'
import ButtonView from './ButtonView'
import styles from '../../assets/stylesheets/styles.scss'
const PLAYER_NAMES = ['your', "red's", "green's", "purple's", "orange's"]
export default ({ bus, currentPlayer }) => {
const text = currentPlayer ? `It's ${PLAYER_NAMES[currentPlayer.id]} turn.... | mit |
TimShi/s3_video | src/main/java/com/s3video/commandline/model/Transcoder.java | 2286 | package com.s3video.commandline.model;
public class Transcoder {
private String isInitialized;
private String pipelineId;
private String distributionDomainName;
private String distributionId;
private String notificationTopicArn;
private String billingNotificationTopicArn;
private String notificationSubscripti... | mit |
javoire/node_chat | server.js | 5324 | HOST = null; // localhost
PORT = 8001;
// when the daemon started
var starttime = (new Date()).getTime();
var mem = process.memoryUsage();
// every 10 seconds poll for the memory.
setInterval(function () {
mem = process.memoryUsage();
}, 10*1000);
var fu = require("./fu"),
sys = require("sys"),
url = requ... | mit |
kyuu/dynrpg-rpgss | source/rpgss/script/game_module/ActorWrapper.hpp | 3375 | /*
The MIT License (MIT)
Copyright (c) 2014 Anatoli Steinmark
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
... | mit |
G43riko/Java | Strategy/src/org/engine/gui/menus/RMenu.java | 747 | package org.engine.gui.menus;
import glib.util.GColor;
import java.awt.Color;
import java.awt.Dimension;
import java.awt.FlowLayout;
import javax.swing.BorderFactory;
import javax.swing.JPanel;
import org.MainStrategy;
public class RMenu extends JPanel{
private static final long serialVersionUID = 1... | mit |
invidit/CodeQuality | DesignPattern/Bridge/src/main/java/de/invidit/design/structural/bridge/internal/v2/AccountEnquirySparkasse.java | 1224 | package de.invidit.design.structural.bridge.internal.v2;
import de.invidit.design.structural.bridge.external.sparkasse.v2.AccountingJsonConverter;
import de.invidit.design.structural.bridge.external.sparkasse.v2.SparkasseAccountService;
import de.invidit.design.structural.bridge.internal.AccountEnquiry;
import de.invi... | mit |
leocherubini/laravel_commerce | resources/views/store/product_tag.blade.php | 400 | @extends('store.store')
@section('categories')
@include('store.partial.tags', ['tags'=>$tags])
@stop
@section('content')
<div class="col-sm-9 padding-right">
<div class="features_items"><!--features_items-->
<h2 class="title text-center">{{ $tag->name }}</h2>
@include('store.partial.product'... | mit |
gempir/gempbotgo | api/server.go | 11364 | package api
import (
"encoding/json"
"errors"
"fmt"
"io/fs"
"net/http"
"net/url"
"strconv"
"strings"
"time"
"github.com/gempir/justlog/bot"
"github.com/gempir/justlog/config"
"github.com/gempir/justlog/helix"
log "github.com/sirupsen/logrus"
"github.com/gempir/go-twitch-irc/v2"
"github.com/gempir/ju... | mit |
ISNIT0/ractive | test/browser-tests/plugins/adaptors/magic.js | 7571 | import { test } from 'qunit';
import { initModule } from '../../test-config';
export default function() {
initModule( 'plugins/adaptors/magic.js' );
let fixture2;
let makeObj;
// only run these tests if magic mode is supported
try {
let obj = {};
let _foo;
Object.defineProperty( obj, 'foo', {
get () {
... | mit |
marcoshoya/MasterpassBundle | Common/LocalPrivateKey.php | 1497 | <?php
namespace Hoya\MasterpassBundle\Common;
/**
* The LocalPrivateKey represents a private key stored
* in the PKCS#12 format in a file of the local filesystem.
*/
class LocalPrivateKey implements PrivateKeyInterface
{
/**
* @var EncryptedPrivateKey
*/
private $privateKey;
/**
* @para... | mit |
y3rsh/lawrencetrailhawks-treasury | tests/test_db.py | 2978 | import pytest
import src.model.line_item
from src.model.line_item import LineItem, session
import src.sheets.spreadsheet
from src.sheets.spreadsheet import get_sheet
import sys, os
myPath = os.path.dirname(os.path.abspath(__file__))
sys.path.insert(0, myPath + '/../')
@pytest.mark.skip
def test_ledger_creation():
l... | mit |
hserang/image-foo | app/build/scripts/app.js | 553287 | /** vim: et:ts=4:sw=4:sts=4
* @license RequireJS 2.1.14 Copyright (c) 2010-2014, The Dojo Foundation All Rights Reserved.
* Available via the MIT or new BSD license.
* see: http://github.com/jrburke/requirejs for details
*/
//Not using strict: uneven strict support in browsers, #392, and causes
//problems with requ... | mit |
toadette/mtg_insight | port/src/main/java/de/avalax/mtg_insight/port/adapter/service/card/CardInJsonAdapter.java | 500 | package de.avalax.mtg_insight.port.adapter.service.card;
import com.google.gson.Gson;
import de.avalax.mtg_insight.domain.model.card.Card;
class CardInJsonAdapter {
private final Gson gson;
public CardInJsonAdapter() {
gson = new Gson();
}
public String fromCard(Card card) {
return... | mit |
avinash-singh-rathi/Avi-Job-Portal | var/cache/dev/twig/f3/f3d66b3ac2bf9f43d60becafae2cc713bf80a0b48aa15f7ff744b0ae3ddc3fe1.php | 10410 | <?php
/* category/index.html.twig */
class __TwigTemplate_cc841f0b30a5b60b026397e6992534a0b3da2a9332bb3d3a2e23bfa229853ac1 extends Twig_Template
{
public function __construct(Twig_Environment $env)
{
parent::__construct($env);
// line 1
$this->parent = $this->loadTemplate("base.html.tw... | mit |
stevenblaster/crapengine | libraries/bullet/btgui/Gwen/Controls/TreeControl.cpp | 7764 | /*
GWEN
Copyright (c) 2010 Facepunch Studios
See license in Gwen.h
*/
#include "Gwen/Controls/TreeControl.h"
#include "Gwen/Controls/ScrollControl.h"
#include "Gwen/Utility.h"
using namespace Gwen;
using namespace Gwen::Controls;
GWEN_CONTROL_CONSTRUCTOR( TreeControl )
{
m_TreeControl = this;
m_ToggleButton->... | mit |
uniquegodwin/Costura | CosturaVSPackage/ProjectKind.cs | 909 | public static class ProjectKind
{
const string CSharpProjectKind = "{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}";
const string VBProjectKind = "{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}";
const string FSharpProjectKind = "{F2A71F9B-5D33-465A-A702-920D77279786}";
const string SolutionFolderKind = "{66A26720-8FB... | mit |
hayeah/curly | lib/curly/xml.rb | 2367 | class Curly::XML
def self.xml(source)
self.new(source).xml
end
def initialize(source)
@source = source
@parse = Curly::Parser.new(source).parse
end
def generate
Builder.xml(@parse)
end
class Builder
# tag ::= [head,attr,children]
# attr ::= Hash || nil
# children ::= [tag*... | mit |
emyl/vagrant-triggers | lib/vagrant-triggers/config/provisioner.rb | 520 | module VagrantPlugins
module Triggers
module Config
class Provisioner < Vagrant.plugin("2", :config)
attr_reader :options
attr_reader :trigger_body
def initialize
@options = {
:good_exit => [0],
:stderr => true,
:stdout => true
... | mit |
sasedev/acf-expert | src/Acf/ClientBundle/Form/Buy/UpdateTransactionStatusTForm.php | 1991 | <?php
namespace Acf\ClientBundle\Form\Buy;
use Acf\DataBundle\Entity\Buy;
use Symfony\Component\Form\AbstractType;
use Symfony\Component\Form\Extension\Core\Type\ChoiceType;
use Symfony\Component\Form\Extension\Core\Type\DateType;
use Symfony\Component\Form\FormBuilderInterface;
use Symfony\Component\OptionsResolver\O... | mit |
tentone/nunuStudio | source/editor/gui/tab/inspector/objects/controls/OrbitControlsInspector.js | 8049 | import {Locale} from "../../../../../locale/LocaleManager.js";
import {ChangeAction} from "../../../../../history/action/ChangeAction.js";
import {ActionBundle} from "../../../../../history/action/ActionBundle.js";
import {ObjectInspector} from "../ObjectInspector.js";
import {Editor} from "../../../../../Editor.js";
i... | mit |
milankinen/relei | src/setEndpoint.js | 260 | import RelayDefaultNetworkLayer from "react-relay/lib/RelayDefaultNetworkLayer"
import RelayNetworkLayer from "react-relay/lib/RelayNetworkLayer"
export default (endpoint) => {
RelayNetworkLayer.injectNetworkLayer(new RelayDefaultNetworkLayer(endpoint))
}
| mit |
jimboy3100/jimboy3100.github.io | server-side/socket-master/socket/views/monitor.js | 6789 | console.clear()
require['config']({
'context': '',
'paths': {
'bootstrap': 'https://cdn.ogario.ovh/static/js/bootstrap.min',
'jquery': 'https://cdnjs.cloudflare.com/ajax/libs/jquery/3.4.0/jquery.min',
'underscore': 'https://cdnjs.cloudflare.com/ajax/libs/underscore.js/1.9.1/underscore-min... | mit |