code stringlengths 3 1.01M | repo_name stringlengths 5 116 | path stringlengths 3 311 | language stringclasses 30
values | license stringclasses 15
values | size int64 3 1.01M |
|---|---|---|---|---|---|
<!doctype html>
<!--[if lt IE 7]><html class="no-js lt-ie9 lt-ie8 lt-ie7" lang="en"> <![endif]-->
<!--[if (IE 7)&!(IEMobile)]><html class="no-js lt-ie9 lt-ie8" lang="en"><![endif]-->
<!--[if (IE 8)&!(IEMobile)]><html class="no-js lt-ie9" lang="en"><![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en"><!--<!... | yanuartadityan/yanuartadityan.github.io | _layouts/post.html | HTML | mit | 2,710 |
module Main where
import Synonyms
import Test.Hspec
main :: IO ()
main = hspec $ do
let d = Definition "foo" ["b"] in
describe "lookupDefinition" $ do
it "returns Nothing when no matches" $
lookupDefinition "a" [d] `shouldBe` Nothing
it "returns Just Definition whe... | justincampbell/synonyms | Spec.hs | Haskell | mit | 720 |
//
// Klak - Utilities for creative coding with Unity
//
// Copyright (C) 2016 Keijiro Takahashi
//
// 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 wi... | atomicguy/codejam | MagentaMidiUnity/Assets/Klak/Wiring/Editor/Input/NoiseEditor.cs | C# | mit | 2,699 |
#include <stdio.h>
main()
{
char current_char = EOF;
while ((current_char = getchar()) != EOF)
{
if (current_char == '\t')
{
printf("\\t");
}
else if (current_char == '\b')
{
printf("\\b");
}
else if (current_char == '\\')
... | jhpy1024/CProgrammingLanguageExercises | exercise_1-10.c | C | mit | 445 |
package se.kjellstrand.colorclock.activity;
import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import se.kjellstrand.colorclock.R;
/**
* Opens up the native share dialog.
*/
public class ShareActivity extends Activity {
@Override
protected void onCreate(Bundle savedInsta... | carlemil/ColorClock | src/se/kjellstrand/colorclock/activity/ShareActivity.java | Java | mit | 671 |
# frozen_string_literal: true
require 'rubycritic/generators/text/lint'
module RubyCritic
module Generator
class LintReport
def initialize(analysed_modules)
@analysed_modules = analysed_modules
end
def generate_report
FileUtils.mkdir_p(generator.file_directory)
File.op... | whitesmith/rubycritic | lib/rubycritic/generators/lint_report.rb | Ruby | mit | 616 |
---
title: Deriving a Hopfield Network from The Bayesian Perspective
author: Akiva Lipshitz
date: June 28, 2017
layout: post
---
Hopfield Networks are models of content addressable memory. In other words, they are dynamical systems designed to encode $N$ arbitrary strings and then converge to a point of perfect recall... | theideasmith/theideasmith.github.io | _posts/2017-6-28-Deriving-A-Hopfield-Network-From-The-Bayesian-Perspective.md | Markdown | mit | 11,591 |
import {Injectable} from "@angular/core";
import {HttpClient} from './httpClient.service';
import {NotificationsService} from './notifications.service';
import {User} from '../models/user.model';
import {Team} from '../models/team.model';
import {Observable} from 'rxjs/Observable';
@Injectable()
export class T... | BartoszSiemienczuk/teamsuite | public/app/services/team.service.ts | TypeScript | mit | 2,602 |
---
uid: SolidEdgeFrameworkSupport.FeatureControlFrame.CompositePrimaryAndSecondaryText
summary:
remarks:
---
| SolidEdgeCommunity/docs | docfx_project/apidoc/SolidEdgeFrameworkSupport.FeatureControlFrame.CompositePrimaryAndSecondaryText.md | Markdown | mit | 115 |
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ActiveCollabTracSync.Entities.ActiveCollab
{
/// <summary>
///
/// </summary>
public class Project
{
/// <summary>Gets or sets the identifier.</summary>
//... | sfarbota/activecollab-trac-sync | ActiveCollabTracSync/Entities/ActiveCollab/Project.cs | C# | mit | 1,166 |
require_relative '../../../../automated_init'
context "Write" do
context "Substitute" do
context "Message" do
context "Initial" do
message = Controls::Message.example
stream_name = Controls::StreamName.example(category: 'testSubstituteWrite')
writer = Write::Substitute.build
... | eventide-project/messaging | test/automated/write/substitute/message/write/initial.rb | Ruby | mit | 549 |
# -*- coding: utf-8 -*-
# Copyright (C) 2013 Michael Hogg
# This file is part of bonemapy - See LICENSE.txt for information on usage and redistribution
import bonemapy
from distutils.core import setup
setup(
name = 'bonemapy',
version = bonemapy.__version__,
description = 'An ABAQUS plug-in to map bo... | mhogg/bonemapy | setup.py | Python | mit | 2,237 |
// Copyright (c) 2010-present Bifrost Entertainment AS and Tommy Nguyen
// Distributed under the MIT License.
// (See accompanying file LICENSE or copy at http://opensource.org/licenses/MIT)
#include "Graphics/SpriteBatch.h"
#include "Script/GameBase.h"
using rainbow::GameBase;
using rainbow::SpriteBatch;
using rain... | tn0502/rainbow | src/Graphics/SpriteBatch.cpp | C++ | mit | 5,164 |
<?php
namespace Symbiose\Component\Caching\Backend;
use Zend\Cache\Backend\File as BaseFile;
class File
extends BaseFile
{
/**
* Make and return a file name (with path)
*
* @param string $id Cache id
* @return string File name (with path)
*/
public function getFile($id)
{
return pa... | mbideau/Symbiose | src/Symbiose/Component/Caching/Backend/File.php | PHP | mit | 342 |
const {CookieJar} = require('tough-cookie');
const {cookieToString, jarFromCookies, cookiesFromJar} = require('..');
describe('jarFromCookies()', () => {
it('returns valid cookies', done => {
const jar = jarFromCookies([{
key: 'foo',
value: 'bar',
domain: 'google.com'
}]);
jar.store.ge... | floatinglacier/mastercard-api-explorer | packages/insomnia-cookies/__tests__/index.test.js | JavaScript | mit | 1,918 |
/*
**
** File: mission8.h
**
** Author: Adam Davison
**
** Description:
** Header file for the training library "Mission Nan" interface.
**
** History:
*/
#ifndef _MISSION_NAN_H_
#define _MISSION_NAN_H_
#ifndef _TRAINING_MISSION_H_
#include "TrainingMission.h"
#endif
#ifndef _GOAL_H_
#include "Goal.h"
#end... | AllegianceZone/Allegiance | src/training/mission8.h | C | mit | 1,521 |
---
layout: post
title: Version One Prototype Shipped to Uganda
published: true
---

<div class="message"> Pictured: Dr. Blachut and Dr. O'Brien introduce the V1 Screw Cutter to hopeful Ugandan surgeons.</div>
Th... | ScrewCutter/screwcutter.github.io | _posts/2014-05-01-first-uganda-prototype.md | Markdown | mit | 1,034 |
import React from 'react';
import { connect } from 'react-redux';
import { browserHistory } from 'react-router';
import { recosActions } from '../../core/recos';
import { getRecommenders, getReco } from '../../core/recos';
import { isEditing } from '../../core/loading';
import Header from '../Header';
import TextField... | pacog/recoreco | app/containers/EditReco/index.js | JavaScript | mit | 4,199 |
using DragonSpark.Model.Selection;
using System.Security.Claims;
namespace DragonSpark.Application.Security.Identity.Claims.Access;
public interface IAccessClaim<T> : ISelect<ClaimsPrincipal, Claim<T>> {} | DragonSpark/Framework | DragonSpark.Application/Security/Identity/Claims/Access/IAccessClaim.cs | C# | mit | 209 |
#!python
import re
import sys
import logging
import boto.ec2
from texttable import Texttable
from pprint import PrettyPrinter
from optparse import OptionParser
PP = PrettyPrinter( indent=2 )
###################
### Arg parsing
###################
parser = OptionParser("usage: %prog [options]" )
parser.add_... | jib/aws-analysis-tools | instances.py | Python | mit | 6,405 |
def read_data(file_name):
return pd.read_csv(file_name)
def preprocess(data):
# Data Preprocessing
data['GDP_scaled']=preprocessing.scale(data['GDP'])
data['CLPRB_scaled']=preprocessing.scale(data['CLPRB'])
data['EMFDB_scaled']=preprocessing.scale(data['EMFDB'])
data['ENPRP_scaled']=preproces... | uwkejia/Clean-Energy-Outlook | examples/Extra/Codes/SVR_nuclear.py | Python | mit | 1,586 |
package models
import (
"database/sql/driver"
"errors"
"fmt"
"time"
)
const (
// DefaultLimit is the number of results we will return per page if the user doesn't specify another amount
DefaultLimit = 25
// DefaultLimitString is DefaultLimit but in string form because types are a thing
DefaultLimitString = "2... | dairycart/dairycart | models/v1/helper_types.go | GO | mit | 2,468 |
package ch.jalu.injector.demo;
import ch.jalu.injector.Injector;
import ch.jalu.injector.InjectorBuilder;
import java.math.RoundingMode;
/**
* Small demo showing how an injector can be used to wire up an application.
* <p>
* In this entry point of the app, we only care about getting {@link CalculationService}.
*... | ljacqu/DependencyInjector | injector/src/test/java/ch/jalu/injector/demo/MyApp.java | Java | mit | 1,293 |
#ifndef _EASYPSEUDO3D_H_
#define _EASYPSEUDO3D_H_
#include "libpseudo3d/config.h"
#include "libpseudo3d/StageCanvas3D.h"
#include "libpseudo3d/StageCanvas2D.h"
#include "libpseudo3d/Proj2DEditOP.h"
#endif // _EASYPSEUDO3D_H_ | xzrunner/easyeditor | easypseudo3d/src/easypseudo3d.h | C | mit | 226 |
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="de">
<head>
<title>kosmotique fördern</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<style>body { width: 800p... | kosmotique/kosmotique.org | support/howto.html | HTML | mit | 2,831 |
package com.optimaize.webcrawlerverifier.bots;
import com.google.common.collect.ImmutableList;
import org.testng.annotations.Test;
import static org.testng.Assert.*;
public class GooglebotDataTest {
@Test
public void testGetIdentifier() throws Exception {
assertEquals(GooglebotData.getInstance().get... | optimaize/webcrawler-verifier | src/test/java/com/optimaize/webcrawlerverifier/bots/GooglebotDataTest.java | Java | mit | 932 |
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" con... | enotio/Tempest | docs/struct_window_1_1_drag_gesture_recognizer.html | HTML | mit | 8,494 |
! 7.53
! Записать нули на места элементов, образованных пересечением главной и побочной диагоналей
! у верхних треугольных матрицы Z и Y
program ex_7_53
implicit none
integer, allocatable :: Z(:,:)
integer :: In, Out, size_of_Z, i, column, k
character(*), parameter :: output_file = "out... | taxnuke/fortranlabs | ex_7_53/src/ex_7_53.f90 | FORTRAN | mit | 992 |
body {
background: #fff;
}
.pipe {
color: #eee;
display: inline-block;
width: 20px;
text-align: center;
}
ul,
ul li {
list-style-type: none;
margin: 0;
overflow: hidden;
}
ul .btn,
ul li .btn {
margin-left: 2px;
}
ul .done,
ul li .done {
color: #aaa;
text-decoration: line-through;
font-style: it... | sagish/compound-angular-todo | public/stylesheets/application.css | CSS | mit | 612 |
using System;
using System.Collections.Generic;
using GenerateLocationData.Model;
using Npgsql;
namespace GenerateLocationData.BAG
{
public class BagFilter
{
private const string Query =
@"SELECT DISTINCT openbareruimtenaam as straat
FROM (SELECT ST_GeomFromText('{0}', 28992) as buurt) as foo, adres
W... | TNOCS/csTouch | services/LocatorService/GenerateLocationData/BAG/BagFilter.cs | C# | mit | 1,925 |
package main
// github.com/cheggaaa/pb
import (
"fmt"
"os"
"path/filepath"
"strconv"
"time"
"github.com/cavaliercoder/grab"
"github.com/fatih/color"
"github.com/gosuri/uilive"
rss "github.com/jteeuwen/go-pkg-rss"
)
func getRss(podcast *Podcast) (*rss.Feed, error) {
feed := rss.New(1, true, nil, nil)
if ... | vali3nt/gopoddl | download.go | GO | mit | 6,430 |
package cn.drct.wepay.exception;
public class TradeException extends Exception {
/**
*
*/
private static final long serialVersionUID = -4735172784989026754L;
private String msg;
public TradeException(String code,String msg){
super(code);
this.msg=msg;
}
public String getMsg() {
re... | sunzy07/cn.drct.wepay | src/main/java/cn/drct/wepay/exception/TradeException.java | Java | mit | 398 |
#ifndef CAFFE_ARRAY_BASE_HPP_
#define CAFFE_ARRAY_BASE_HPP_
#include <string>
#include <vector>
#include "caffe/array/math_functions.hpp"
#include "caffe/proto/caffe.pb.h"
#include "caffe/syncedmem.hpp"
namespace std {
// Print function for ArrayShape
ostream &operator<<(ostream &os, const vector<int> &shape);
}
name... | tinghuiz/learn-reflectance | caffe/include/caffe/array/base.hpp | C++ | mit | 4,489 |
<?php
// Include the API
require '../../lastfmapi/lastfmapi.php';
// Get the session auth data
$file = fopen('../auth.txt', 'r');
// Put the auth data into an array
$authVars = array(
'apiKey' => trim(fgets($file)),
'secret' => trim(fgets($file)),
'username' => trim(fgets($file)),
'sessionKey' => trim(fgets($file... | albertyw/6.470 | src/process/lastfmapi/examples/user.gettoptracks/index.php | PHP | mit | 861 |
package com.topology.impl.importers.sndlib;
import com.topology.impl.primitives.LinkImpl;
import com.topology.impl.primitives.NetworkElementImpl;
import com.topology.impl.primitives.TopologyManagerImpl;
import com.topology.importers.ImportTopology;
import com.topology.primitives.TopologyManager;
import com.topology.pr... | mohitc/NetworkTopologyDatastore | topology-importers/src/test/java/com/topology/impl/importers/sndlib/SndLibImportTest.java | Java | mit | 3,152 |
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>JSDoc: Source: utils/schema.js</title>
<script src="scripts/prettify/prettify.js"> </script>
<script src="scripts/prettify/lang-css.js"> </script>
<!--[if lt IE 9]>
<script src="//html5shiv.googlecode.com/svn/trunk/html5.js... | korzio/djv | docs/auto/utils_schema.js.html | HTML | mit | 3,714 |
/*
* Copyright (c) 2014 Roman Kuznetsov
*
* 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, modify, merge, pu... | rokuz/DemoOpenGL | demo/framework/utils.cpp | C++ | mit | 1,880 |
package com.xinyuan.pub.business.bi.dao.impl;
import com.xinyuan.pub.business.bi.dao.BiHrPersonCntDao;
import com.xinyuan.pub.dao.BiBaseDao;
import com.xinyuan.pub.model.business.bi.po.BiHrPersonCnt;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Repository;
import java... | mrajian/xinyuan | xinyuan-parent/xinyuan-pub-parent/xinyuan-pub-dao/src/main/java/com/xinyuan/pub/business/bi/dao/impl/BiHrPersonCntDaoImpl.java | Java | mit | 916 |
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
// ReSharper disable CheckNamespace
using System.Collections.Generic;
using System.Collections.Immutable;
using Sy... | mafiya69/corefx | src/System.Collections.Immutable/src/System/Linq/ImmutableArrayExtensions.cs | C# | mit | 30,414 |
---
title: Can the same organization submit multiple proposals?
published: True
tags: [small_grants_fund]
categories: [faqs]
layout: post
---
<div class="content">
<p>Yes.</p>
</div> | Vizzuality/gfw-howto | _posts/01-01-01-faq-sgf-can-the-same-organization-submit-multiple-proposals.md | Markdown | mit | 183 |
var fs = require('fs')
var path = require('path')
module.exports.getConfig = getConfig
var env = process.env.NODE_ENV || 'development'
var configDirs = fs.readdirSync(path.resolve(__dirname, '../config'))
var configObj = {}
configDirs.forEach(function(dirName) {
if (dirName.indexOf('.') !== 0) {
// skip hidde... | kenspirit/generator-evergrow | generators/app/templates/system/config-manager.js | JavaScript | mit | 496 |
using System.Collections;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using Xe.BinaryMapper;
namespace OpenKh.Kh2.Mixdata
{
public class BaseMixdata<T> : IEnumerable<T>
where T : class
{
[Data] public int MagicCode { get; set; }
[Data] public int Version { get... | Xeeynamo/KingdomHearts | OpenKh.Kh2/Mixdata/BaseMixdata.cs | C# | mit | 1,518 |
package com.swfarm.biz.chain.bo;
import java.io.Serializable;
public class NamedPriceAdjustmentStep implements Serializable {
private Long id;
private String code;
private String name;
private String defaultSfmCode;
private String defaultBuyerCountry;
private String planName;
private D... | zhangqiang110/my4j | pms/src/main/java/com/swfarm/biz/chain/bo/NamedPriceAdjustmentStep.java | Java | mit | 2,423 |
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Coq bench</title>
<link rel="shortcut icon" type="image/png" href="../../../../../favicon.png" />
<link href="../../../../../bootstrap.min.css" rel="stylesheet... | coq-bench/coq-bench.github.io-old | clean/Linux-x86_64-4.02.1-1.2.0/unstable/8.5beta1/contrib:jprover/dev/2015-02-03_21-08-42.html | HTML | mit | 7,839 |
# Docker-specific local settings
import os
DEBUG = True
TEMPLATE_DEBUG = DEBUG
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.sqlite3',
'NAME': 'db',
}
}
# Make this unique, and don't share it with anybody.
SECRET_KEY = ''
TEMPLATE_DIRS = (
'/srv/webldap/templates',
)
EMAIL_F... | FedeRez/webldap | app/webldap/local_settings.docker.py | Python | mit | 764 |
module EffectiveEmailTemplates
VERSION = '1.1.3'.freeze
end
| code-and-effect/effective_email_templates | lib/effective_email_templates/version.rb | Ruby | mit | 62 |
---
description: Enable AMP in a page, and control the way Next.js adds AMP to the page with the AMP config.
---
# next/amp
<details>
<summary><b>Examples</b></summary>
<ul>
<li><a href="https://github.com/vercel/next.js/tree/canary/examples/amp">AMP</a></li>
</ul>
</details>
> AMP support is one of our ad... | flybayer/next.js | docs/api-reference/next/amp.md | Markdown | mit | 2,461 |
/*
* print_chart.h
* Kevin Coltin
*
* Contains functions for printing a chart of blackjack strategy to Latex.
*/
#ifndef PRINT_CHART_H
#define PRINT_CHART_H
#include <stdio.h>
#include "bj_sims.h"
#include "bj_strat.h"
void printChart (Strategy **chart, const char *filename, int showWinPct,
... | kcoltin/blackjack | include/print_chart.h | C | mit | 668 |
package io.github.tiscs.demos.oauth2.providers;
import io.github.tiscs.demos.oauth2.entities.UserAccountEntity;
import io.github.tiscs.demos.oauth2.entities.UserCredentialEntity;
import io.github.tiscs.demos.oauth2.repositories.UserAccountRepository;
import io.github.tiscs.demos.oauth2.repositories.UserCredentialRepos... | Tiscs/spring-cloud-oauth2-demo | oauth2-server/src/main/java/io/github/tiscs/demos/oauth2/providers/JpaUserDetailsService.java | Java | mit | 2,077 |
<!DOCTYPE html>
<html>
<head>
<title>Dan at EDA</title>
<meta charset="UTF-8">
<link href="https://fonts.googleapis.com/css?family=Average|Fugaz+One|Lusitana" rel="stylesheet">
<!-- Skeleton Normalize -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/3.0.3/normalize... | daniel-reason/daniel-reason.github.io | blog/t2-html-css-dom-p1.html | HTML | mit | 3,469 |
/**
* Copyright (c) 2015 Alexandre Vaillancourt. See full MIT license at the root of the repository.
*/
#pragma once
#include <stdint.h>
class DirtMap
{
public:
DirtMap(
float aWorldWidth,
float aWorldHeight,
int aCanvasWidth,
int aCanvasHeight,
float aDirtRate);
~DirtMap();
void ... | vaillancourt/patrol | src/DirtMap.h | C | mit | 848 |
describe "Build Manager" do
describe ".truncate_changelog" do
it "Truncates Changelog" do
changelog = File.read("./pilot/spec/fixtures/build_manager/changelog_long")
changelog = Pilot::BuildManager.truncate_changelog(changelog)
expect(changelog).to eq(File.read("./pilot/spec/fixtures/build_manag... | manuyavuz/fastlane | pilot/spec/build_manager_spec.rb | Ruby | mit | 17,148 |
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
<head profile="http://gmpg.org/xfn/11">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta name="show-menu-auto-ar... | oceanmatters/static-site | rain-rain-go-away/group1/index.html | HTML | mit | 20,237 |
# -*- coding: utf-8 -*-
# Copyright (c) 2017-2020 Richard Hull and contributors
# See LICENSE.rst for details.
"""
Simplified sprite animation framework.
.. note:: This module is an evolving "work-in-progress" and should be treated
as such until such time as this notice disappears.
"""
from time import sle... | rm-hull/luma.core | luma/core/sprite_system.py | Python | mit | 8,896 |
'use strict'
const { test } = require('tap')
const Fastify = require('..')
const {
codes: {
FST_ERR_DEC_ALREADY_PRESENT,
FST_ERR_MISSING_MIDDLEWARE
}
} = require('../lib/errors')
test('Should throw if the basic use API has not been overridden', t => {
t.plan(1)
const fastify = Fastify()
try {
f... | mcollina/fastify | test/middleware.test.js | JavaScript | mit | 1,311 |
// Description: Async extension methods for LINQ (Language Integrated Query).
// Website & Documentation: https://github.com/zzzprojects/LINQ-Async
// Forum: https://github.com/zzzprojects/LINQ-Async/issues
// License: http://www.zzzprojects.com/license-agreement/
// More projects: http://www.zzzprojects.com/
// Copyr... | zzzprojects/LINQ-Async | src/Z.Linq.Async.Shared/EnumerableAsync/AsyncOrderedEnumerable`.cs | C# | mit | 1,695 |
import React from "react";
import { storiesOf } from "@storybook/react";
import { withKnobs, boolean } from "@storybook/addon-knobs";
import centered from "@storybook/addon-centered/react";
import DarkModeKnobWrapper from "./DarkModeKnobWrapper";
import Heart from "../components/dots/Heart";
import Pride from "../com... | Mathspy/binary-clock | src/stories/dots.stories.js | JavaScript | mit | 1,037 |
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
def populate_target_amount(apps, schema_editor):
Entry = apps.get_model("momentum", "Entry")
for entry in Entry.objects.all():
entry.target_amount = entry.goal.target_amount
entry.save()
... | mod2/momentum | momentum/migrations/0010_target_data_migration.py | Python | mit | 517 |
# FileMessage - simple class to write a message
class FileMessage
attr_reader :message_name
def initialize(message_name)
@message_name = message_name
end
def write_message(queue_location, message)
File.open(queue_location + '/' + @message_name, 'w') do |file|
file.puts message
end
end
end
| m1ckr1sk/FileMQ | lib/file_message.rb | Ruby | mit | 319 |
io.stdout:setvbuf("no") --For console output
Loader = require("Loader")
--====CONFIG START====--
--Note: Make sure that your images are pngs.
_Path = "/ExampleObjects/"
_SheetName = "ExampleObjects.json"
_ObjectsNames = {"AlienBeige","AlienBlue","AlienPink","DebrisGlass","DebrisStone","DebrisWood","Explosive"} --Fi... | RamiLego4Game/Love2D-PhysicsEditor-Library | main.lua | Lua | mit | 5,845 |
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> Partial Class frmpricechange
#Region "Windows Form Designer generated code "
<System.Diagnostics.DebuggerNonUserCode()> Public Sub New()
MyBase.New()
'This call is required by the Windows Form Designer.
InitializeComponent()
End Sub
'Fo... | nodoid/PointOfSale | VB/4PosBackOffice.NET/frmpricechange.Designer.vb | Visual Basic | mit | 10,918 |
// Copyright (c) 2018-2019 The Bitcoin developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include <script/sigencoding.h>
#include <script/script_flags.h>
#include <test/lcg.h>
#include <test/test_bitcoin.h>
#include ... | ftrader-bitcoinabc/bitcoin-abc | src/test/sigencoding_tests.cpp | C++ | mit | 22,601 |
/*
* Copyright (C) The Apache Software Foundation. All rights reserved.
*
* This software is published under the terms of the Apache Software
* License version 1.1, a copy of which has been included with this
* distribution in the LICENSE.APL file. */
// Contibutors: "Luke Blanshard" <Luke@quiq.com>
// ... | pitpitman/GraduateWork | jakarta-log4j-1.1.3/src/java/org/apache/log4j/PropertyConfigurator.java | Java | mit | 23,774 |
define(function(require) {
/**
* The Promises/A+ compliance test suite
*
* Converted from https://github.com/promises-aplus/promises-tests
* Thanks @domenic and A+ team for this massive work!
**/
require('spec/base/promiseSpec/aplus/2.1.2');
require('spec/base/promiseSpec/aplus/2.1.3');
require('s... | Ptico/beejs | test/specs/base/promiseSpec/aplus.js | JavaScript | mit | 840 |
# Knex 튜토리얼
Node.js를 통해 MySQL을 이용하는 방법에는 아래와 같이 여러 가지가 있습니다.
1. 쿼리를 직접 작성한 후 실행 ([mysql](https://www.npmjs.com/package/mysql), ...)
2. 쿼리 빌더를 통해서 쿼리 실행 ([Knex.js](http://knexjs.org/), [Squel.js](https://hiddentao.com/squel/), ...)
3. ORM(Object)을 통해서 쿼리 실행 ([Sequelize](http://docs.sequelizejs.com/), [Bookshelf.js](ht... | hsootree/TIL | Knex/README.md | Markdown | mit | 1,742 |
import React from 'react'
import { Image, Reveal } from 'shengnian-ui-react'
const RevealExampleHidden = () => (
<Reveal animated='small fade'>
<Reveal.Content visible>
<Image src='/assets/images/wireframe/square-image.png' size='small' />
</Reveal.Content>
<Reveal.Content hidden>
<Image src=... | shengnian/shengnian-ui-react | docs/app/Examples/elements/Reveal/Content/RevealExampleHidden.js | JavaScript | mit | 446 |
package org.usfirst.frc.team2503.r2016.subsystem;
import org.usfirst.frc.team2503.r2016.subsystem.base.DataSpeedControllerSubsystem;
import org.usfirst.frc.team2503.r2016.subsystem.base.DataSubsystem;
import edu.wpi.first.wpilibj.SpeedController;
public class RhinoTrackSubsystem extends DataSpeedControllerSubsystem ... | frc2503/r2016 | src/org/usfirst/frc/team2503/r2016/subsystem/RhinoTrackSubsystem.java | Java | mit | 987 |
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head profile="http://selenium-ide.openqa.org/profiles/test-case">
<meta http-equiv="Content-Type" cont... | MarijaJankovic623/PSI_Implementacija | tests_selenium/Test3-MarijaJankovic.html | HTML | mit | 1,613 |
/* global appSettings */
var
$result,
$resultContainer,
$resultsButton,
$resultsPane,
$renderingLabel,
$window = $(window),
path = require('path'),
_ = require('lodash'),
isEnabled = true,
messenger = require(path.resolve(__dirname, '../messenger')),
renderer = require(path... | Tasarinan/dockWriter | app/modules/results/index.js | JavaScript | mit | 5,811 |
<?php $this->load->view('partials/mdb-header') ?>
<<<<<<< HEAD
<!-- /.Primary Style Header -->
<div class="wrapper">
<div class="outer">
<div class="row">
<!-- <div class="col-lg-12"> -->
<div class="jumbotron">
<h1 class="h1-responsive">Latihan</h1>
<hr class="my-2">
... | aisy/polieditor | application/views/errors/latihan.php | PHP | mit | 2,213 |
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using System.Security.Claims;
using Microsoft.AspNet.Authorization;
using Microsoft.AspNet.Identity;
using Microsoft.AspNet.Mvc;
using Microsoft.Extensions.Logging;
using MyWebPlayground.Models;
using MyWebPlayground.Servic... | planset/MyWebPlayground | Controllers/ManageController.cs | C# | mit | 13,295 |
namespace PickUp.Web
{
using System;
using Microsoft.AspNet.Identity;
using Microsoft.AspNet.Identity.Owin;
using Microsoft.Owin;
using Microsoft.Owin.Security.Cookies;
using Owin;
using PickUp.Data;
using PickUp.Data.Models;
public partial class Startup
{
// For more i... | ivanvasilev/PickUp | Source/Web/PickUp.Web/App_Start/Startup.Auth.cs | C# | mit | 2,929 |
package repl
// Create creates . . . something
func (shell *Shell) Create(args []string) (string, error) {
if !shell.IsConnected() {
return "", ErrNotConnected
}
return "", nil
}
| hoop33/elasticprompt | repl/create.go | GO | mit | 185 |
/**
* @license Angular v4.2.6
* (c) 2010-2017 Google, Inc. https://angular.io/
* License: MIT
*/
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/common'), require('@angular/core'), require('rxjs/BehaviorSubject'), require('rxjs/Subject... | batimiasu/angular-tour-of-heroes | node_modules/@angular/router/bundles/router.umd.js | JavaScript | mit | 220,558 |
(function(forp, $){
/**
* BarChart Class
*/
forp.BarChart = function(conf) {
forp.Graph.call(this, conf);
this.tmp = null;
this.restore = function() {
if(this.tmp) {
this.ctx.clearRect(0, 0, this.element.width, this.element.height);
... | aterrien/forp-ui | src/js/lib/view/indicator/barchart.js | JavaScript | mit | 2,948 |
const Parse = require('./parser');
describe('test_parse', () => {
describe('test_parse_key_values', () => {
it('should return the key values specified in the config from the body', () => {
const config = {
keys: ['to', 'from'],
};
const request = {
body: {
to: 'inbound... | sendgrid/sendgrid-nodejs | packages/inbound-mail-parser/src/parser.spec.js | JavaScript | mit | 2,789 |
/*
* Swaggy Jenkins
* Jenkins API clients generated from Swagger / Open API specification
*
* The version of the OpenAPI document: 1.1.2-pre.0
* Contact: blah@cliffano.com
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edi... | cliffano/swaggy-jenkins | clients/java-micronaut-client/generated/src/main/java/org/openapitools/model/GithubRespositoryContainer.java | Java | mit | 5,141 |
/* tslint:disable max-line-length */
import { TestBed, getTestBed } from '@angular/core/testing';
import { HttpClientTestingModule, HttpTestingController } from '@angular/common/http/testing';
import { HttpClient, HttpResponse } from '@angular/common/http';
import { of } from 'rxjs';
import { take, map } from 'rxjs/ope... | ls1intum/ArTEMiS | src/test/javascript/spec/app/entities/course/course.service.spec.ts | TypeScript | mit | 5,874 |
#ifndef BITCOINGUI_H
#define BITCOINGUI_H
#include <QMainWindow>
#include <QSystemTrayIcon>
#include <QMap>
class TransactionTableModel;
class WalletFrame;
class WalletView;
class ClientModel;
class WalletModel;
class WalletStack;
class TransactionView;
class OverviewPage;
class AddressBookPage;
class SendCoinsDialog... | dollarcoins/source | src/qt/bitcoingui.h | C | mit | 6,623 |
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<title>User agent detail - Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_2) AppleWebKit/536.26.14 (KHTML, like Gecko)</title>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/materialize/0.97.3/css/mater... | ThaDafinser/UserAgentParserComparison | v5/user-agent-detail/b1/8c/b18cc71b-79da-41f5-8fcf-fa20e7103d76.html | HTML | mit | 52,694 |
import com.mongodb.client.MongoCollection;
import com.mongodb.client.MongoDatabase;
import static com.mongodb.client.model.Filters.*;
import com.mongodb.client.result.UpdateResult;
import org.bson.Document;
import org.bson.conversions.Bson;
import java.util.ArrayList;
import java.util.GregorianCalendar;
import java.u... | bbb1991/java_spark_example | src/main/java/BlogPostDAO.java | Java | mit | 3,172 |
package org.herrdommel;
import org.apache.catalina.Context;
import org.apache.catalina.connector.Connector;
import org.apache.tomcat.util.descriptor.web.SecurityCollection;
import org.apache.tomcat.util.descriptor.web.SecurityConstraint;
import org.springframework.beans.factory.annotation.Value;
import org.springframe... | herrdommel/spring-boot-seed | src/main/java/org/herrdommel/TomcatHttpsConfig.java | Java | mit | 2,064 |
<?php
declare(strict_types=1);
namespace Doctrine\Tests\ORM\Functional\Ticket;
use Doctrine\Deprecations\PHPUnit\VerifyDeprecations;
use Doctrine\ORM\Mapping\Column;
use Doctrine\ORM\Mapping\Entity;
use Doctrine\ORM\Mapping\GeneratedValue;
use Doctrine\ORM\Mapping\Id;
use Doctrine\ORM\Mapping\MappedSuperclass;
use D... | doctrine/doctrine2 | tests/Doctrine/Tests/ORM/Functional/Ticket/DDC1404Test.php | PHP | mit | 3,287 |
#ifndef _KERNEL_VESA_H_
#define _KERNEL_VESA_H_
#include <Kernel/Kernel.h>
struct VbeInfo
{
char Signature[4];
struct
{
u8 Minor;
u8 Major;
} Version;
u16 Oem[2];
u8 Capabilities[4];
u16 VideoModes[2];
u16 TotalMemory;
};
struct VbeModeInfo
{
u16 Attribut... | jbatonnet/system | Source/Kernel/Devices/Drivers/VESA/VESA.h | C | mit | 1,033 |
<div data-tabs-text='TabContainer' class='sc-tabs--with-text'>
<button class="sc-inline-link sc-tab sc-tab--with-text--active sc-font-m" data-section='Tab1'>Tab 1</button>
<div class='sc-tabs__content sc-tabs__content--visible' data-section='Tab1'>
<p>Tab 1 Content</p>
<a href='#'>Link</a>
<... | AutoScout24/showcar-ui | src/06-components/atoms/tabs/docs/tabs-text.html | HTML | mit | 3,110 |
var Connection = require(['tedious']).Connection;
var config = {
userName: 'masproject2017',
password: 'MAS.2017',
server: 'masproject.database.windows.net',
// If you are on Microsoft Azure, you need this:
options: { encrypt: true, database: 'AdventureWorks' }
};
var connection = new Conn... | DamnDaniel7/MAS-PROJECT | js/main.js | JavaScript | mit | 459 |
<?php
namespace ApiExport\Module\App\Model\DTO\Filter;
/**
* Class FeedItem.
*/
class FeedItem
{
/** @var int */
public $id;
/** @var int */
public $feedId;
/** @var string */
public $hash;
/** @var \DateTime */
public $startDate;
/** @var \DateTime */
public $endDate;
... | UbikZ/api-export | src/Module/App/Model/DTO/Filter/FeedItem.php | PHP | mit | 544 |
---
path: '/building-with-gatsby'
date: '2017-08-19T20:51:00.000Z'
title: 'Building with Gatsby.js'
tags:
- code
- gatsby
- shiny
---
I've always been fascinated by static sites — there's something alluring about building a site and being able to deploy it anywhere, without worrying about web middleware, scaling... | chrisvoll/chrisvolldotcom | src/posts/08-19-2017-build-with-gatsby/index.md | Markdown | mit | 5,205 |
package basic;
import java.util.Arrays;
/**
* Created by bonismo
* 14/10/12 上午10:35
*/
public class HelloWord {
public static void main(String[] args) {
System.out.println("Hello,World!");
System.out.println("Hello,Java");
// ASCII 排序
System.out.println((char) 1);
Syste... | StayHungryStayFoolish/stayhungrystayfoolish.github.com | JavaSE/src/main/java/basic/HelloWord.java | Java | mit | 635 |
using System;
using System.Diagnostics;
namespace Martini
{
[DebuggerDisplay("Type = {Type} Token = {_token}")]
internal class Token
{
private string _token;
public Token(string token)
{
_token = token;
}
public Token(char token) : this(token.ToString()... | he-dev/Martini | Martini/_Codebase/_data/Token.cs | C# | mit | 1,854 |
/* Standard CSS */
body
{
margin: 0px;
}
#foot
{
background-color:#D0D0D0;
width: 100%;
height: 50px;
position:absolute; /* added */
bottom:0; /* added */
left:0; /* added */
... | ReneFGJ/Brapci | css/prj_style.css | CSS | mit | 1,122 |
// This file was generated based on 'C:\ProgramData\Uno\Packages\UnoCore\0.13.2\Source\Uno\Compiler\ShaderGenerator\$.uno'.
// WARNING: Changes might be lost if you edit this file directly.
#ifndef __APP_UNO_COMPILER_SHADER_GENERATOR_SHADER_STAGE_INLINE_ATTRIBUTE_H__
#define __APP_UNO_COMPILER_SHADER_GENERATOR_SHADER_... | blyk/BlackCode-Fuse | AndroidUI/.build/Simulator/Android/include/app/Uno.Compiler.ShaderGenerator.ShaderStageInlineAttribute.h | C | mit | 981 |
package eu.bcvsolutions.idm.core.security.evaluator.role;
import java.util.Set;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Description;
import org.springframework.stereotype.Component;
import org.springframework.util.Assert;
import eu.bcvsolutions.idm... | bcvsolutions/CzechIdMng | Realization/backend/core/core-impl/src/main/java/eu/bcvsolutions/idm/core/security/evaluator/role/RequestByWfInvolvedIdentityEvaluator.java | Java | mit | 2,221 |
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>higman-s: Not compatible 👼</title>
<link rel="shortcut icon" type="image/png" href="../../../../../favicon.png" />
<link href="../../../../../bootstrap.min.cs... | coq-bench/coq-bench.github.io | clean/Linux-x86_64-4.07.1-2.0.6/extra-dev/8.10.0/higman-s/8.8.0.html | HTML | mit | 7,000 |
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>coinductive-reals: Not compatible 👼</title>
<link rel="shortcut icon" type="image/png" href="../../../../../favicon.png" />
<link href="../../../../../bootstr... | coq-bench/coq-bench.github.io | clean/Linux-x86_64-4.02.3-2.0.6/released/8.8.1/coinductive-reals/8.7.0.html | HTML | mit | 7,430 |
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>tree-diameter: Not compatible 👼</title>
<link rel="shortcut icon" type="image/png" href="../../../../../favicon.png" />
<link href="../../../../../bootstrap.m... | coq-bench/coq-bench.github.io | clean/Linux-x86_64-4.05.0-2.0.1/released/8.6.1/tree-diameter/8.7.0.html | HTML | mit | 7,207 |
# Satyr
_This handsome, grinning man has the furry legs of a goat and a set of curling ram horns extending from his temples._
**Satyr CR 4**
**XP 1,200**
CN Medium [fey](creatureTypes#_fey)
**Init** +2; **Senses** low-light vision; [Perception](../skills/perception#_perception) +18
**Defense**
**AC** 18, touch 1... | brunokoga/pathfinder-markdown | prd_markdown/monsters/satyr.md | Markdown | mit | 4,391 |
/**
* Config Interface
*/
"use strict";
/* Node modules */
/* Third-party modules */
/* Files */
export interface IConfigInterface {
url: string;
mongoOptions?: {
uri_decode_auth?: boolean;
db?: any;
server?: any;
replSet?: any;
mongos?: any;
promiseLib... | riggerthegeek/steeplejack-mongodb | lib/configInterface.ts | TypeScript | mit | 796 |
declare namespace java {
namespace awt {
namespace image {
abstract class RGBImageFilter extends java.awt.image.ImageFilter {
protected origmodel: java.awt.image.ColorModel
protected newmodel: java.awt.image.ColorModel
protected canFilterIndexColorModel: boolean
public const... | wizawu/1c | @types/jdk/java.awt.image.RGBImageFilter.d.ts | TypeScript | mit | 1,665 |
#include <stdio.h>
#include <stdlib.h>
void next_generation(int *current, int *next, int length);
int main()
{
int i, j, sum;
int n,current[20], next[20];
do{
scanf("%d", &n);
}while(n < 0 && n > 20);
for(i=0;i<n;i++)
scanf(" %d", ¤t[i]);
next[0]=0;
next[n-1]=0;
... | Ivan-Killer/po-homework | 2015-2016/A/07/05/task2.c | C | mit | 1,143 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.