text
stringlengths
1
1.05M
#!/bin/bash # Start Server in development or production # Development will watch for python file changes serverFile="${PWD}/src/server.py" devServerFile="${PWD}/src/sourceChangeMonitor.py" if [ "$APP_ENVIRONMENT" = "development" ] then # watch files for changes python $devServerFile $serverFile else # Ru...
/********************************************************************* * Software License Agreement (BSD License) * * Copyright (c) 2012-2016, <NAME> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditi...
#!/bin/bash mvnw org.springframework.cloud:spring-cloud-contract-maven-plugin:2.1.0.BUILD-SNAPSHOT:convert
<filename>CommonUtils/src/com/cats/utils/UserDirRestore.java<gh_stars>0 /* * Copyright 2015 lixiaobo * * VersionUpgrade project licenses this file to you 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 ...
<filename>f_stub_mock_operation/test_lib_mock.py<gh_stars>1-10 from typing import List from datetime import date import lib import pytest_mock def test_room602_operations_log(operation_data: List[lib.Operation], mocker: pytest_mock.MockFixture): mocker.patch('lib.get_operations_fr...
from kivy.app import App from kivy.clock import Clock from kivy.uix.label import Label from kivy.uix.floatlayout import FloatLayout from kivy.properties import NumericProperty, ObjectProperty from kivy.vector import Vector from kivy.animation import Animation class TextLabel(Label): angle = NumericProperty(0) ...
from typing import Tuple def parse_package_definition(code_snippet: str) -> Tuple[str, str]: # Find the index of the opening and closing single quotes start_quote_index = code_snippet.find("'") end_quote_index = code_snippet.rfind("'") # Extract the package name and version using string slicing pa...
SELECT city_name FROM cities WHERE country = 'France'
#!/usr/bin/env bash # To use an OpenStack cloud you need to authenticate against the Identity # service named keystone, which returns a **Token** and **Service Catalog**. # The catalog contains the endpoints for all services the user/tenant has # access to - such as Compute, Image Service, Identity, Object Storage, Blo...
#!/bin/bash #SBATCH -J Act_selu_1 #SBATCH --mail-user=eger@ukp.informatik.tu-darmstadt.de #SBATCH --mail-type=FAIL #SBATCH -e /work/scratch/se55gyhe/log/output.err.%j #SBATCH -o /work/scratch/se55gyhe/log/output.out.%j #SBATCH -n 1 # Number of cores #SBATCH --mem-per-cpu=6000 #SBATCH -t 23:59:00 # Hours, minutes and...
/// <reference path="../../core/Collider.ts"/> /// <reference path="../../math/Rectangle.ts"/> module WOZLLA.component { /** * @class WOZLLA.component.MaskCollider */ export class MaskCollider extends WOZLLA.Collider { collideXY(localX:number, localY:number):boolean { return true...
<reponame>mykaelandrade/fiscal4j package br.indie.fiscal4j.validadores; public abstract class IntegerValidador { public static void tamanho4(final Integer valor, final String info) { IntegerValidador.limite(valor, 9999, info); } public static void tamanho7(final Integer valor, final String info) ...
package de.schub.marathon_scaler.Monitoring.Backend.Prometheus.Exception; /** * Exception thrown when a query failed */ public class PrometheusQueryException extends PrometheusException { public PrometheusQueryException(String expression, String error) { super(String.format("Failed to execute prometh...
const gulp = require("gulp"); const sass = require("gulp-sass"); const typescript = require("gulp-tsc"); const sassPaths = ['./static/*.scss']; // Don't include the node_modules folder const tsPaths = ['./server.ts', './app/**/*.ts']; // Don't include the node_modules folder gulp.task('task-typescript', () => { gulp...
#!/bin/sh filesdir=$1 searchstr=$2 cd if [ "$#" -ne 2 ] ; then echo "2 arguments required" echo "1: the file directory path" echo "2: the name of the file" exit 1 else if [ -d "${filesdir}" ] ; then cd "${filesdir}" numlines=$(grep -x -r "${searchstr}" * | wc -l) numfiles=$(grep -l -Rx "${filesdir}" -e "${s...
#!/bin/bash # # Metrics sync will takes metrics from the osde2e metrics bucket and sync them with the datahub Prometheus pushgateway. # METRICS_BUCKET=osde2e-metrics INCOMING=incoming PROCESSED=processed VENV="$(mktemp -d)" METRICS_DIR="$(mktemp -d)" METRIC_TIMEOUT_IN_SECONDS=21600 # 6h in seconds METRIC_ADDON_TIMEOUT...
#! /bin/sh #================================================== # # updated: 03/22/20 Reach Technology # # this script controls a system critical function # and must not be put under control of chkconfig # #================================================== # # WARNING: If your hardware clock is not in UTC/GMT, thi...
function toUpper(arr) { let temp = []; for (let i = 0; i < arr.length; i++) { temp.push(arr[i].toUpperCase()); } return temp; }
<reponame>collosdeveloper/tt package com.knyaz.testtask.api.model.pojos; import android.text.format.DateUtils; import java.io.Serializable; import java.util.Date; import java.util.List; public class VideoItem implements Serializable { public String id; public String url; public String name; public St...
<gh_stars>0 'use strict'; // external deps var ObjectId = require('mongodb').ObjectId; // internal deps require('mongodb-toolkit'); var MmModels = require('mm-models'); var map = MmModels.map; var ArticleApproval = MmModels.master.article.ArticleApproval; var ArticleBrand = MmModels.master.article.ArticleBrand; var...
<gh_stars>1-10 /* 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 distributed un...
<reponame>milogert/website import styles from './sections.module.css' const Sections = () => <div> Sections here. </div> export default Sections
<gh_stars>1-10 #ifdef ESP8266 #include <ESP8266WiFi.h> #else #include <WiFi.h> #endif #include <WiFiUdp.h> #include <OSCMessage.h> #include <OSCBundle.h> #include <OSCData.h> #include <Servo.h> char ssid[] = "*********"; //your network SSID char pass[] = "*********"; //your network password WiFiUDP ...
#pragma once #include <vector> #include "triangle.h" #include "aabb.h" class DebugMesh { public: DebugMesh(); std::vector<Triangle>::const_iterator begin() const { return m_triangles.cbegin(); } std::vector<Triangle>::const_iterator end() const { return m_triangles.cend(); ...
#!/bin/bash -eu source functions.sh FILE_SQL="${1}" get_customer_name get_athena_credentials convert_sql_to_spatialite echo info "Created: ${FILE_VRT}" info "Created: ${FILE_SQLITE}"
<reponame>wjtree/wechat-parent<filename>wechat-sdk/src/main/java/com/app/wechat/request/WxMaterialAddNewsRequest.java /** * Copyright (c) 2017. Lorem ipsum dolor sit amet, consectetur adipiscing elit. * Morbi non lorem porttitor neque feugiat blandit. Ut vitae ipsum eget quam lacinia accumsan. * Etiam sed turpis ac ...
require 'yt/models/base' require 'yt/models/right_owner' module Yt module Models # Provides methods to interact with YouTube ContentID asset ownership, # which provide ownership information for the specified asset. # @see https://developers.google.com/youtube/partner/docs/v1/ownership class Ownership...
public static int Fibonacci(int n) { if (n == 0) return 0; if (n == 1) return 1; return Fibonacci(n - 1) + Fibonacci(n - 2); }
#!/bin/bash REPO=mac-config echo "Syncing Github Pages Build for $REPO.." # # What SHA are we going to deploy? SHA=$(git rev-parse --short HEAD) # # When you build the static site, where is it generated? BUILD_DIR=gh-pages # # Create the static site in ./gh-pages rake build-gh-pages # # What branch serves as the s...
#!python3.6 import sys import re def line2command(line): m = re.search('\{.*\}\{', line) cmd = m.group()[2:-2] m = re.search('\}\{.*\}\n', line) text = m.group()[2:-2] return [cmd, text] def plain2latex(line, cmds): tmp = line for cmd in cmds: tmp = re.sub(" "+cmd[1]+" ", "~\\"+cmd...
<reponame>wongoo/alipay-sdk-java-all<gh_stars>0 package com.alipay.api.response; import com.alipay.api.AlipayResponse; /** * ALIPAY API: alipay.business.mall.points.notify response. * * @author auto create * @since 1.0, 2021-12-08 21:28:06 */ public class AlipayBusinessMallPointsNotifyResponse exten...
<gh_stars>1-10 #include "cipher/aes_cipher.h" #include "cipher/ctr_cipher_mode.h" #include "string/extended_std_string.h" #include "cipher/counter.h" #include "hex_coding/hex_coding.h" #include "gtest/gtest.h" #include <vector> struct PlaintextCiphertextPair { ExtendedStdString plaintext; ExtendedStdString ...
<filename>src/main/scala/Algorithms/Recursion/Min.scala package Algorithms.Recursion /** * Created by MikBac on 29.09.2020 */ object Min { def min(xs: List[Int]): Int = { if (xs.length != 1) { min(xs.head, min(xs.tail)) } else { xs.head } } def min(numb1: Int, numb2: Int): Int = { ...
package com.unboundid.ldap.sdk; public class LDAPConnection { public AsyncRequestID asyncSearch(ReadOnlySearchRequest searchRequest) throws LDAPException { return null; } public AsyncRequestID asyncSearch(SearchRequest searchRequest) throws LDAPException { return null; } public SearchResult search(ReadOnlySearc...
/** * Copyright IBM Corp. 2016, 2018 * * This source code is licensed under the Apache-2.0 license found in the * LICENSE file in the root directory of this source tree. */ import { Close16, WarningFilled16, CheckmarkFilled16, } from '@rocketsoftware/icons-react'; import { settings } from '@rocketsoftware/c...
<reponame>afreeorange/wifi-qrcode-generator (() => { const IMAGE_SIZE_IN_PIXELS = 1024; const $ = document.querySelector.bind(document); const qrcode = new QRCode($(".qrcode"), { text: "http://jindo.dev.naver.com/collie", width: IMAGE_SIZE_IN_PIXELS, height: IMAGE_SIZE_IN_PIXELS, colorDark: "#000...
echo "In run.sh script!" date chpl --version module list BENCHMARKS="stream argsort gather scatter reduce scan" node_counts=(1 2 4 8 16 32) for benchmark in ${BENCHMARKS}; do for i in {1..1}; do for nodes in "${node_counts[@]}"; do dir=$PWD/ak-perf-$nodes rm -rf $dir ./benchmarks/run_benchma...
import { Injectable } from "@angular/core"; import { StarPRNT } from "@ionic-native/star-prnt/ngx"; import { Printer, PrintOptions } from "@ionic-native/printer/ngx"; import { AlertController, Platform } from "@ionic/angular"; import { File } from "@ionic-native/file/ngx"; import { FileOpener } from "@ionic-native/file...
#! /bin/bash # Copyright 2020 Peter Williams <peter@newton.cx> and collaborators # Licensed under the MIT License. # A very simple script to build static GitHub Pages content. This will # probably be superseded pretty soon. set -euo pipefail cd "$(dirname $0)" version="$(cranko show version cranko)" sed -e "s/@VERS...
def calculate_bmi(height, weight): return round(weight / (height / 100) ** 2, 2)
#!/bin/bash set -e case $1 in noroot) shift echo "==> executing as non-root user: $@" exec gosu ${DEFAULT_USER} $@ ;; *) echo "==> executing as root user: $@" cmdline="$@" exec ${cmdline:-"bash"} ;; esac # vim:set ft=sh ff=unix:
#!/usr/bin/env python3 # coding=utf-8 # # Copyright (c) 2020 Huawei Device Co., Ltd. # 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...
<reponame>hoodini47/gatsby-video-portfolio-page<filename>src/components/list-of-menu-items.js import React from "react" import { Link } from "gatsby" import { graphql, useStaticQuery } from 'gatsby' export const ListOfMenuItems = () => { const data = useStaticQuery(graphql` query MyMenuQuery { allDatoC...
export type Noop = () => void; export type Primitive = string | number | boolean;
echo "# 默认注释了源码镜像以提高 apt update 速度,如有需要可自行取消注释">/etc/apt/sources.list \ && echo "deb https://mirrors.tuna.tsinghua.edu.cn/debian/ buster main contrib non-free">>/etc/apt/sources.list \ && echo "# deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ buster main contrib non-free">>/etc/apt/sources.list \ && ...
#!/bin/sh $((123)) $((a|=123)) $((a&=123)) $((a^=123))
def get_latest_version(): """ Get the latest version of the ‘test_package’ package. :return: The version string (e.g. '1.0.0') """ url = 'https://test_package-db.org/api/version.json' response = requests.get(url) data = response.json() version = data['version'] ...
<reponame>Nebulon/nebpyclient<gh_stars>1-10 # # Copyright 2021 Nebulon, Inc. # All Rights Reserved. # # DISCLAIMER: THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, # EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT...
#!/bin/sh # Copyright 2019 Google LLC # # 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 i...
<reponame>marvelperseus/Real-Estate-website-frontend import React from 'react'; import { withStyles } from 'material-ui/styles'; import Input, { InputLabel } from 'material-ui/Input'; import Chip from 'material-ui/Chip'; import { FormControl } from 'material-ui/Form'; import Divider from 'material-ui/Divider'; import T...
main_dir="/home/j/Insync/jmmunozp@usp.br/Google Drive - Shared with me/NitrogenResponsiveGenotypes/Salmon2/SalmonQuant" test_dir="/home/j/BIOINFORMATICA/test_RNAseq" ls "$main_dir" | grep Sample > ${test_dir}/samples2.txt for i in $(cat ${test_dir}/samples2.txt) do mkdir -p "${test_dir}"/"$i" head -n1000 "${main_dir}...
<gh_stars>0 package uk.co.mruoc.json.mask.phone; import com.fasterxml.jackson.databind.ObjectMapper; import com.jayway.jsonpath.JsonPath; import uk.co.mruoc.json.mask.JsonMasker; import uk.co.mruoc.json.mask.JsonPathConfig; import java.util.Collection; public class PhoneNumberJsonMasker extends JsonMasker { pub...
<reponame>mpermar/debezium-incubator /* * Copyright Debezium Authors. * * Licensed under the Apache Software License version 2.0, available at http://www.apache.org/licenses/LICENSE-2.0 */ package io.debezium.connector.oracle.logminer; import static org.fest.assertions.Assertions.assertThat; import static org.mock...
// const electron = require ('electron'); const { app, BrowserWindow, dialog, globalShortcut, ipcMain, Menu, shell } = electron; // const remoteMain = require ('@electron/remote/main'); // remoteMain.initialize (); // let mainWindow = null; // const gotTheLock = app.requestSingleInstanceLock (); if (!gotTheLock) { ...
def update_snippet( data: schemas.snippet.SnippetData, auth_token: str = fastapi.Depends(oath) ) -> schemas.snippet.SnippetResponse: """ update the code snippet with the specified id. """ try: # Authenticate the user using the provided auth_token user = authenticate_user(auth_tok...
import codecs import csv import datetime import json import time from django.core.paginator import Paginator from django.http import StreamingHttpResponse from django.shortcuts import render, Http404, redirect, HttpResponse from polls.models import Equipment, Data from account.models import User from pyecharts.charts...
<filename>blingfireclient.library/inc/FATransform_hyph_redup_rev_t.h /** * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */ #ifndef _FA_TRANSFORM_HYPH_REDUP_REV_T_H_ #define _FA_TRANSFORM_HYPH_REDUP_REV_T_H_ #include "FAConfig.h" #include "FATransformCA_t.h"...
import React from 'react'; import { Form } from 'antd'; // Assuming the use of Ant Design library for form components class CustomForm extends React.Component { render() { const { layout = 'vertical', form, onSubmit, onFinishFailed, className, style } = this.props; re...
import { CacheInterceptor, CacheModule, MiddlewareConsumer, Module, NestModule, } from '@nestjs/common' import { ConfigModule, ConfigService } from '@nestjs/config' import { TypeOrmModule, TypeOrmModuleOptions } from '@nestjs/typeorm' import * as Joi from 'joi' import { SnakeNamingStrategy } from 'typeorm-nam...
what I suppose to do :(())
package be.kwakeroni.evelyn.model.impl; import be.kwakeroni.evelyn.model.Event; import be.kwakeroni.evelyn.model.ParseException; import java.time.LocalDateTime; import java.time.format.DateTimeFormatter; import java.util.regex.Matcher; import java.util.regex.Pattern; class RecordStructure { private static Recor...
<filename>lang/py/cookbook/v2/source/cb2_8_7_sol_1.py # code snippet to include in your sitecustomize.py import sys def info(type, value, tb): if hasattr(sys, 'ps1') or not ( sys.stderr.isatty() and sys.stdin.isatty() ) or issubclass(type, SyntaxError): # Interactive mode, no tty-like de...
#! /bin/bash mkdir /home/dmwm/dbs_test/ pushd /home/dmwm/dbs_test/ curl -o .pylintrc https://raw.githubusercontent.com/dmwm/WMCore/master/standards/.pylintrc git clone https://github.com/dmwm/DBS.git pushd DBS git checkout master popd popd
#!/usr/bin/env bash # ****************************** # * * # * Configure OSX GUI * # * * #******************************* # Credits https://pawelgrzybek.com/change-macos-user-preferences-via-command-line/ _installOSXsetup() { unset THISNAME DATA loc...
<gh_stars>10-100 #include "MemBitMap.hpp" #include "catch2/catch.hpp" CATCH_TEST_CASE("MemBitMap tests") { auto bitmap = new MemBitMap(); CATCH_SECTION("basic map") { bitmap->add_map(0x1000, 0x100); CATCH_REQUIRE(bitmap->has_addr(0x1000)); bitmap->set_bit_range(0x1000, 0x10, MapFl...
/** * The MIT License (MIT) * * Copyright (c) 2014 <NAME>, University of Massachusetts * * 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 lim...
#!/bin/bash # AUTHORS # # The Veracruz Development Team. # # COPYRIGHT # # See the `LICENSE.markdown` file in the Veracruz root directory for licensing # and copyright information. cd /work/rust-optee-trustzone-sdk/optee-qemuv8-3.7.0/build ln -sf /work/rust-optee-trustzone-sdk/optee-qemuv8-3.7.0/out-br/images/rootfs.cp...
#!/bin/sh #SBATCH -N 1 # nodes requested #SBATCH -n 1 # tasks requested SBATCH --partition=standard SBATCH --gres=gpu:8 #SBATCH --mem=12000 # memory in Mb #SBATCH --time=0-08:00:00 export CUDA_HOME=/opt/cuda-9.0.176.1/ export CUDNN_HOME=/opt/cuDNN-7.0/ export STUDENT_ID=$(whoami) export LD_LIBRARY_PATH=${CUDNN...
var _maximum_for_leaky_relu_8cpp = [ [ "BOOST_FIXTURE_TEST_CASE", "_maximum_for_leaky_relu_8cpp.xhtml#a40c4197840ac14d9cccab5585285ad37", null ], [ "BOOST_FIXTURE_TEST_CASE", "_maximum_for_leaky_relu_8cpp.xhtml#a89f2f61aa18c4c179f26e8a0d328b12c", null ], [ "BOOST_FIXTURE_TEST_CASE", "_maximum_for_leaky_relu...
// from: https://gitlab.com/mpapp-public/prosemirror-recreate-steps/blob/master/src/recreate.js import { Transform, ReplaceStep } from 'prosemirror-transform' import { applyPatch, createPatch } from 'rfc6902' import {diffWordsWithSpace, diffChars} from 'diff' function getReplaceStep (fromDoc, toDoc) { let start...
<gh_stars>0 import { async, inject, TestBed } from '@angular/core/testing'; import { MockBackend } from '@angular/http/testing'; import { XHRBackend, Response, HttpModule } from '@angular/http'; import { OAuthSe...
/* * Copyright (c) 2018-2021 <NAME> * * 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...
<filename>nitro-python/nssrc/com/citrix/netscaler/nitro/resource/config/cluster/clusternodegroup.py # # Copyright (c) 2008-2016 Citrix Systems, Inc. # # Licensed under the Apache License, Version 2.0 (the "License") # you may not use this file except in compliance with the License. # You may obtain a copy of the ...
package clientAPI.impl; import javax.smartcardio.Card; import javax.smartcardio.CardChannel; import javax.smartcardio.CardException; import javax.smartcardio.CommandAPDU; import javax.smartcardio.ResponseAPDU; /** * Klasse zur Kapselung der direkten Kommunikation mit der Smartcard. * */ public final cl...
<filename>admin/vue2/element-admin-v3/node_modules/@antv/g-canvas/esm/util/util.js export function getPixelRatio() { return window ? window.devicePixelRatio : 1; } /** * 两点之间的距离 * @param {number} x1 起始点 x * @param {number} y1 起始点 y * @param {number} x2 结束点 x * @param {number} y2 结束点 y */ export function dista...
<filename>src/main/java/chylex/hee/world/feature/blobs/populators/BlobPopulatorLiquidPool.java package chylex.hee.world.feature.blobs.populators; import java.util.HashSet; import java.util.List; import java.util.Random; import java.util.Set; import net.minecraft.block.Block; import net.minecraft.init.Blocks; import chy...
#!/usr/bin/env python # =========================================================================== # Copyright 2017 `<NAME>` # Email: ttungl at gmail dot com # # Heterogeneous Architecture Configurations Generator for Multi2Sim simulator # (aka, `HeteroArchGen4M2S`) # `HeteroArchGen4M2S` is free software, which is fr...
package com.github.teocci.android.bluetoothrecycleview.adapters; import android.content.Context; import android.support.v7.widget.RecyclerView; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import com.github.teocci.android.bluetoothrecycleview.R; import com.github.teocci...
<gh_stars>1-10 """Leetcode 547. Friend Circles Medium URL: https://leetcode.com/problems/friend-circles/ There are N students in a class. Some of them are friends, while some are not. Their friendship is transitive in nature. For example, if A is a direct friend of B, and B is a direct friend of C, then A is an indir...
#!/bin/bash ${CXX:-g++} -fprofile-arcs -ftest-coverage -fPIC -O0 example.cpp -o program ./program #BEGIN gcovr gcovr -r . --branches #END gcovr rm -f program *.gc*
<reponame>jab142/tasktimer<filename>app/src/main/java/com/ergdyne/tasktimer/ExportFragment.java package com.ergdyne.tasktimer; import android.app.Activity; import android.app.AlertDialog; import android.app.Fragment; import android.content.DialogInterface; import android.content.pm.PackageManager; import android.datab...
import React, { Component } from "react"; import PropTypes from "prop-types"; class Result extends Component { constructor(props) { super(props); this.state = { participantFirstName: "", participantLastName: "", participantGender: "", participantOtherGender: "", participantRace...
<filename>src/dijkstra/Boj11900.java package dijkstra; import java.io.BufferedReader; import java.io.InputStreamReader; import java.util.Arrays; import java.util.PriorityQueue; import java.util.StringTokenizer; /** * * @author exponential-e * 백준 11900번: 차이 그래프 * * @see https://www.acmicpc.net/problem/11900/ * ...
// +build !unit package eventstore_test import ( "context" "errors" "sync" "testing" "time" "github.com/GabrielCarpr/cqrs/bus" "github.com/GabrielCarpr/cqrs/eventstore" "github.com/GabrielCarpr/cqrs/eventstore/memory" "github.com/GabrielCarpr/cqrs/eventstore/postgres" "github.com/GabrielCarpr/cqrs/log" "g...
#!/bin/bash # Copyright (c) Facebook, Inc. and its affiliates. # # This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. # scripts directory THIS_DIR=$(cd -P "$(dirname "$(readlink "${BASH_SOURCE[0]}" || echo "${BASH_SOURCE[0]}")")" && pwd) REACT_NATI...
#include "game.h" #include <iostream> Game::Game(b2World& world, int okrazenia, int liczbaprzeciwnikow, Image& img, RenderWindow& window, int trasa, string strNazwaPng, char* chNazwaTxt) : view(window.GetDefaultView()) { double pospoc[2] = {0.0, 0.0}; nOkrazenia = okrazenia; nLiczbaPrzeciwnikow = liczbaprz...
# Copyright (c) [2022] Huawei Technologies Co.,Ltd.ALL rights reserved. # This program is licensed under Mulan PSL v2. # You can use it according to the terms and conditions of the Mulan PSL v2. # http://license.coscl.org.cn/MulanPSL2 # THIS PROGRAM IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KI...
<filename>test/server/serverEnvTest.ts /// <reference path="../../typings/index.d.ts" /> const Code = require('code'); // assertion library const Lab = require('lab'); const lab = exports.lab = Lab.script(); const Hapi = require('hapi'); const env = process.env.env; delete process.env.env; import server from "../../...
function generateDynamicButton($label, $url, $options) { $defaultOptions = ['onclick' => "window.location.href='$url'"]; $options = array_merge($defaultOptions, $options); return Html::button($label, $options); }
#!/bin/bash export DEBIAN_FRONTEND=noninteractive apt-get -y update apt-get -y dist-upgrade apt-get -y install software-properties-common apt-add-repository ppa:ansible/ansible apt-get -y update apt-get -y install ansible python-pip pip install jmespath # needed for Ansible json_query echo 'ubuntu ALL=NOPASSWD:AL...
#!/bin/zsh sed "s/ /,/" wool_extract.txt > mid_1.txt sed "s/ //" mid_1.txt > mid_2.txt sed "s/2016/2016,/" mid_2.txt > mid_3.txt sed "s/2017/2017,/" mid_3.txt > mid_4.txt sed "s/2018/2018,/" mid_4.txt > mid_5.txt sed "s/2019/2019,/" mid_5.txt > mid_6.txt sed "s/2020/2020,/" mid_6.txt > mid_7.txt sed "s/Date/Date,/" mi...
func sum(to n: Int) -> Int { var result = 0 for number in 1...n { // O(n) result += number } return result }
<reponame>mevoly/-<filename>pages/goods_detail/index.js import{ request } from "../../request/index.js"; import regeneratorRuntime from '../../lib/runtime/runtime'; Page({ data: { goodsObj:{}, //商品是否被收藏过 isCollect:false }, GoodsInfo:{}, onShow: function () { let pages = getCurrentPages(); ...
def binary_search(X, target): # Set the lower limit lower = 0 # Set the upper limit upper = len(X) - 1 # Check if list contains 1 element if upper == 0 and X[0]==target: return 0 while lower <= upper : # Calculate the mid point mid = ( lower + upper )...
import vtk def printme(string): print(string) return printme("abc") # print(a) def move_actor(name): axes = vtk.vtkAxesActor() axes.SetTotalLength(10, 10, 10) axes.SetShaftType(0) axes.SetAxisLabels(0) axes.SetCylinderRadius(0.02) print("123") return move_actor("a")
#!/usr/bin/env bash # A script to deploy all of the microservices to openshift # OBS. If you`re no running/using https://github.com/fabric8io/fabric8-maven-plugin # microservice-authz cd microservice-authz mvn clean package declare -a authz_sha256=($(shasum -a 256 target/microservice-authz-swarm.jar)) docker build -t...
#!/bin/bash # inspired/adapted from: https://github.com/leucos/ansible-rsync-backup/blob/master/files/rbackup.sh set -eu ## Logging functions function prepare_date() { date "$@" } function log() { if [ -n "${LOG_FILE}" ]; then echo "$(prepare_date +%F_%H:%M:%S): ${*}" >> "${LOG_FILE}" else echo "$(p...
<reponame>bmyte/runelite import net.runelite.mapping.ObfuscatedName; @ObfuscatedName("gp") public interface class194 extends Iterable { }
#!/bin/bash dieharder -d 201 -g 7 -S 588971838
#!/usr/bin/env sh set -e #set -x MIRROR=https://github.com/linkerd/linkerd2/releases/download dl() { local branch=$1 local ver=$2 local os=$3 local suffix=${4:-} local url=$MIRROR/${branch}-${ver}/linkerd2-cli-$branch-$ver-$os$suffix.sha256 printf " # %s\n" $url printf " %s: sha25...