text stringlengths 27 775k |
|---|
import 'package:functional_error_handling_dart/functional_error_handling_dart.dart';
Future<void> main() async {
const itemIds = [1, 2, 3, 4, 5];
// Bad Code
var badItemList = <Item>[]; // mutable list
for (var itemId in itemIds) {
var targetItem = ItemService.find(itemId);
if (targetItem.isEmpty) {
... |
require 'spec_helper'
require 'etl/audit_loader'
RSpec.describe ETL::AuditLoader do
let(:audit_dimension) { instance_double(Dimensions::Audit) }
subject { described_class.new(audit_dimension: audit_dimension) }
it 'creates an Import reocrd' do
expect(audit_dimension).to receive(:update_attributes!).with(
... |
require 'puppet/util/errors'
require 'puppet/util/execution'
require 'octokit'
Puppet::Type.type(:github_ssh_key).provide :github do
include Puppet::Util::Execution
include Puppet::Util::Errors
def exists?
existing_id
end
def destroy
api.remove_key(existing_id)
end
def create
api.add_key(t... |
#!/bin/bash
cd ggc-core && make $1 && cd ..
cd ggc-app && make $1 && cd ..
|
// Copyright (c) 2019 The DAML Authors. All rights reserved.
// SPDX-License-Identifier: Apache-2.0
package com.digitalasset.ledger.client.binding.offset
import com.digitalasset.ledger.api.v1.ledger_offset.LedgerOffset
import com.digitalasset.ledger.api.v1.ledger_offset.LedgerOffset.LedgerBoundary.{
LEDGER_BEGIN,
... |
#-------------------------------------------------------------------------------
#
# Thomas Thomassen
# thomas[at]thomthom[dot]net
#
#-------------------------------------------------------------------------------
module TT::Plugins::QuadFaceTools
module Settings
@cache = {}
def self.read(key, defa... |
# how to generate html API documentation using pdoc3
1. Using anaconda prompt, activate dryft environment per repository README.
2. Check that pdoc3 is installed: `pip install pdoc3`
3. Navigate to repository locally: `cd path/to/dryft`
4. Use pdoc3: `python -m pdoc --html dryft`
Html files should be located in a new... |
import Log from "../core/log";
import {default as parseArgs} from "minimist";
export default class ConsoleCommand {
public readonly base: string;
public readonly args: any;
/**
* @param {string} base
* @param {*} args
*/
constructor(base: string, args: any) {
/**
... |
#include "LevelLoader.h"
//#include <iostream>
#include <fstream>
//#include <iomanip>
#include "../Modules/ActorFactory.h"
LevelLoader::LevelLoader(void)
{
}
LevelLoader::~LevelLoader(void)
{
}
void LevelLoader::save(World* world, const std::string levelName)
{
// saving all actors in this world
std::ofstream ... |
<?php
declare(strict_types = 1);
require __DIR__.'/../vendor/autoload.php';
use Innmind\HttpServer\Main;
use Innmind\Http\Message\{
ServerRequest,
Response,
};
use Innmind\Compose\ContainerBuilder\ContainerBuilder;
use Innmind\Url\{
PathInterface,
Path,
};
use Innmind\HttpFramework\Environment;
use In... |
module SyntheticWeb.Counter.ByteCounter
( ByteCounter (..)
, empty
, addByteCount
) where
import GHC.Int (Int64)
data ByteCounter =
ByteCounter { download :: {-# UNPACK #-} !Int64
, upload :: {-# UNPACK #-} !Int64 }
deriving (Show)
empty :: ByteCounter
empty = ByteCoun... |
sudo apt-get update
sudo sh -c "echo "US/Eastern" > /etc/timezone"
sudo dpkg-reconfigure -f noninteractive tzdata
sudo debconf-set-selections <<< "postfix postfix/mailname string $HOSTNAME"
sudo debconf-set-selections <<< "postfix postfix/main_mailer_type string 'Internet Site'"
sudo apt-get install -y make build-ess... |
a = gets.split.map(&:to_i)
nums = a.uniq.map { |n| a.count(n) }
if nums.include?(3)
if nums.include?(2)
puts 'FULL HOUSE'
else
puts 'THREE CARD'
end
elsif nums.include?(2)
if nums.count(2) == 2
puts 'TWO PAIR'
else
puts 'ONE PAIR'
end
else
puts 'NO HAND'
end
|
var PATH = require("path");
var stackTrace = require("stack-trace");
var _ = require("lodash");
module.exports = {
getParentModule: function (depth) {
// get unique filename call stack
var paths = module.exports.getUniqueFilenameStackTrace();
// we work relative to parent path,
// so we remove Modul... |
# === COPYRIGHT:
# Copyright (c) North Carolina State University
# Developed with funding for the National eXtension Initiative.
# === LICENSE:
#
# see LICENSE file
class EpochDate
extend YearWeek
attr_accessor :date
# earliest google analytics data
GA_START = Date.parse('2007-02-23')... |
/**
* Example: https://github.com/jasonsoft-net/jasonsoft-express-server
* FilePath: /jasonsoft-express-server/app.js
* Added by Jason.Song (成长的小猪) on 2021/09/28
* CSDN: https://blog.csdn.net/jasonsong2008
* GitHub: https://github.com/jasonsoft-net
* Organizations: https://github.com/jasonsoft
*/
import Express ... |
package nguyengiap.vietitpro.tudienanhviet.com.adapter;
import android.content.Context;
import android.support.v7.widget.RecyclerView;
import android.text.Html;
import android.text.TextUtils;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.TextView;
im... |
desc "This task is called by the Heroku scheduler add-on"
task :clean_articles => :environment do
puts "Cleaning articles..."
Article.where("created_at > ?", 1.day.ago).destroy_all
puts "done."
end
|
"""
@title
@description
"""
import argparse
import CoDrone
def get_sensor_state(drone):
sensor_vals = {
'accel': drone.get_accelerometer(),
'ang_speed': drone.get_angular_speed(),
'battery': drone.get_battery_percentage(),
'battery_voltage': drone.get_battery_voltage(),
't... |
# Changelog
## 2.1.3
- Fix for object properties
## 2.1.2
- Version bump to trigger a green build
## 2.1.1
- Fixed a bug where component file names were wrong on Windows builds
## 2.1.0
- Annotating React.Fragments as a configurable option
## 2.0.1
- Readme update
## 2.0.0
- React.Fragments are no longer an... |
/**
* Copyright 2020 Shimizu Yasuhiro (yshrsmz)
*
* 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 o... |
import { ThemeTypes } from '@getstation/theme';
import * as classNames from 'classnames';
import * as React from 'react';
// @ts-ignore: no declaration file
import injectSheet from 'react-jss';
interface Classes {
container: string,
dot: string,
close: string,
minimize: string,
expand: string,
}
interface P... |
package com.example.kru13.fractal;
import android.graphics.Bitmap;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.util.Log;
import android.view.MotionEvent;
import android.view.View;
import android.widget.ImageView;
import android.widget.TextView;
public class MainActivity e... |
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Samples
{
public static class Constants
{
public const string BaseAddress = "https://developers.es.gov.br/acessocidadao/is";
public const string RedirectUriCorporativo ... |
<?php
namespace App\Helpers;
use App\Pattern;
class BibliobigrafiRelationship
{
private $pattern;
private $str;
private $newPattern;
private $patternId;
public function modifyPattern($str)
{
$this->str = $str;
$this->findPattern();
}
public function getPattern()
{
$this->updatePattern(... |
package com.github.lemfi.kest.cadence.executor
import com.fasterxml.jackson.module.kotlin.jacksonObjectMapper
import com.github.lemfi.kest.core.model.Execution
import com.google.gson.Gson
import com.uber.cadence.activity.ActivityOptions
import com.uber.cadence.client.WorkflowClient
import com.uber.cadence.client.Workf... |
helm del --purge helm
kubectl delete -f /home/hingnekar_mayur/k8s-practice/prometheus-alerting-0.20.0-helm/prometheus-instance-rbac.yaml
kubectl delete secret alertmanager-alertmanager -n monitoring
kubectl delete -f /home/hingnekar_mayur/k8s-practice/prometheus-alerting-0.20.0-helm/alertmanager-setup.yaml
kubectl dele... |
'use strict';
const fs = require('fs');
const StaticMaps = require('staticmaps');
const svg2img = require('svg2img');
const { Colors, Transport } = require('../helpers/enums');
const varsToChange = ['%arrow.fill', '%arrow.stroke', '%circle.fill', '%circle.stroke', '%direction', '%route.number'];
const transportMarke... |
# Localized resources for DSR_ReplaceText
ConvertFrom-StringData @'
SearchForTextMessage = Searching using RegEx '{1}' in file '{0}'.
StringNotFoundMessageAppend = String not found using RegEx '{1}' in file '{0}', change required.
StringNotFoundMessage = String not found using RegEx '{1}' in file '{0}', ch... |
/*
* An Adaptive Hash Table
* Sumer Cip 2012
*/
#ifndef YHASHTAB_H
#define YHASHTAB_H
#include "config.h"
#define HSIZE(n) (1<<n)
#define HMASK(n) (HSIZE(n)-1)
#define HLOADFACTOR 0.75
struct _hitem {
uintptr_t key;
uintptr_t val;
int free; // for recycling.
struct _hitem *next;
};
typedef str... |
using Microsoft.EntityFrameworkCore;
using Microsoft.Extensions.DependencyInjection;
using SampleBank.Business;
using SampleBank.Core.Abstractions.Business;
using SampleBank.Core.Abstractions.Persistence;
using SampleBank.Core.Entity;
using SampleBank.Persistence;
using SampleBank.Persistence.EF;
namespace SampleBank... |
ENV["GKSwstype"]="100"
using Literate
using Plots
import Remark
using Remark, FileWatching
# files = filter( f -> startswith(f, "0"), readdir("src")) |> collect
files = [ "01.Introduction.jl",
"02.RungeKuttaMethods.jl",
"03.PoissonEquation.jl",
"04.HOODESolver.jl",
"05.Con... |
# 우석대학교 컴퓨터공학과 커리큘럼
* [Web Skills](https://github.com/cbnuswoss/web-skills)를 이용하여 우리학교 CS 커리큘럼 페이지 만들기
## ✋ Team Members
* 
* 
* 
## ⚡ npm scripts
### Install
```
npm install
```
#... |
from subprocess import Popen, PIPE
import sys
import os
from queue import Queue, Empty
import subprocess
import threading
import time
class LocalShell(object):
def __init__(self):
pass
def run(self, cmd):
env = os.environ.copy()
p = Popen(cmd, stdin=PIPE, stdout=PIPE, stderr=subproces... |
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Text.RegularExpressions;
using System.Threading.Tasks;
using System.Windows.Forms;
using System.IO;
using NAudio.Wave;
namespace AlbumRecorder {
static class Program {
public const string GracenoteKey = "1032852198-E... |
#ifndef MCL_ARMIJO_H
#define MCL_ARMIJO_H
#include "Problem.hpp"
namespace mcl {
namespace optlib {
// Backtracking-Armijo
template<typename Scalar, int DIM, typename P>
class Armijo {
public:
typedef Eigen::Matrix<Scalar,DIM,1> VectorX;
typedef Eigen::Matrix<Scalar,DIM,DIM> MatrixX;
static Scalar linesearch(co... |
package dev.kord.core.behavior
import dev.kord.core.cache.data.ApplicationCommandData
import dev.kord.core.entity.application.GlobalUserCommand
import dev.kord.core.entity.application.GuildUserCommand
import dev.kord.core.entity.application.UserCommand
import dev.kord.rest.builder.interaction.UserCommandModifyBuilder
... |
# 
[](https://bintray.com/yuriy-budiyev/maven/code-scanner/_latestVersion)
[ => {
test('test case nums = [3, 1, 2, 5, 4]', () => {
expect(merge([3, 1, 2, 5, 4])).toEqual([1, 2, 3, 4, 5]);
});
test('test case nums = [1, 2, 3, 4, 5]', () => {
expect(merge([1, 2, 3, 4, 5]))... |
var a00240 =
[
[ "shared_ptr", "a00240.html#abdd4f7b20903037894fc3847905214ad", null ],
[ "Unit", "a00240.html#a33df813274f299f2d6d6e67c7e95c60f", null ],
[ "~Unit", "a00240.html#ac5c108d61c9bc4fd86939ead503368b5", null ],
[ "Mahalanobis", "a00240.html#a86bb771335c2071c0c764d9572866933", null ],
[ "... |
class FakeKafkaProducer
def initialize(real)
@messages = {}
@real = real
@stub = true
end
def unstub
@stub = false
yield
@stub = true
end
def produce(message, options = {})
topic = options[:topic]
self.channel(topic) << message
@real.produce(message, options) if not @stub... |
#!/bin/bash
root_password=`date +%s | sha1sum | head -c 12 ; echo`
echo "Updating root's password to ${root_password}."
echo "root:${root_password}" | chpasswd
echo "Removing IPv6 localhost from /etc/hosts."
# Sed can't always modify this thing in place?
sed -e 's/localhost ip6-localhost/ip6-localhost/g' /etc/hosts >... |
module Mailflow
class << self
attr_accessor :test_mode
end
class Client
include Mailflow::APIOperations
def self.test
response = get_request('test')
return {status: response.code}
end
end
end
|
package modules
import org.springframework.stereotype.Component
@Component
class MyBeanB {
def getMessage = "I am a message from a Spring Bean"
}
|
'use strict';
/*
* nodejs-express-mongoose
* Copyright(c) 2015 Madhusudhan Srinivasa <madhums8@gmail.com>
* MIT Licensed
*/
/**
* Module dependencies
*/
require('dotenv').config();
const fs = require('fs');
const join = require('path').join;
const express ... |
<?
$save_dir="./upload";
//파일 업로드 함수
function upload(&$file,$limit_file_size)
{
global $save_dir;
//금지된 확장자 설정 - 금지할 확장자를 추가해서 사용
$ban_ext = array('php','php3','html','htm','cgi','pl');
//업로드 파일 제한 크기를 초과하였는지 확인
if ($file[s... |
package main
import (
"bytes"
"context"
_ "embed"
"encoding/json"
"errors"
"fmt"
"image"
"image/jpeg"
"image/png"
"io"
"net/http"
"os"
"strconv"
"strings"
"sync"
"time"
"github.com/kelseyhightower/envconfig"
"github.com/nfnt/resize"
)
// Config struct. Main configuration options
type Config struct ... |
package org.mcdh.jda
import org.jetbrains.java.decompiler.main.decompiler.BaseDecompiler
import java.io.File
class Decompiler @JvmOverloads constructor(private val proxy: JavaDecompileProxy = JavaDecompileProxy()) {
fun decompile(path: String): String {
val target = File(path)
val files = mutableMapOf(Pair(sanit... |
---
sidebar:
title: "Algorithm"
nav: sidebar-algorithm
icon: "fas fa-calculator"
title: "[Swift] 수박수박수박수박수박수?"
toc: true
toc_sticky: true
toc_label: 목차
tag: "Programers level1"
depth:
- title: "Algorithm"
url: /algorithm/
icon: "fas fa-calculator"
- title: "Programers level1"
url: /algorithm/progr... |
export default function reducer(state = {
user: JSON.parse(localStorage.getItem('user_info'))||{},
posts: JSON.parse(localStorage.getItem('posts'))||{},
friends: JSON.parse(localStorage.getItem('friends'))||{},
token: localStorage.getItem('id_token') || null,
}, action) {
switch (action.type) {
... |
module.exports = function(req, res, next){
const username = req.body.username;
const password = req.body.password;
if (!username || !password) {
return res.status(400).json(
"username and password required"
)
} else {
next()
}
} |
import React, { useEffect } from 'react';
import Worker from './test.worker.js'; // eslint-disable-line
const videoUrl = '';
let data;
const initWorker = async () => {
const worker = new Worker();
const outputElement = {};
worker.onmessage = function (event) {
const message = event.data;
... |
name "manta"
maintainer "Wanelo, Inc"
maintainer_email "ops@wanelo.com"
license "MIT"
description "Installs/Configures manta"
long_description IO.read(File.join(File.dirname(__FILE__), 'README.md'))
version "1.0.5"
depends "nodejs"
depends "npm"
supports "smartos"
supports "ubu... |
/*-
* Copyright (c) 2003-2004 Tim Kientzle
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of c... |
<?php
declare(strict_types=1);
namespace Liquetsoft\Fias\Component\FiasInformer;
use Liquetsoft\Fias\Component\Exception\FiasInformerException;
use SoapClient;
use SoapFault;
use Throwable;
/**
* Объект, который получает ссылку на файл с архивом ФИАС
* от soap сервиса информирования ФИАС.
*/
class SoapFiasInform... |
package de.jlnstrk.transit.sample.android
import androidx.lifecycle.ViewModel
import de.jlnstrk.transit.common.extensions.require
import de.jlnstrk.transit.common.model.Coordinates
import de.jlnstrk.transit.common.model.Location
import de.jlnstrk.transit.common.response.StationBoardData
import de.jlnstrk.transit.commo... |
package akka.contrib.persistence.mongodb
import akka.actor.ActorSystem
import com.typesafe.config.{Config, ConfigException}
import scala.concurrent.ExecutionContextExecutor
import scala.util.{Failure, Success, Try}
abstract class WithMongoPersistencePluginDispatcher(actorSystem: ActorSystem, config: Config) {
imp... |
# Copyright (c) 2010-2011, Diaspora Inc. This file is
# licensed under the Affero General Public License version 3 or later. See
# the COPYRIGHT file.
namespace :migrations do
desc 'copy all hidden share visibilities from share_visibilities to users. Can be run with the site still up.'
task :copy_hidden_share_v... |
<?php
declare(strict_types=1);
namespace Baraja\Shop\Invoice;
use Baraja\Doctrine\ORM\DI\OrmAnnotationsExtension;
use Nette\DI\CompilerExtension;
final class ShopInvoiceExtension extends CompilerExtension
{
public function beforeCompile(): void
{
$builder = $this->getContainerBuilder();
OrmAnnotationsExtensi... |
package docker
import (
"context"
"encoding/base64"
"encoding/json"
"errors"
"fmt"
"io"
"io/ioutil"
"log"
"os"
"path/filepath"
"github.com/docker/docker/api/types"
"github.com/docker/docker/api/types/filters"
docker "github.com/docker/docker/client"
)
// Client for handling requests to the Docker API
ty... |
<?php
/**
* Pubble_Messenger
*
* @category Pubble
* @package Pubble_Messenger
* @author Pubble <ross@pubble.io>
* @copyright 2016 Pubble (http://www.pubble.io)
* @version 1.1.2
*/
/**
* Pubble_Messenger_Test_Config_Module
*
* @category Pubble
* @package Pubble_Messenger
* @subpackage Test
*/... |
#googlemarket
首页、专题、游戏界面如下:
  
分类、排行的界面
 
详情页面如下:

# 良心友情链接
[腾讯QQ群快速检索](http://u.720life.cn/s/8cf73f7c)
[软件免费开发论坛](http://u.720life.cn/s/bbb01dc0) |
<?php
namespace QuarkCMS\Quark\Component\Form\Fields;
use QuarkCMS\Quark\Component\Form\Fields\Item;
class Quarter extends Item
{
/**
* 组件类型
*
* @var string
*/
public $component = 'quarterField';
}
|
<?php
namespace TheBachtiarz\SerialNumber\Cache;
use TheBachtiarz\SerialNumber\Interfaces\ConfigInterface;
use TheBachtiarz\SerialNumber\Service\ApiKeyAccessService;
use TheBachtiarz\Toolkit\Cache\Service\Cache;
use TheBachtiarz\Toolkit\Helper\App\Converter\ArrayHelper;
use TheBachtiarz\Toolkit\Helper\App\Encryptor\E... |
-- --------------------------------------------------------
-- Host: 127.0.0.1
-- Server version: 8.0.12 - MySQL Community Server - GPL
-- Server OS: Win64
-- HeidiSQL Version: 9.5.0.5196
-- --------------------------------------------------------
/*... |
/*
* Copyright 2016 The BigDL Authors.
*
* 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 agr... |
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License.
import numpy as np
import os
class SlidingWindowTrainer():
@staticmethod
def SlidingTrainer(w: int, s: int, training_max_iter_vec: list, train, kwargs: dict, runInitialTrain=True):
'''
Assume: data i... |
package nosj
import (
"bufio"
"fmt"
)
type String struct {
s string
}
func NewString() *String {
return &String{}
}
func (str *String) Parse(s *bufio.Scanner) Node {
str.s = ScanQuote(s)
return str
}
func (str *String) String() string {
return fmt.Sprintf(`"%s"`, str.s)
}
func (str *String) PrettyString() ... |
# GitHub-Search
O GitHub Search é um app onde você pode informações do perfil de qualquer usuário do Github apenas digitando seu nome
Clique <a href="https://luanhma.github.io/GitHub-Search/">aqui</a> para acessar!
|
<?php
namespace decorator;
/**
* Created by PhpStorm.
* User: zhudong
* Date: 2017/7/14
* Time: 下午7:36
*/
class PulisherDerector implements PulisherInterface {
protected $pulisher = null;
function derect(PulisherInterface $pulisher) {
$this->pulisher = $pulisher;
}
public function pul... |
package Paws::MediaLive::AacSettings;
use Moose;
has Bitrate => (is => 'ro', isa => 'Num', request_name => 'bitrate', traits => ['NameInRequest']);
has CodingMode => (is => 'ro', isa => 'Str', request_name => 'codingMode', traits => ['NameInRequest']);
has InputType => (is => 'ro', isa => 'Str', request_name =>... |
use super::nms::{NmsOutput, NonMaxSuppression, NonMaxSuppressionInit};
use crate::common::*;
use tch_goodies::detection::MergedDenseDetection;
#[derive(Debug)]
pub struct YoloInferenceInit {
pub nms_iou_thresh: R64,
pub nms_conf_thresh: R64,
}
impl YoloInferenceInit {
pub fn build(self) -> Result<YoloInfe... |
export { addUserToDefaultChannels } from './addUserToDefaultChannels';
export { addUserToRoom } from './addUserToRoom';
export { archiveRoom } from './archiveRoom';
export { attachMessage } from './attachMessage';
export { checkEmailAvailability } from './checkEmailAvailability';
export { checkUsernameAvailability } fr... |
I know how to code **Java** and I am new to **C++** but I am sure it will be *similar* enough to be understood.
|
#!/bin/bash
if [ ! -d "build" ]; then
echo "Build directory does not exist, running ./build.sh"
./build.sh
fi
cd build
if [ ! -d ".git" ]; then
echo "Git not initialized in build directory, cloning gh-pages"
git init
git remote add origin git@github.com:SlateFoundation/slate-cbl.git
fi
echo "Ens... |
[1.0.0]: https://github.com/real-digital/half-flake/commits/1.0.0
# Changelog
All notable changes to this project will be listed in this file.
## [1.0.0] - 2019-06-27
The first release as a separated library
|
-- @testpoint: opengauss关键字collate(保留),作为游标名,部分测试点合理报错
--前置条件
drop table if exists collate_test cascade;
create table collate_test(cid int,fid int);
--关键字不带引号-失败
start transaction;
cursor collate for select * from collate_test order by 1;
close collate;
end;
--关键字带双引号-成功
start transaction;
cursor "collate" for selec... |
ori $ra,$ra,0xf
mflo $6
mthi $0
srav $0,$6,$2
ori $4,$5,38212
mflo $5
mthi $4
mtlo $4
sb $3,15($0)
mflo $0
ori $0,$4,30354
div $6,$ra
mthi $1
sll $5,$3,1
lb $4,16($0)
lb $4,1($0)
mflo $4
lui $0,42531
ori $2,$2,37357
sb $5,1($0)
mfhi $5
divu $2,$ra
div $5,$ra
lui $2,20042
addiu $3,$1,-14581
srav $0,$4,$3
addu $4,$3,$3
s... |
#!/bin/bash
source 'common.sh'
kl_heading 'Setup docker'
kl_cmd 'build docker image klueless/web-{{dashify settings.application}}'
docker image build -t klueless/web-{{dashify settings.application}} ../.
kl_cmd_end
|
package com.wavesplatform.dex.api
import java.time.LocalDateTime
import akka.http.scaladsl.model.ws.{BinaryMessage, Message, TextMessage}
import akka.http.scaladsl.server.Route
import akka.stream.Materializer
import akka.stream.scaladsl.{Flow, Sink, Source}
import com.wavesplatform.dex.api.http.ApiRoute
import io.swa... |
SELECT
ogc_fid AS t_id,
ST_Multi(wkb_geometry) AS geometrie,
id_wp,
fid_amtei,
fid_fk,
fid_fr,
wirt_zone,
gem_bfs,
hoheitsgrenzen_gemeindegrenze.gemeindename,
fid_we,
round(gb_flaeche,0) AS gb_flaeche,
we_text,
fid_eigcod,
CASE
WHEN fid_eig = 1000
... |
package com.pubnub.api.managers;
import com.pubnub.api.PubNub;
import com.pubnub.api.callbacks.ReconnectionCallback;
import com.pubnub.api.enums.PNReconnectionPolicy;
import lombok.extern.slf4j.Slf4j;
import java.util.Timer;
import java.util.TimerTask;
@Slf4j
public class DelayedReconnectionManager {
private sta... |
package com.chaidarun.chronofile
import android.os.Bundle
import android.util.Log
import android.view.View
import android.view.ViewGroup
import android.widget.CheckBox
import android.widget.RadioButton
import android.widget.TextView
import androidx.appcompat.app.AlertDialog
import com.jakewharton.rxbinding2.view.RxVie... |
import { AxiosResponse } from "axios";
import * as ProfileTypes from "./profiles";
import * as EventTypes from "./events";
import * as TenantTypes from "./tenants";
import * as AppTypes from "./apps";
import { QueryParams } from "./queryBuilder"
import { FilteredResponse } from "./sdkResponse";
import { AggregateEventT... |
/***************************************************************************
qgsprocessingmodelcomponent.h
-----------------------------
begin : June 2017
copyright : (C) 2017 by Nyall Dawson
email : nyall dot dawson ... |
# A Request-Response Example with Status Code
A sample [Express](http://expressjs.com/) application to demo http request-response with status code.
## Run locally
1. Install [Node.js and npm](https://nodejs.org/)
1. Run `git clone https://github.com/ywdeng/wp19-node-05-response-400.git`
1. Run `cd wp19-node-05-respo... |
namespace Hades.Syntax.Lexeme
{
public enum Category
{
Unknown,
WhiteSpace,
Comment,
Literal,
Identifier,
Grouping,
Punctuation,
Operator,
Invalid,
Other,
Assignment,
LeftHand,
RightHand
}
} |
# -*- coding: utf-8 -*-
require 'open-uri'
require 'nokogiri'
class Excuse
include Cinch::Plugin
match /excuse/, :use_prefix => true
def execute m
url = "http://www.programmerexcuses.com"
begin
doc = Nokogiri::HTML(open url)
m.reply doc.at('a').content
rescue
m.reply "Meh ¯\\_(ツ)... |
<?php
class __FlowStateFactory {
const ACTION_STATE = 1;
const START_STATE = 2;
const END_STATE = 3;
const DECISION_STATE = 4;
const SUBFLOW_STATE = 5;
static public function createState($state_type) {
$return_value = null;
switch((int)$state_type) {
case self:... |
#!/bin/sh
execpath=$(dirname $BASH_SOURCE)
function getTimestamp() {
timestamp=$(date +%s);
return $timestamp;
}
function generateHash() {
hashstart=getTimestamp;
hash=$(md5 -qs $hashstart);
return $hash;
}
# Set up database user. Run this script immediately after cloning the codebase and before... |
export enum HintLevel{ 'EASY', 'LIGHT', 'MEDIUM', 'EXTERME' }
export interface Hint {
char: String;
pos: Number;
}
export class Word {
public word: String;
public scramWord: String;
constructor(word: String) {
this.word = word;
this.scramWord = this.scrambleWord();
}
p... |
/*
* Copyright (C) 2019 Open Source Robotics Foundation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by appl... |
from django import template
from django.utils.safestring import mark_safe
from pygments import highlight
from pygments.formatters import HtmlFormatter
from pygments.lexers import guess_lexer_for_filename, TextLexer
from pygments.util import ClassNotFound
register = template.Library()
@register.filter('highlight')
de... |
fun funWithoutArgs(): Int {
return Any().hashCode().toInt()
}
fun funWithAnyArg(value_1: Any): Int {
return value_1.hashCode()
}
fun <K> select(vararg x: K): K = x[0]
fun <K> expandInv(vararg x: Inv<K>): K = x[0] as K
fun <K> expandIn(vararg x: In<K>): K = x[0] as K
fun <K> expandOut(vararg x: Out<K>): K = x... |
{-# LANGUAGE DeriveDataTypeable #-}
--
-- Licensed to the Apache Software Foundation (ASF) under one
-- or more contributor license agreements. See the NOTICE file
-- distributed with this work for additional information
-- regarding copyright ownership. The ASF licenses this file
-- to you under the Apache License, Ve... |
import * as github from '@actions/github';
import * as core from '@actions/core';
import * as formatter from './formatter';
import * as matrix from './matrix';
import Report from './Report';
import {TestFilter} from './TestFilter';
const GITHUB_SUMMARY_LIMIT = 50000;
function truncateByBytesUTF8(str: string, limit: n... |
// Copyright (c) 2020 DDN. All rights reserved.
// Use of this source code is governed by a MIT-style
// license that can be found in the LICENSE file.
//! # Breakpoints
//!
//! This module lists the existing media breakpoints we use and contains some helper functions for working with them.
//!
//! It should be kept i... |
import React from 'react';
import { WrapProps } from '@interfaces/render';
export default class _Wrap extends React.Component<WrapProps, {}> {
render() {
const { Container, App, containerProps, appProps } = this.props;
return (
<Container {...containerProps}>
<App {...appProps} />
</Con... |
package com.univocity.trader.exchange.interactivebrokers;
import java.util.*;
import static com.univocity.trader.exchange.interactivebrokers.TradeType.*;
/**
* Security types with defaults taken from https://interactivebrokers.github.io/tws-api/basic_contracts.html
*
* @author uniVocity Software Pty Ltd - <a href... |
package fortos.model.step.timer
import fortos.engine.processor.EngineProcessor
import fortos.engine.processor.time.ConstantTimerEngineProcessor
import fortos.model.step.Step
@EngineProcessor(ConstantTimerEngineProcessor::class)
data class ConstantTimerStep(
override val type: String,
override val workload: Li... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.