identifier
stringlengths
42
383
collection
stringclasses
1 value
open_type
stringclasses
1 value
license
stringlengths
0
1.81k
date
float64
1.99k
2.02k
title
stringlengths
0
100
creator
stringlengths
1
39
language
stringclasses
157 values
language_type
stringclasses
2 values
word_count
int64
1
20k
token_count
int64
4
1.32M
text
stringlengths
5
1.53M
__index_level_0__
int64
0
57.5k
https://github.com/jceverritt/AngularFun-master/blob/master/src/scripts/controllers/gitHubController.coffee
Github Open Source
Open Source
MIT
null
AngularFun-master
jceverritt
CoffeeScript
Code
21
81
class Controller constructor: (@$log, @gitHubService) -> @search = (searchTerm) => @gitHubService.get(searchTerm).then (results) => @repos = results angular.module('app').controller 'gitHubController', ['$log', 'gitHubService', Controller]
32,548
https://github.com/webcpp/hinginx/blob/master/module/lib/jsoncons/source_adaptor.hpp
Github Open Source
Open Source
BSD-2-Clause
2,022
hinginx
webcpp
C++
Code
306
1,101
// Copyright 2021 Daniel Parker // Distributed under the Boost license, Version 1.0. // (See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) // See https://github.com/danielaparker/jsoncons for latest version #ifndef JSONCONS_BUFFER_READER_HPP #define JSONCONS_BUFFER_READER_HPP #in...
8,399
https://github.com/zhuangbiaowei/OSS-bot/blob/master/src/ducks/wechaty/selectors.ts
Github Open Source
Open Source
Apache-2.0
2,020
OSS-bot
zhuangbiaowei
TypeScript
Code
50
127
import * as types from './types' export function status ( state: types.State, wechatyId: string, ) { if (wechatyId in state) { return state[wechatyId] } return {} } export function available ( state: types.State, wechatyId: string, ) { if (wechatyId in state) { return state[wechatyId].availabl...
15,484
https://github.com/mbra/b2-sdk-python/blob/master/b2sdk/api.py
Github Open Source
Open Source
MIT
null
b2-sdk-python
mbra
Python
Code
1,680
5,019
###################################################################### # # File: b2sdk/api.py # # Copyright 2019 Backblaze Inc. All Rights Reserved. # # License https://www.backblaze.com/using_b2_code.html # ###################################################################### import six from .account_info.sqlite_ac...
12,853
https://github.com/FeatureToggleStudy/olcs-backend/blob/master/module/Api/src/Domain/QueryHandler/DiscSequence/DiscPrefixes.php
Github Open Source
Open Source
MIT
2,018
olcs-backend
FeatureToggleStudy
PHP
Code
91
338
<?php /** * Disc Sequence - get discs prefixes */ namespace Dvsa\Olcs\Api\Domain\QueryHandler\DiscSequence; use Dvsa\Olcs\Api\Domain\QueryHandler\AbstractQueryHandler; use Dvsa\Olcs\Transfer\Query\QueryInterface; /** * Disc Prefix */ class DiscPrefixes extends AbstractQueryHandler { protected $repoServiceNam...
11,183
https://github.com/PacktPublishing/Java-9-Cookbook/blob/master/Chapter03/6_bottom_up_migration_after/src/calculator/com/packt/calculator/commands/Command.java
Github Open Source
Open Source
MIT
2,022
Java-9-Cookbook
PacktPublishing
Java
Code
29
110
package com.packt.calculator.commands; import com.fasterxml.jackson.databind.ObjectMapper; import java.util.Map; public interface Command{ ObjectMapper objectMapper = new ObjectMapper(); public void execute() throws Exception; default void printInJson(Map<String, Object> data) throws Exception{ System.out.print...
46,010
https://github.com/p1q/library-app/blob/master/src/main/java/library/spring/service/impl/RentServiceImpl.java
Github Open Source
Open Source
MIT
null
library-app
p1q
Java
Code
138
557
package library.spring.service.impl; import java.util.List; import java.util.Optional; import library.spring.dao.RentDao; import library.spring.entity.Book; import library.spring.entity.Rent; import library.spring.entity.User; import library.spring.exceptions.UserNotFoundException; import library.spring.service.RentSe...
35,262
https://github.com/HiikJava/University-Information-System/blob/master/cloudclient/man.model/src/main/java/org/sibsutis/is/database/all/Man.java
Github Open Source
Open Source
Apache-2.0
2,017
University-Information-System
HiikJava
Java
Code
214
675
package org.sibsutis.is.database.all; import java.io.Serializable; import java.time.LocalDateTime; import java.util.ArrayList; import java.util.List; import java.util.logging.Level; import java.util.logging.Logger; import org.sibsutis.is.location.AbstractLocation; import org.sibsutis.is.location.AbstractPoint; public...
37,682
https://github.com/webkom/lego/blob/master/lego/apps/surveys/views.py
Github Open Source
Open Source
MIT
2,023
lego
webkom
Python
Code
520
2,351
import csv from django.http import HttpResponse from django_filters.rest_framework import DjangoFilterBackend from rest_framework import exceptions, mixins, status, viewsets from rest_framework.decorators import action from rest_framework.response import Response from lego.apps.permissions.api.views import AllowedPer...
23,026
https://github.com/bdurand/sunspot_index_queue/blob/master/README.rdoc
Github Open Source
Open Source
MIT
2,012
sunspot_index_queue
bdurand
RDoc
Code
1,178
2,070
= Sunspot Index Queue This gem provides support for asynchronously updating a Solr index with the sunspot gem. == Why asynchronous === If Solr is down, your application won't (necessarily) be down Since Solr runs as a different part of your application infrastructure, there is always the chance that it isn't worki...
33,580
https://github.com/bavix/laravel-wallet/blob/master/src/Internal/Exceptions/ModelNotFoundException.php
Github Open Source
Open Source
MIT
2,023
laravel-wallet
bavix
PHP
Code
15
52
<?php declare(strict_types=1); namespace Bavix\Wallet\Internal\Exceptions; use RuntimeException; final class ModelNotFoundException extends RuntimeException implements RuntimeExceptionInterface { }
50,291
https://github.com/camillobruni/pygirl/blob/master/pypy/lang/smalltalk/objtable.py
Github Open Source
Open Source
MIT
2,021
pygirl
camillobruni
Python
Code
110
398
from pypy.lang.smalltalk import classtable from pypy.lang.smalltalk import constants from pypy.lang.smalltalk import model # ___________________________________________________________________________ # Global Data def wrap_char_table(): global CharacterTable def bld_char(i): w_cinst = classtable.w_Ch...
4,897
https://github.com/haorama/nestjs-storage/blob/master/lib/index.ts
Github Open Source
Open Source
MIT
2,021
nestjs-storage
haorama
TypeScript
Code
8
18
export * from './interfaces'; export * from './storage.module';
11,244
https://github.com/HUK-COBURG/hackbay_2017/blob/master/html/application/controllers/Alerts.php
Github Open Source
Open Source
MIT, LicenseRef-scancode-unknown-license-reference
2,021
hackbay_2017
HUK-COBURG
PHP
Code
153
571
<?php defined('BASEPATH') OR exit('No direct script access allowed'); /** * Description of Dashboard * * @author andre */ class Alerts extends CI_Controller { public function __construct() { parent::__construct(); $this->load->model('AlertDAO'); $this->load->model('SensorD...
52,854
https://github.com/Keesiu/meta-kaggle/blob/master/data/external/repositories/132416/caffe-windows-master/examples/kaggle-bowl/caffe_windows/utils/shuffle_lines.py
Github Open Source
Open Source
MIT
2,020
meta-kaggle
Keesiu
Python
Code
72
214
#!/usr/bin/env python """ @file shuffle_lines.py @brief shuffle lines in a file @author ChenglongChen """ import sys import csv import random import numpy as np from string import atoi def main(): # collect argvs seed = atoi(sys.argv[1]) file_in = sys.argv[2] file_out = sys.argv[3] # read w...
698
https://github.com/rendello/TTD2_Bot/blob/master/src/data.py
Github Open Source
Open Source
Unlicense
null
TTD2_Bot
rendello
Python
Code
761
2,804
import re import sqlite3 import random import common # 1: name, 2: file (if applicable), 3: line (if applicable), 4: type. SYMBOL_PATTERN = re.compile(r"^(?:\$LK,\")?([\w/:\/.]+)(?:\s*\",A=\"FL:[A-Z]:([/\w\.]+),(\d+)\S+)?.*? ((?:[A-Z][a-z].*|NULL)) $") # 1: full path. PATH_PATTERN = re.compile(r"^\$LK,\"[A-Z]:([\w/\...
14,167
https://github.com/sahaavi/HackerRank/blob/master/Algorithms/Implementation/Between Two Sets/Solution.cs
Github Open Source
Open Source
MIT
2,021
HackerRank
sahaavi
C#
Code
144
455
using System; using System.Linq; class Result { public static int getTotalX(int[] a, int[] b) { var totalXs = 0; var maximumA = a.Max(); var minimumB = b.Min(); var counter = 1; var multipleOfMaxA = maximumA; while (multipleOfMaxA <= minimumB) { ...
44,081
https://github.com/wench/Ao3-Tracker/blob/master/Ao3TrackReader/Ao3TrackReader/Text/HtmlConverter.cs
Github Open Source
Open Source
Apache-2.0
2,019
Ao3-Tracker
wench
C#
Code
729
1,879
/* Copyright 2017 Alexis Ryan 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 law or agreed to in writing, software di...
37,000
https://github.com/JY92/spider-flow/blob/master/spider-flow-api/src/main/java/org/spiderflow/context/CookieContext.java
Github Open Source
Open Source
MIT
2,020
spider-flow
JY92
Java
Code
16
48
package org.spiderflow.context; import java.util.HashMap; /** * Cookie上下文 */ public class CookieContext extends HashMap<String, String> { }
33,337
https://github.com/poissonconsulting/chk/blob/master/tests/testthat/test-chk-atomic.R
Github Open Source
Open Source
MIT
2,023
chk
poissonconsulting
R
Code
27
198
test_that("vld_atomic", { expect_true(vld_atomic(1)) expect_true(vld_atomic(matrix(1:3))) expect_true(vld_atomic(character(0))) expect_true(vld_atomic(NULL)) expect_false(vld_atomic(list(1))) }) test_that("chk_atomic", { expect_identical(chk_atomic(1), 1) expect_invisible(chk_atomic(1)) expect_chk_erro...
36,589
https://github.com/altdx/dotfiles/blob/master/Linux/.local/share/fish/generated_completions/docker-manifest.fish
Github Open Source
Open Source
MIT
null
dotfiles
altdx
Fish
Code
22
68
# docker-manifest # Autogenerated from man page /usr/lib/jvm/default/man/man1/docker-manifest.1.gz complete -c docker-manifest -s h -l help -d ' help for manifest SEE ALSO'
10,490
https://github.com/prehensilecode/tutorial-multi-gpu/blob/master/.etc/modules.sh
Github Open Source
Open Source
MIT
null
tutorial-multi-gpu
prehensilecode
Shell
Code
30
121
module use $OTHERSTAGES module purge module load Stages/2020 module load GCC/10.3.0 module load CUDA/11.3 module load ParaStationMPI/5.4.10-1 module load NVSHMEM/2.2.1 module load NCCL/2.10.3-1-CUDA-11.3 module load Nsight-Systems/2021.4.1 # module use $JSCCOURSE_DIR_GROUP/common/modulefiles
11,363
https://github.com/shivamsancc/citapp/blob/master/app/Models/gallery.php
Github Open Source
Open Source
MIT
null
citapp
shivamsancc
PHP
Code
123
543
<?php namespace App\Models; use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\Model; use Cviebrock\EloquentSluggable\Sluggable; class gallery extends Model { use Sluggable; use HasFactory; protected $table = 'galleries'; protected $fillable = ['gallery_name','slug','...
45,595
https://github.com/coolthor/hackfoldr-iOS/blob/master/hackfoldr-iOS/ListViewController.m
Github Open Source
Open Source
MIT
2,014
hackfoldr-iOS
coolthor
Objective-C
Code
102
421
// // ListViewController.m // hackfoldr-iOS // // Created by Superbil on 2014/8/31. // Copyright (c) 2014年 org.superbil. All rights reserved. // #import "ListViewController.h" #import "ViewController.h" #import "HackfoldrClient.h" #import "HackfoldrPage.h" @interface ListViewController () <UITabBarControllerDele...
49,896
https://github.com/theo-mesnil/WhatToWatch/blob/master/src/contexts/genres.js
Github Open Source
Open Source
MIT
2,022
WhatToWatch
theo-mesnil
JavaScript
Code
72
241
import React, { createContext, useContext, useEffect, useState } from 'react'; import { useGetGenres } from 'api/genres'; export const GenresContext = createContext(); export function GenresProvider({ children }) { const [genresTv, setGenresTv] = useState(); const [genresMovie, setGenresMovie] = useState(); co...
6,045
https://github.com/Tawsif-Kaisar/node-api-postgres/blob/master/queries.js
Github Open Source
Open Source
MIT
2,021
node-api-postgres
Tawsif-Kaisar
JavaScript
Code
210
593
const pool = require('./pool'); const loadScheema = require('./scheema'); loadScheema(pool); const getAllUsers = (request, response) => { pool.query('SELECT * FROM users ORDER BY id ASC', (error, result) => { if (error) { response.status(500); throw error; } response.status(200).json(result...
10,175
https://github.com/sudhakarVuppalapati/tracker/blob/master/tracker-ui/src/components/pages/device/Device.vue
Github Open Source
Open Source
MIT
2,017
tracker
sudhakarVuppalapati
Vue
Code
88
456
<template> <div class="device"> <b-row> <b-col md="4" lg="4" xl="2"> <device-list-group concise="true" class="d-none d-md-block d-lg-block d-xl-block"></device-list-group> </b-col> <b-col> <b-card no-body> <b-tabs ref="tabs" small lazy card> <b-tab title="М...
3,761
https://github.com/DanielChappuis/PEEL/blob/master/PEEL/Physics/PINT_Bounce/include/bounce/softbody/shapes/softbody_world_shape.h
Github Open Source
Open Source
Zlib
2,020
PEEL
DanielChappuis
C++
Code
649
1,910
/* * Copyright (c) 2016-2019 Irlan Robson https://irlanrobson.github.io * * This software is provided 'as-is', without any express or implied * warranty. In no event will the authors be held liable for any damages * arising from the use of this software. * Permission is granted to anyone to use this software for any p...
38,075
https://github.com/kkonishi2/atlas-checks/blob/master/src/main/java/org/openstreetmap/atlas/checks/validation/intersections/UnwalkableWaysCheck.java
Github Open Source
Open Source
BSD-3-Clause
null
atlas-checks
kkonishi2
Java
Code
894
2,767
package org.openstreetmap.atlas.checks.validation.intersections; import java.util.Arrays; import java.util.Collections; import java.util.HashSet; import java.util.List; import java.util.Optional; import java.util.Set; import java.util.stream.Collectors; import org.openstreetmap.atlas.checks.base.BaseCheck; import org...
50,455
https://github.com/ryankapur/sef-founderwall/blob/master/features/step_definitions/display_hospitals_steps.rb
Github Open Source
Open Source
MIT
2,016
sef-founderwall
ryankapur
Ruby
Code
62
185
Then(/^I should see "([^"]*)" before "([^"]*)"$/) do |hospital1, hospital2| regexp = /#{hospital1}.*#{hospital2}/m page.body.should =~ regexp end Then(/^I should not see "([^"]*)" before "([^"]*)"$/) do |hospital1, hospital2| regexp = /#{hospital1}.*#{hospital2}/m page.body.should_not =~ regexp end Then(/^I s...
16,233
https://github.com/BryanHaley/fteqw-applesilicon/blob/master/engine/client/m_mp3.c
Github Open Source
Open Source
Intel
2,022
fteqw-applesilicon
BryanHaley
C
Code
15,038
58,157
//mp3 menu and track selector. //was origonally an mp3 track selector, now handles lots of media specific stuff - like q3 films! //should rename to m_media.c #include "quakedef.h" #ifdef GLQUAKE #include "glquake.h" #endif #ifdef VKQUAKE #include "../vk/vkrenderer.h" #endif #include "shader.h" #include "gl_draw.h" #i...
42,901
https://github.com/h-ssiqueira/Academia_Cobra_Kai/blob/master/test/MysqlCon.java
Github Open Source
Open Source
MIT
2,021
Academia_Cobra_Kai
h-ssiqueira
Java
Code
87
365
import java.sql.*; class MysqlCon{ public static void main(String args[]){ float valores[] = new float[4]; try{ Class.forName("com.mysql.cj.jdbc.Driver"); Connection link = DriverManager.getConnection("jdbc:mysql://localhost:3306/academia","root",""); Statement stmt = link.createStatement(); ResultSet...
22,561
https://github.com/lwoggardner/awsdouble/blob/master/doubles/appsync/double.go
Github Open Source
Open Source
Apache-2.0
2,020
awsdouble
lwoggardner
Go
Code
4,812
21,192
// Code generated by go doublegen; DO NOT EDIT. // This file was generated at 2020-02-14T22:11:18+11:00 // Package appsyncdouble provides a TestDouble implementation of appsynciface.AppSyncAPI package appsyncdouble import ( "context" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/aws/request" ...
11,487
https://github.com/oscaroders/GameProgramming/blob/master/Disc/Assets/Imports/LowPoly_Floating_Islands/Prefabs_tex/Snow/Island13_tex.prefab.meta
Github Open Source
Open Source
MIT
2,019
GameProgramming
oscaroders
Unity3D Asset
Code
17
76
fileFormatVersion: 2 guid: 60263e776453dd54bb7cfa35a271e7c9 labels: - lowpoly - island timeCreated: 1479832455 licenseType: Store NativeFormatImporter: userData: assetBundleName: assetBundleVariant:
44,772
https://github.com/dvoegeli/adversary_emulation_library/blob/master/carbanak/Resources/utilities/RAMStressTest.ps1
Github Open Source
Open Source
Apache-2.0
2,022
adversary_emulation_library
dvoegeli
PowerShell
Code
325
751
<# .SYNOPSIS This script will generate RAM load to the specified memory. For best results run once in dedicated console per use. .DESCRIPTION This script will generate RAM load to the specified memory value. This will be the total RAM utilized by the system. If other progams are running they will ...
3,648
https://github.com/Crowd-Wire/CrowdWire/blob/master/api/app/api/api_v1/endpoints/statistics.py
Github Open Source
Open Source
MIT
2,022
CrowdWire
Crowd-Wire
Python
Code
244
1,088
from typing import Union from datetime import datetime from fastapi import APIRouter, Depends, HTTPException from sqlalchemy.orm import Session from app import models, schemas, crud from app.api import dependencies as deps from app.core import strings from app.utils import is_guest_user router = APIRouter() @router....
6,129
https://github.com/theletterf/signalfx-dotnet-tracing/blob/master/tracer/src/Datadog.Trace/Conventions/ITraceIdConvention.cs
Github Open Source
Open Source
Apache-2.0
null
signalfx-dotnet-tracing
theletterf
C#
Code
63
164
namespace Datadog.Trace.Conventions { /// <summary> /// Convention used when defining format of TraceId. /// </summary> public interface ITraceIdConvention { /// <summary> /// Generates new unique trace id based on convention. /// </summary> /// <returns>Trace id.</re...
15,345
https://github.com/jedimatt42/tipicmd/blob/master/b6_handleTipimap.c
Github Open Source
Open Source
MIT
2,021
tipicmd
jedimatt42
C
Code
792
2,997
#include "banks.h" #define MYBANK BANK(6) #include "commands.h" #include "b10_parsing.h" #include "b1_strutil.h" #include "b2_dsrutil.h" #include "b8_terminal.h" #include <string.h> #include <vdp.h> typedef void (*line_cb)(char*, char*); void handleTipimap(); static void listDrives(); static void visitLines(line_cb ...
51,616
https://github.com/asarmiento/brujulaelectoral/blob/master/app/candidatos.php
Github Open Source
Open Source
MIT
null
brujulaelectoral
asarmiento
PHP
Code
82
268
<?php namespace App; use Illuminate\Database\Eloquent\Model; class candidatos extends Model { /** * The database table used by the model. * * @var string */ protected $table = 'candidatos'; public function partidos() { return $this->hasOne('App\partido'); } public function preguntas(){ re...
45,003
https://github.com/anas-elghafari/WordCloudVisualiztion/blob/master/popularity_plot.js
Github Open Source
Open Source
MIT
2,019
WordCloudVisualiztion
anas-elghafari
JavaScript
Code
574
2,158
function getConfigPopularity() { // set the dimensions and margins of the graph let margin = { top: 20, right: 50, bottom: 50, left: 50 }; let height = 500 - margin.top - margin.bottom; let width = 850 - margin.left - margin.right; // set the ranges let x = d3.scaleTime().range([0, width]); let y = d3.sca...
37,091
https://github.com/MircoBabin/KeePassCommander/blob/master/src/KeePassCommanderPlugin/ViaFileSystemServer/DirectoryWatcher.cs
Github Open Source
Open Source
MIT
2,023
KeePassCommander
MircoBabin
C#
Code
179
637
using KeePassLib; using System.Collections.Generic; using System.IO; namespace KeePassCommander.ViaFileSystemServer { public class DirectoryWatcher { private FileSystemWatcher _watcher; private HandleFileCallback _handler; private Dictionary<string, bool> _allowedTitles = new Dictionar...
6,231
https://github.com/sitgdsc2022/roBOT/blob/master/command/game/playtogether.py
Github Open Source
Open Source
MIT
2,021
roBOT
sitgdsc2022
Python
Code
503
2,266
import datetime import discord from discord.ext import commands from typing import Optional class PlayFlags(commands.FlagConverter, delimiter=" ", prefix="-"): direct: Optional[str] = commands.flag(name="direct", aliases=["dir", "d"]) class Playdown(discord.ui.Select): def __init__(self, *options): ...
18,360
https://github.com/sumacero/bukikimenaika/blob/master/app/Http/Requests/UpdateInputDataRequest.php
Github Open Source
Open Source
MIT
null
bukikimenaika
sumacero
PHP
Code
82
268
<?php namespace App\Http\Requests; use Illuminate\Foundation\Http\FormRequest; class UpdateInputDataRequest extends FormRequest { /** * Determine if the user is authorized to make this request. * * @return bool */ public function authorize() { return true; } /** ...
42,452
https://github.com/john/drive.vote/blob/master/app/controllers/admin/ride_zones_controller.rb
Github Open Source
Open Source
MIT
2,018
drive.vote
john
Ruby
Code
317
1,205
class Admin::RideZonesController < Admin::AdminApplicationController include RideZoneParams include AccessMethods before_action :set_ride_zone, except: [:index, :new, :create] before_action :require_zone_admin, except: [:index] # handled at the method level before_action :require_admin_privileges, only: [:ne...
10,972
https://github.com/kthackse/website/blob/master/user/views.py
Github Open Source
Open Source
MIT
2,019
website
kthackse
Python
Code
1,006
4,847
import csv import zipfile from io import StringIO, BytesIO from django.contrib import auth, messages from django.contrib.auth.decorators import login_required from django.db import IntegrityError from django.http import ( HttpResponseRedirect, HttpResponseNotFound, StreamingHttpResponse, HttpResponse, ...
22,683
https://github.com/StevenCostiou/CVGenerator/blob/master/CVGenerator/CVGServiceType.class.st
Github Open Source
Open Source
MIT
null
CVGenerator
StevenCostiou
null
Spoken
154
347
Class { #name : #CVGServiceType, #superclass : #CVGElementType, #category : #'CVGenerator-elements - types' } { #category : #'as yet unclassified' } CVGServiceType class >> lc [ ^CVGLCType new ] { #category : #'as yet unclassified' } CVGServiceType class >> pc [ ^CVGPCType new ] { #category : #'as yet unclassifie...
49,282
https://github.com/frank-deng/experimental-works/blob/master/btree/btree.h
Github Open Source
Open Source
MIT
2,023
experimental-works
frank-deng
C
Code
108
440
#ifndef BTREE_H #define BTREE_H #include <stdbool.h> #include "queue.h" typedef enum { BTREE_LEFT = 0, BTREE_RIGHT = 1, } btree_pos_t; typedef struct btree_leaf_s { struct btree_leaf_s *left; struct btree_leaf_s *right; struct btree_leaf_s *parent; char data[0]; } btree_leaf_t; typedef struc...
35,013
https://github.com/fangdadashen/travel-5/blob/master/src/store/state.js
Github Open Source
Open Source
MIT
null
travel-5
fangdadashen
JavaScript
Code
4
19
export default{ city:localStorage.city||'北京' }
5,826
https://github.com/sitespeedio/compare/blob/master/gulp-tasks/usemin.js
Github Open Source
Open Source
MIT
2,022
compare
sitespeedio
JavaScript
Code
67
218
'use strict'; /** * Usemin task for replaces references to non-optimized scripts * or stylesheets into a set of HTML files */ const gulp = require('gulp'); const usemin = require('gulp-usemin'); const htmlmin = require('gulp-htmlmin'); const rev = require('gulp-rev'); const gulpPaths = require('../gulp-paths'); fun...
15,497
https://github.com/ZanderZhang/EasyDarkMode/blob/master/EasyDarkMode+Remote/UIImageView+DMRemote.m
Github Open Source
Open Source
MIT
2,020
EasyDarkMode
ZanderZhang
Objective-C
Code
85
294
// // UIImageVIew+DMRemote.m // EasyDarkMode // // Created by Elenion on 2019/8/21. // Copyright © 2019 Elenion. All rights reserved. // #import "UIImageView+DMRemote.h" #import "UIImage+DMRemote.h" @implementation UIImageView (DMRemote) - (void)dm_setImageUrlLight:(NSURL *)light dark:(NSURL *)dark { __weak _...
5,273
https://github.com/hampta/DSM/blob/master/commands/error_handler.py
Github Open Source
Open Source
MIT
null
DSM
hampta
Python
Code
158
522
import socket import sys import traceback import discord from aiohttp.client_exceptions import (ClientConnectorError, ClientOSError, ServerDisconnectedError) from discord.errors import DiscordServerError from discord.ext import commands from modules.logging import logger class ...
23,547
https://github.com/grzegorzt/junit-servers/blob/master/junit-servers-tomcat/src/test/java/com/github/mjeanroy/junit/servers/rules/TomcatServerRuleTest.java
Github Open Source
Open Source
MIT
2,017
junit-servers
grzegorzt
Java
Code
417
1,506
/** * The MIT License (MIT) * * Copyright (c) 2014-2017 <mickael.jeanroy@gmail.com> * * 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 ...
6,694
https://github.com/randysecrist/riak-java-httpclient/blob/master/src/test/java/com/sfn/riak/client/ClientOpsTest.java
Github Open Source
Open Source
Apache-2.0
null
riak-java-httpclient
randysecrist
Java
Code
99
375
package com.sfn.riak.client; import org.junit.jupiter.api.AfterAll; import org.junit.jupiter.api.BeforeAll; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.function.ThrowingSupplier; import static java.time.Duration.ofSeconds; import static org.junit.jupiter.a...
6,557
https://github.com/himichael/LeetCode/blob/master/src/201_300/0207_course-schedule/course-schedule.py
Github Open Source
Open Source
Apache-2.0
2,019
LeetCode
himichael
Python
Code
286
1,162
class Graph(object): def __init__(self,vertexNum): self.__adjacencyTable = [[] for _ in xrange(vertexNum)] def addRelationOfVertices(self,src,dest): self.__adjacencyTable[src].append(dest) def vertexReference(self,i): return self.__adjacencyTable[i] # BFS,Kahn算法 class Solution(object): def canFinish(s...
9,695
https://github.com/hgnc-fe/ife-spring/blob/master/.gitignore
Github Open Source
Open Source
MIT
2,016
ife-spring
hgnc-fe
Ignore List
Code
5
53
goal/task_1_7_1.psd goal/task_1_9_1.psd goal/task_1_9_1.psd test/node_modules node_modules
13,415
https://github.com/activej/activej/blob/master/cloud-fs/src/main/java/io/activej/fs/IBlockingFileSystem.java
Github Open Source
Open Source
Apache-2.0
2,023
activej
activej
Java
Code
286
931
package io.activej.fs; import io.activej.common.annotation.ComponentInterface; import org.jetbrains.annotations.Nullable; import java.io.IOException; import java.io.InputStream; import java.io.OutputStream; import java.util.LinkedHashMap; import java.util.Map; import java.util.Set; import static io.activej.common.Ch...
20,497
https://github.com/dwebplatform/web-room-cqrs-app/blob/master/backend/src/chars/chars.module.ts
Github Open Source
Open Source
MIT
2,021
web-room-cqrs-app
dwebplatform
TypeScript
Code
67
198
import { Module } from '@nestjs/common'; import { TypeOrmModule } from '@nestjs/typeorm'; import { CharsController } from './chars.controller'; import { CommandHandlers } from './commands'; import { Characteristic } from 'src/entities/char.entity'; import { CqrsModule } from '@nestjs/cqrs'; import { QueriesHandlers } f...
10,603
https://github.com/emosowski/phase-0/blob/master/week-7/nums_commas.js
Github Open Source
Open Source
MIT
2,016
phase-0
emosowski
JavaScript
Code
345
584
// Separate Numbers with Commas in JavaScript **Pairing Challenge** // I worked on this challenge with: Jackie Feminella. // Pseudocode //Input: Integer //Output: Return a comma-separated integer as a string //Create a function //Convert integer to string //Create an array out of it - Reverse the string //Using indi...
23,680
https://github.com/n-hutton/tendermint/blob/master/rpc/client/http/http.go
Github Open Source
Open Source
Apache-2.0
2,021
tendermint
n-hutton
Go
Code
2,293
6,319
package http import ( "context" "errors" "net/http" "strings" "time" "github.com/tendermint/tendermint/libs/bytes" tmjson "github.com/tendermint/tendermint/libs/json" "github.com/tendermint/tendermint/libs/log" tmpubsub "github.com/tendermint/tendermint/libs/pubsub" "github.com/tendermint/tendermint/libs/se...
13,728
https://github.com/S-Asghari/Complex-Network-Analysis-of-Twitter-Accounts/blob/master/classifiers.py
Github Open Source
Open Source
MIT
2,022
Complex-Network-Analysis-of-Twitter-Accounts
S-Asghari
Python
Code
621
2,683
import pandas as pd import numpy as np import networkx as nx from statistics import mean from datetime import datetime from sklearn.linear_model import LogisticRegression from sklearn.svm import SVC from sklearn.neighbors import KNeighborsClassifier from sklearn.ensemble import RandomForestClassifier from sklearn.neura...
19,706
https://github.com/lazyMods/BlockActions/blob/master/src/main/java/com/lazynessmind/blockactions/base/BlockActionTileEntity.java
Github Open Source
Open Source
MIT
null
BlockActions
lazyMods
Java
Code
401
1,741
package com.lazynessmind.blockactions.base; import com.lazynessmind.blockactions.Configs; import com.lazynessmind.blockactions.api.IInfo; import com.lazynessmind.blockactions.utils.BlockActionEnergyStorage; import com.lazynessmind.blockactions.utils.EnergyManager; import com.lazynessmind.blockactions.utils.Utils; impo...
36,707
https://github.com/yurydelendik/cloudlibc/blob/master/src/libc/libintl/dgettext.c
Github Open Source
Open Source
LicenseRef-scancode-unknown-license-reference, BSD-2-Clause
2,018
cloudlibc
yurydelendik
C
Code
37
109
// Copyright (c) 2015 Nuxi, https://nuxi.nl/ // // SPDX-License-Identifier: BSD-2-Clause #include <libintl.h> #ifndef dgettext #error "dgettext is supposed to be a macro as well" #endif char *(dgettext)(const char *domain, const char *msgid) { return dgettext(domain, msgid); }
50,396
https://github.com/Pyro-tech/pyro/blob/master/lib/assets/Ruby復習問題_入門_中級/復習問題_入門編_回答/b3.rb
Github Open Source
Open Source
MIT
2,016
pyro
Pyro-tech
Ruby
Code
47
169
puts <<EOS 以下の空欄(a)~(c)を書き換えて、プログラムを完成させましょう。 ---正解となる実行結果--- [100, 200, 30, 4, 500] [500, 4, 30, 200, 100] [4, 30, 100, 200, 500] [500, 200, 100, 30, 4] ---ここまで--- EOS ary = [100, 200, 30, 4, 500] p ary p ary.reverse p ary.sort p ary.sort.reverse # sort {|a,b| b <=> a}
43,545
https://github.com/Wh1t3Fox/twistedbot/blob/master/plugins/webpage.py
Github Open Source
Open Source
MIT
2,014
twistedbot
Wh1t3Fox
Python
Code
43
213
#!/usr/bin/env python import re import requests import HTMLParser from bs4 import BeautifulSoup class Webpage(object): def __init__(self, url): self.h = HTMLParser.HTMLParser() self.get_info(url) def sanitize_url(self, text): return re.sub(r'[\r\n\s]*','',text) def sanitize_text...
51,798
https://github.com/codehaus/xjb/blob/master/xjb/src/com/thoughtworks/xjb/jdbc/NonClosingConnectionInvocationHandler.java
Github Open Source
Open Source
BSD-3-Clause
2,008
xjb
codehaus
Java
Code
64
202
/* * Created on 11-Apr-2004 * * (c) 2003-2004 ThoughtWorks Ltd * * See license.txt for license details */ package com.thoughtworks.xjb.jdbc; import java.lang.reflect.Method; import java.sql.Connection; import com.thoughtworks.proxy.toys.delegate.DelegatingInvoker; class NonClosingConnectionInvocationHandler ...
47,347
https://github.com/dda119141/mp3tags/blob/master/include/3rd-party/ericniebler/range-v3/cmake/thread_test_code.cpp
Github Open Source
Open Source
MIT, NCSA, LicenseRef-scancode-mit-old-style, LicenseRef-scancode-other-permissive, BSL-1.0
2,022
mp3tags
dda119141
C++
Code
9
33
#include <thread> int main() { return (void)std::this_thread::get_id(), 0; }
13,567
https://github.com/rosenbergdm/ro-tools/blob/master/scripts/functions_REMOTE_1130.sh
Github Open Source
Open Source
MIT
null
ro-tools
rosenbergdm
Shell
Code
820
3,083
#!/usr/local/bin/bash pbpaste=$(pbpaste && echo) _systype=$(uname) case "$_systype" in Darwin* | darwin*) export AWK=/usr/local/bin/gawk export BASENAME=/usr/local/bin/gbasename export DATE=/usr/local/bin/gdate export DIRNAME=/usr/local/bin/gdirname export FIND=/usr/local/bin/gfind export GIT=/usr/local/bin/git...
39,550
https://github.com/JevinAnderson/DM-Memorial/blob/master/src/pages/valhalla/keep/hall-of-memory-2.js
Github Open Source
Open Source
Apache-2.0
null
DM-Memorial
JevinAnderson
JavaScript
Code
219
464
import React from "react"; import Layout from "../../../components/layout"; import SEO from "../../../components/seo"; import Room from "../../../components/room"; import Exits from "../../../components/exits"; import Characters from "../../../components/characters"; import { Link } from "gatsby"; const HallOfMemory ...
3,069
https://github.com/laura-nieto/empatia/blob/master/resources/views/usuarios/listar.blade.php
Github Open Source
Open Source
MIT
null
empatia
laura-nieto
PHP
Code
176
909
@extends('layouts.app') @section('title','Usuario - Psicologia y Emprendimiento') @section('main') <h2 class="h2__title">Usuarios</h2> <div class="mb-3 desempenio-modify"> <a href="{{route('usuarios.create')}}" class="btn link-color color-white">Nuevo</a> </div> <article class="article-users-ind...
7,571
https://github.com/bsides44/MARSGeofencing/blob/master/MARS geofencing/Library/PackageCache/com.unity.mars@1.3.1/Runtime/Scripts/Handles/ScaleWorldCanvasWithCameraDistance.cs
Github Open Source
Open Source
Apache-2.0
null
MARSGeofencing
bsides44
C#
Code
49
211
using UnityEngine; using Unity.MARS.MARSHandles; namespace Unity.MARS { [ExecuteInEditMode] [AddComponentMenu("")] [RequireComponent(typeof(RectTransform))] sealed class ScaleWorldCanvasWithCameraDistance : HandleBehaviour { Vector3? m_InitialScale; RectTransform m_RectTransform; ...
988
https://github.com/03330130/WeatherDemo/blob/master/app/src/main/java/bourne/com/weatherdemo/util/Utility.java
Github Open Source
Open Source
Apache-2.0
null
WeatherDemo
03330130
Java
Code
179
833
package bourne.com.weatherdemo.util; import android.text.TextUtils; import android.util.Log; import com.google.gson.Gson; import org.json.JSONArray; import org.json.JSONException; import org.json.JSONObject; import bourne.com.weatherdemo.db.City; import bourne.com.weatherdemo.db.Country; import bourne.com.weatherde...
38,874
https://github.com/dhis2/dhis2-core/blob/master/dhis-2/dhis-api/src/test/java/org/hisp/dhis/dataelement/OperandTest.java
Github Open Source
Open Source
BSD-3-Clause, BSD-2-Clause
2,023
dhis2-core
dhis2
Java
Code
559
2,033
/* * Copyright (c) 2004-2022, University of Oslo * All rights reserved. * * Redistribution and use 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 cond...
27,509
https://github.com/hautezwei/zephyr/blob/master/tests/crypto/ecc_dh/src/main.c
Github Open Source
Open Source
Apache-2.0
2,018
zephyr
hautezwei
C
Code
28
127
/* * Copyright (c) 2017 Intel Corporation * * SPDX-License-Identifier: Apache-2.0 */ #include <ztest.h> extern void test_ecc_dh(void); /**test case main entry*/ void test_main(void) { ztest_test_suite(test_ecc_dh_fn, ztest_unit_test(test_ecc_dh)); ztest_run_test_suite(test_ecc_dh_fn); }
21,493
https://github.com/kellyselden/ember-cli-dependency-graph/blob/master/test/fixtures/code-corps-ember/addon-tree-output/ember-keyboard/utils/get-cmd-key.js
Github Open Source
Open Source
MIT
2,019
ember-cli-dependency-graph
kellyselden
JavaScript
Code
49
142
define('ember-keyboard/utils/get-cmd-key', ['exports'], function (exports) { 'use strict'; Object.defineProperty(exports, "__esModule", { value: true }); exports.default = function (platform) { if (typeof FastBoot === 'undefined') { if (platform === undefined) { platform = navigator.plat...
39,645
https://github.com/jazad136/EventFlowSlicerJava-releases/blob/master/JavaEFS/src/edu/unl/cse/efs/view/FindFile.java
Github Open Source
Open Source
Apache-2.0
2,021
EventFlowSlicerJava-releases
jazad136
Java
Code
413
1,170
/******************************************************************************* * Copyright (c) 2018 Jonathan A. Saddler * * 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 * ...
680
https://github.com/ZioYuri78/AttackOfThePrisms/blob/master/Plugins/LoadingScreen/Source/LoadingScreen/Private/SSimpleLoadingScreen.h
Github Open Source
Open Source
MIT
2,017
AttackOfThePrisms
ZioYuri78
C++
Code
101
346
// Copyright 1998-2015 Epic Games, Inc. All Rights Reserved. #pragma once #include "SCompoundWidget.h" #include "LoadingScreenSettings.h" /** * Special brush to prevent garbage collection */ struct FLoadingScreenBrush : public FSlateDynamicImageBrush, public FGCObject { FLoadingScreenBrush(class UTexture2D* InTextu...
144
https://github.com/ToCheckOn/Bannerlord.Diplomacy/blob/master/src/DiplomaticAction/Alliance/BreakAllianceConditions.cs
Github Open Source
Open Source
MIT
null
Bannerlord.Diplomacy
ToCheckOn
C#
Code
31
132
using Diplomacy.DiplomaticAction.Alliance.Conditions; using System.Collections.Generic; namespace Diplomacy.DiplomaticAction.Alliance { class BreakAllianceConditions : AbstractConditionEvaluator<BreakAllianceConditions> { private static List<IDiplomacyCondition> _breakAllianceConditions = new List<IDi...
40,493
https://github.com/mwitiderrick/crypto-market-watcher/blob/master/views/index.ejs
Github Open Source
Open Source
MIT
2,018
crypto-market-watcher
mwitiderrick
EJS
Code
161
722
<!DOCTYPE html> <html> <head> <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"> <link rel='stylesheet' href='/stylesheets/style.css' /> </head> <body> <nav class="navbar navbar-default"> <div class="container-fluid"> <!-...
26,317
https://github.com/ropensci/gistr/blob/master/tests/testthat/test-gist_create_obj.R
Github Open Source
Open Source
MIT
2,022
gistr
ropensci
R
Code
113
544
context("gist_create_obj") test_that("gist_create_obj works from a data.frame", { skip_on_cran() ## data.frame ### by default makes pretty table in markdown format row.names(mtcars) <- NULL df_1 <- gist_create_obj(mtcars, browse = FALSE) ### or just push up json df_3 <- gist_create_obj(mtcars, browse ...
10,245
https://github.com/mwotton/robots/blob/master/test/examples/blogfa.com
Github Open Source
Open Source
2,022
robots
mwotton
DIGITAL Command Language
Code
12
53
User-agent: * Disallow: /Desktop/ Disallow: /images/ Disallow: /Comments.aspx User-agent: googlebot Crawl-delay: 30
13,825
https://github.com/blerer/horizondb-io/blob/master/src/test/java/io/horizondb/io/files/CompositeSeekableFileDataInputTest.java
Github Open Source
Open Source
Apache-2.0
2,016
horizondb-io
blerer
Java
Code
749
2,858
/** * Copyright 2013 Benjamin Lerer * * 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 law or agreed to...
26,336
https://github.com/4nnina/IS_CovidMarket/blob/master/src/main/model/FasciaOraria.java
Github Open Source
Open Source
MIT
null
IS_CovidMarket
4nnina
Java
Code
10
31
package main.model; public enum FasciaOraria { Mattina, Pomeriggio, Sera }
24,268
https://github.com/DrewLab/Winder_Echagarruga_Zhang_Drew_2017_Code/blob/master/Subscripts/Data Processing/Categorize Data By Behavior/SelectStruggleEvents.m
Github Open Source
Open Source
MIT
2,017
Winder_Echagarruga_Zhang_Drew_2017_Code
DrewLab
MATLAB
Code
129
485
function [StrugStruct] = SelectStruggleEvents(EventData,dataType,Criteria) % function [] = () % % Author: Aaron Winder % Affiliation: Engineering Science and Mechanics, Penn State University % https://github.com/awinde % % DESCRIPTION: % %_______________________________________________________________ % ...
36,750
https://github.com/lukebp/politeiagui/blob/master/src/components/Logo/Logo.jsx
Github Open Source
Open Source
0BSD
2,022
politeiagui
lukebp
null
Spoken
71
196
import React from "react"; import { useTheme, DEFAULT_DARK_THEME_NAME } from "pi-ui"; import PropTypes from "prop-types"; import { useConfig } from "src/containers/Config"; const Logo = ({ style }) => { const { themeName } = useTheme(); const { logoLight, logoDark } = useConfig(); const logoSrc = themeName === D...
23,140
https://github.com/RyuaNerin/uotp-go/blob/master/example/main.go
Github Open Source
Open Source
Unlicense
null
uotp-go
RyuaNerin
Go
Code
136
454
package main import ( "context" "encoding/json" "fmt" "os" "github.com/RyuaNerin/uotp" ) func main() { var otp uotp.UOTP if fs, err := os.Open("uotp.json"); !os.IsNotExist(err) { defer fs.Close() // Read var otpAccount uotp.Account err = json.NewDecoder(fs).Decode(&otpAccount) if err != nil { p...
6,133
https://github.com/Msajt/NodeJS/blob/master/facerecognition-fullstack/facerecognition-react/src/components/ImageLinkForm/ImageLinkForm.js
Github Open Source
Open Source
MIT
null
NodeJS
Msajt
JavaScript
Code
89
250
import React from 'react'; import './ImageLinkForm.css'; const ImageLinkForm = ({ onInputChange, onButtonSubmit }) => { return( <div> {/* Título */} <p className='f3'> {'O cérebro irá detectar as faces na figura, faça uma tentativa.'} </p> ...
31,128
https://github.com/z00m128/sjasmplus/blob/master/sjasm/relocate.h
Github Open Source
Open Source
BSD-3-Clause
2,023
sjasmplus
z00m128
C++
Code
323
595
/* SjASMPlus Z80 Cross Compiler - modified - RELOCATE extension Copyright (c) 2006 Sjoerd Mastijn (original SW) Copyright (c) 2020 Peter Ped Helcmanovsky (RELOCATE extension) This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any dama...
24,302
https://github.com/bubblecode/bubblBI/blob/master/src/models/setting.js
Github Open Source
Open Source
MIT
null
bubblBI
bubblecode
JavaScript
Code
109
325
import { getConfig, updateConfig } from "../services/setting"; export default { namespace: "setting", state: { ToolbarAutoHideDelay: 2000, }, reducers: { updateState(state, { payload }) { return { ...state, ...payload, }; }, }, subscriptions: { setup({ dispatc...
31,225
https://github.com/Sonyq/pharo/blob/master/src/UndefinedClasses/ShiftClassBuilder.extension.st
Github Open Source
Open Source
MIT
null
pharo
Sonyq
null
Spoken
38
79
Extension { #name : #ShiftClassBuilder } { #category : #'*UndefinedClasses' } ShiftClassBuilder >> useUndefinedClass [ "If i am use, the superResolver will resolve unknown superclass by creating an UndefinedClass with the expected superclassName" self superclassResolver: ClassResolverUndefinedClass new. ]
34,343
https://github.com/matthope/area53/blob/master/kube_client.rb
Github Open Source
Open Source
MIT
null
area53
matthope
Ruby
Code
72
334
require 'kubeclient' TOKEN_PATH = ENV['TOKEN_PATH'] || '/var/run/secrets/kubernetes.io/serviceaccount/token' class KubeClient def initialize(logger, version, server_suffix) @logger = logger @version = version @server_suffix = server_suffix end def watch_services client.watch_services(label_selec...
17,729
https://github.com/d0sadata/studio/blob/master/contentcuration/contentcuration/frontend/shared/views/MarkdownEditor/plugins/minimize/minimize.js
Github Open Source
Open Source
MIT
2,022
studio
d0sadata
JavaScript
Code
44
232
const EVENT_MINIMIZE_TOOLBAR_BTN_CLICK = 'MinimizeToolbarBtnClick'; const minimizeExtension = (editor, options) => { editor.eventManager.addEventType(EVENT_MINIMIZE_TOOLBAR_BTN_CLICK); editor.eventManager.listen(EVENT_MINIMIZE_TOOLBAR_BTN_CLICK, () => { options.onMinimizeToolbarBtnClick(); }); editor ...
19,141
https://github.com/lunks/telegram-youtube-notifier/blob/master/.eslintrc.js
Github Open Source
Open Source
MIT
null
telegram-youtube-notifier
lunks
JavaScript
Code
48
193
module.exports = { env: { browser: true, es2020: true, 'jest/globals': true, }, extends: ['standard', 'prettier/@typescript-eslint', 'plugin:prettier/recommended'], parser: '@typescript-eslint/parser', parserOptions: { ecmaVersion: 11, sourceType: 'module', }, plugins: ['@typescript-es...
26,556
https://github.com/abacusai/intraprocessing_debiasing/blob/master/utils.py
Github Open Source
Open Source
Apache-2.0
2,021
intraprocessing_debiasing
abacusai
Python
Code
549
2,198
import numpy as np from sklearn.metrics import balanced_accuracy_score def get_data(dataset, protected_attribute, seed=101): def protected_attribute_error(): raise ValueError(f'protected attribute {protected_attribute} is not available for dataset {dataset}') if dataset == 'adult': from aif36...
52,151
https://github.com/code-dot-org/code-dot-org/blob/master/apps/src/javalab/JavalabConsole.jsx
Github Open Source
Open Source
Apache-2.0
2,022
code-dot-org
code-dot-org
null
Spoken
720
2,529
import React from 'react'; import {connect} from 'react-redux'; import PropTypes from 'prop-types'; import javalabMsg from '@cdo/javalab/locale'; import color from '@cdo/apps/util/color'; import {KeyCodes} from '@cdo/apps/constants'; import { appendInputLog, clearConsoleLogs, closePhotoPrompter } from './javalabR...
22,196
https://github.com/Handsome-Geniuses/cobot/blob/master/cobotduino/include/LockZoneControl.h
Github Open Source
Open Source
MIT
null
cobot
Handsome-Geniuses
C
Code
196
616
#pragma once #include <Arduino.h> #include "timer.h" #define ACTIVE_HIGH //comment out if active low #define USING_PWM //comment out if using digital signals #ifdef USING_PWM #undef USING_PWM #define MAX_BRIGHTNESS 255 #define MIN_BRIGHTNESS 0 #define pinWrite(pin, state) analogWrite(pin, st...
39,447
https://github.com/GJRinfinity/kizuna/blob/master/src/db/mongoose.js
Github Open Source
Open Source
MIT
null
kizuna
GJRinfinity
JavaScript
Code
21
86
require('dotenv').config() const mongoose = require('mongoose') mongoose.connect(process.env.MONGODB_URI, { useNewUrlParser: true, useCreateIndex: true, useFindAndModify: false }, () => { console.log('connected to mongodb') })
42,865
https://github.com/saandre15/advance-cs-labs/blob/master/Lab99-BonusLabs/Lab___-MazeSolver (alternate version)/MazeSolver (alt) starter code/MazeCell.java
Github Open Source
Open Source
MIT
null
advance-cs-labs
saandre15
Java
Code
179
444
import java.util.*; import java.awt.*; import java.awt.event.*; import javax.swing.*; public class MazeCell { int status; // 0 = never visited // 1 = on current path // 2 = on dead-end path int setNumber; // used when constructing maze boolean leftHedge; boolean rightHedge; boolean to...
18,884
https://github.com/sweetgiorni/DXDecompiler/blob/master/src/DXDecompiler/DX9Shader/Decompiler/Compiler/MatrixMultiplicationCompiler.cs
Github Open Source
Open Source
MIT
2,022
DXDecompiler
sweetgiorni
C#
Code
43
168
namespace DXDecompiler.DX9Shader { public sealed class MatrixMultiplicationCompiler { private NodeCompiler nodeCompiler; public MatrixMultiplicationCompiler(NodeCompiler nodeCompiler) { this.nodeCompiler = nodeCompiler; } public string Compile(MatrixMultiplicationContext context) { string matrixN...
27,659
https://github.com/thibault-martinez/bee/blob/master/bee-protocol/src/workers/index_updater.rs
Github Open Source
Open Source
Apache-2.0
2,022
bee
thibault-martinez
Rust
Code
799
2,317
// Copyright 2020-2022 IOTA Stiftung // SPDX-License-Identifier: Apache-2.0 use crate::workers::storage::StorageBackend; use bee_message::{ milestone::{Milestone, MilestoneIndex}, MessageId, }; use bee_runtime::{node::Node, shutdown_stream::ShutdownStream, worker::Worker}; use bee_tangle::{metadata::IndexId, ...
489
https://github.com/kamil-nawrot/kamil-nawrot.github.io/blob/master/src/utils/typography.js
Github Open Source
Open Source
MIT
null
kamil-nawrot.github.io
kamil-nawrot
JavaScript
Code
48
165
import Typography from "typography" const typography = new Typography({ baseFontSize: "18px", baseLineHeight: 1.666, headerFontFamily: [ "Josefin Sans", "sans-serif" ], headerWeight: "200", bodyFontFamily: [ "Josefin Sans", "sans-serif" ], bodyWeight: "300", googleFonts: [ { ...
28,523