text
stringlengths
1
1.05M
#ifndef INCLUDED_NETWORK_FLAG_STATE_CHANGED_H #define INCLUDED_NETWORK_FLAG_STATE_CHANGED_H #include "network/message.h" #include "network/message_handler_sub_system.h" #include "network/message_sender_system.h" #include "core/flag_state_changed_event.h" #include "core/ctf_program_state.h" #include "platform/export.h"...
<filename>workspaces/ui-v2/src/hooks/useGroupedEndpoints.ts import { useMemo } from 'react'; import groupBy from 'lodash.groupby'; import { IEndpoint } from '<src>/types'; import { findLongestCommonPath } from '<src>/utils'; export const useGroupedEndpoints = <T extends IEndpoint>(endpoints: T[]) => { return useMem...
package com.github.nenomm.ks.ktable; import org.apache.kafka.streams.kstream.KTable; import org.springframework.cloud.stream.annotation.Input; public interface KTableCustomInput { String INPUT = "kTableCustomInput"; @Input(INPUT) KTable<?, ?> ingestSomethn(); }
package pt.isel.pdm.li51n.g4.tmdbisel.data.models.TMDB; import android.os.Parcel; import android.os.Parcelable; import com.google.gson.annotations.Expose; import com.google.gson.annotations.SerializedName; public class MovieCollection implements Parcelable{ /** * */ public static final Creator<Movi...
import * as path from "path"; import * as dotenv from "dotenv"; import {inject, singleton} from "../di"; import { ICascDirProvider, ICascDirProviderToken, IEnvProvider, IEnvProviderToken, } from "../interfaces"; @singleton(IEnvProviderToken) export class EnvProvider implements IEnvProvider { public constru...
package com.example.android.githubrepolist.database; import android.content.Context; import android.database.sqlite.SQLiteDatabase; import android.database.sqlite.SQLiteOpenHelper; public class DatabaseOpenHelper extends SQLiteOpenHelper { /** * There will be a singleton instance of {@link DatabaseOpenHelper} */...
<gh_stars>1-10 import { OutputAsset, OutputChunk } from 'rollup'; type SimpleObject = Record<string, string | number>; type MakeAttributes = (file: OutputAsset | OutputChunk) => string; type Files = Array<OutputAsset | OutputChunk> | undefined; interface AssetsOptions { publicPath?: string attrs?: SimpleObject | ...
/* Visit occurrence table. For every record in the patient registry, create a visit occurrence. Indatum empty for some dag_kiru rows. Use 01-01-1900 as default value. Unique visit identifier (visit_id) stored in the long tables. */ INSERT INTO visit_occurrence (visit_occurrence_id, person_id, visit_st...
/** * Copyright (C) 2006-2021 Talend Inc. - www.talend.com * * 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 appli...
<reponame>raptorhere/neuropod # https://docs.bazel.build/versions/master/skylark/repository_rules.html def _impl(repository_ctx): # The `or` pattern below handles empty strings and unset env variables # Using a default value only handles unset env variables version = repository_ctx.os.environ.get("NEUROPOD_...
macro_rules! assert_custom { ($body:expr, $expected:expr) => { if $body != $expected { panic!("Assertion failed: `{}` is not equal to {}", stringify!($body), stringify!($expected)); } }; } mod shared { pub mod api { pub const FORBIDDEN: &str = "FORBIDDEN"; } } fn ma...
package net.community.apps.tools.svn.wc.state; import java.util.Collection; import java.util.List; import net.community.chest.svnkit.core.wc.SVNLocalCopyData; import org.tmatesoft.svn.core.wc.SVNClientManager; /** * <P>Copyright 2009 as per GPLv2</P> * * <P>Base class helper for {@link StateChecker}-s implementa...
<filename>inc/hwy/base.h // Copyright 2020 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 applic...
<filename>ui/src/main/java/org/moskito/control/ui/resource/accumulators/AccumulatorChartsListResponse.java package org.moskito.control.ui.resource.accumulators; import org.moskito.control.ui.bean.ChartBean; import org.moskito.control.ui.resource.ControlReplyObject; import javax.xml.bind.annotation.XmlElement; import ...
import { Injectable, Input } from '@angular/core'; @Injectable({ providedIn: 'root' }) export class ArrayService { @Input() list: number[]; smallestElement(): number { let min = this.list[0]; for (let i=1; i<this.list.length; i++){ if (this.list[i] < min){ min = this.list[i]; } } return min...
#!/usr/bin/env bash chmod u+x ./workernode/target/pack/bin/worker-node ./workernode/target/pack/bin/worker-node worker.conf
<filename>src/android/UltraUnionpay.java package com.ott.cordova.plugin; import android.content.Intent; import org.apache.cordova.CordovaPlugin; import org.apache.cordova.CallbackContext; import org.apache.cordova.LOG; import org.apache.cordova.PluginResult; import org.json.JSONArray; import org.json.JSONException; imp...
<reponame>eitrtechnologies/idem_provider_azurerm # -*- coding: utf-8 -*- """ Azure Resource Manager (ARM) Compute Proximity Placement Group State Module .. versionadded:: 4.0.0 :maintainer: <<EMAIL>> :configuration: This module requires Azure Resource Manager credentials to be passed via acct. Note that the authe...
# wget -qO- https://raw.github.com/progrium/dokku/v0.2.3/bootstrap.sh | sudo DOKKU_TAG=v0.2.3 bash VERSION=$(lsb_release -sr) OLD_VERSION="12.04" if [ "$VERSION" == "$OLD_VERSION" ]; then # required for 12.04 sudo apt-get install -y python-software-properties else # required workaround for bug on 14.04 wget -q...
#!/usr/bin/env bash # Copyright (c) 2015-present, Facebook, Inc. # # This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. function print_help { echo "Usage: ${0} [OPTIONS]" echo "" echo "OPTIONS:" echo " --node-version <version> the node ve...
import json from os import walk, makedirs from os.path import exists, join, basename from shutil import copyfile from collections import defaultdict from argparse import ArgumentParser from lxml import etree from tqdm import tqdm NUM_CLASSES = 12 VIDEO_FILE_EXTENSIONS = 'webm' XML_FRAGMENT_TEMPLATE = '<annotations>\...
package documentdb // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. See License.txt in the project root for license information. // // Code generated by Microsoft (R) AutoRest Code Generator. // Changes may cause incorrect behavior and will be lost if the code is regenera...
<filename>openshift/ftest-oc-proxy/src/test/java/org/arquillian/cube/openshift/ftest/HelloWorldIT.java package org.arquillian.cube.openshift.ftest; import java.net.URISyntaxException; import java.net.URL; import java.util.List; import org.arquillian.cube.kubernetes.impl.utils.CommandExecutor; import org.arquillian.cub...
function changeButtonAppearance() { const submitBtn = document.getElementById('submitBtn'); submitBtn.addEventListener('click', function() { submitBtn.classList.remove('btn-success'); submitBtn.classList.add('btn-danger'); submitBtn.textContent = 'Submitted'; }); } changeButtonAppearance();
private void checkLocalSlot3(string slot) { try { string filePath = @".modmanager/mods/local/" + slot + "/package.txt"; if (System.IO.File.Exists(filePath)) { string slotPackage = System.IO.File.ReadAllText(filePath); if (slotPackage.Trim() =...
# >>> conda initialize >>> # !! Contents within this block are managed by 'conda init' !! __conda_setup="$('/opt/conda/bin/conda' 'shell.bash' 'hook' 2> /dev/null)" if [ $? -eq 0 ]; then eval "$__conda_setup" else if [ -f "/opt/conda/etc/profile.d/conda.sh" ]; then . "/opt/conda/etc/profile.d/conda.sh" ...
package org.xtwy.netty.constants; public class CommonConstant { public final static String ATTRIBUTE_KEY="Attribute_key"; }
<reponame>Modelata/fire import 'reflect-metadata'; /** * Sets userCollectionPath attribute of the targetted AuthDAO * * @param path user collection path */ export function UsersCollectionPath(path: string): any { // eslint-disable-next-line @typescript-eslint/ban-types return (target: Object) => { Reflect....
<gh_stars>0 package wordcount; import java.io.DataInput; import java.io.DataOutput; import java.io.IOException; import java.util.Arrays; import java.util.LinkedList; import java.util.List; import org.apache.hadoop.io.Writable; public class BroadcastValue implements Writable { /** * The keys which are "encoded" i...
import sys import random import math class Node: def __init__(self, val=0, next=None): self.val = val self.next = next class slist: """ singly linked list class """ def __init__(self): self._first = None self._last = None def build_slist_from_list(self, a): ...
#!/bin/sh kill -9 `ps -ef | grep /bms | grep -v 'grep' | awk '{print $2}'` exit
#!/bin/bash missing_vars=( ) [ -z "$PUBLIC_URL" ] && missing_vars+=( "PUBLIC_URL" ) [ -z "$GOOGLE_ANALYTICS_ID" ] && missing_vars+=( "GOOGLE_ANALYTICS_ID" ) [ -z "$AMPLITUDE_KEY" ] && missing_vars+=( "AMPLITUDE_KEY" ) if [ ${#missing_vars[@]} -gt 0 ]; then echo "Missing environment variables: ${missing_vars[*]}" ...
<reponame>ivarbanas/example $(document).ready(function() { $('#search_box').click(function(e) { var $region = $('#' + $(this).attr('aria-controls')); $region.slideToggle(100, function() { if ($region.attr('aria-expanded') == 'false') { $region.attr('aria-expanded', 'true'); $region.focu...
import datetime class Guest: def __init__(self, user, last_used): self.user = user self.last_used = last_used @classmethod def create_guest(cls, user): return cls(user=user, last_used=datetime.datetime.now()) # Example usage class User: def __init__(self, username): se...
#!/bin/sh # CYBERWATCH SAS - 2017 # # Security fix for CESA-2014:0866 # # Security announcement date: 2014-07-09 18:25:19 UTC # Script generation date: 2017-01-01 21:11:06 UTC # # Operating System: CentOS 6 # Architecture: x86_64 # # Vulnerable packages fix on version: # - libsmbclient.i686:3.6.9-169.el6_5 # - ...
#!/usr/bin/env bash # -----------private-------------------------- #sudo add-apt-repository -y ppa:danielrichter2007/grub-customizer #sudo add-apt-repository -y ppa:jtaylor/keepass #sudo add-apt-repository -y ppa:openshot.developers/ppa # Set time to use local-time so Ubuntu and windows can co-exists # https://www.ho...
<filename>src/main/java/frc/robot/autonomous/routines/test/Fender.java // Copyright (c) FIRST and other WPILib contributors. // Open Source Software; you can modify and/or share it under the terms of // the WPILib BSD license file in the root directory of this project. package frc.robot.autonomous.routines.test; impo...
class Usuario { constructor(nombre, edad, admin) { this.nombre = nombre; this.edad = edad; this.admin = admin; } } function authenticateUser(rut, pass, api_key) { if (api_key === "valid_api_key") { // Simulating user data retrieval from a database const usuario = new Usuario("John Doe", 25, f...
#!/bin/bash startDate=`date -d "2018-06-01 10:00"` weeks=12 judgeId=584a3ac1-690e-41b5-913f-b51cca824a45 roomId=74cc0d1e-0e1e-4f6e-9ae6-7fd9d223fb81 echo "1 DAY" curl -o /dev/null -s -w '%{time_total} :%{http_code} %{url_effective}\n' "http://localhost:8091/search?from=2018-06-25%2010:00&to=2018-06-25%2012:00&duration...
<reponame>pskopek/elytron-subsystem /* * JBoss, Home of Professional Open Source. * Copyright 2017 Red Hat, Inc., and individual contributors * as indicated by the @author tags. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. ...
// Copyright 2016 <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 to in writi...
<reponame>lutzer/mazi-board<filename>src/node/database/database.js 'use strict'; /* * @Author: <NAME>, Design Research Lab, Universität der Künste Berlin * @Date: 2016-05-04 12:55:03 * @Last Modified by: lutzer * @Last Modified time: 2016-05-04 17:41:19 */ var mongoose = require('mongoose'); var Utils = r_requir...
package main import "fmt" func diff(original, new string) { o, n := loadSQL(original, new) do := parseSQL(o, "original") dn := parseSQL(n, "new") // Start with the original, look for changed fields and keys for h, t := range do.Tables { // Go through the fields for i, f := range t.Fields { // Find in t...
#!/bin/bash # Init source "$(dirname $(readlink -f $0))/lib_update.bash" clone "vim" --github "vim/vim" --ver "master" $@ # Build ./configure --with-features=huge --enable-multibyte --enable-rubyinterp \ --enable-largefile --enable-pythoninterp --with-x \ --with-python-config-dir="${LOCAL_PREFIX}/lib/python2.7...
#!/bin/sh # function3.sh . ./common.lib echo $STD_MSG rename .html .html-bak
#!/bin/bash # This script generates release zips into _output/releases. It requires the openshift/origin-release # image to be built prior to executing this command via hack/build-base-images.sh. # NOTE: only committed code is built. set -o errexit set -o nounset set -o pipefail OS_ROOT=$(dirname "${BASH_SOURCE}"...
def filter_list(list): even_list = [] odd_list = [] for number in list: if number % 2 == 0: even_list.append(number) else: odd_list.append(number) return even_list,odd_list even,odd = filter_list([12,4,5,8,10,22]) print("Even numbers list :",even) print("Odd numbers list :",od...
<reponame>Rachel4858/Algorithm function findHappyNumber(n, set) { // 19 let numArray = n.toString().split(''); //['1', '9'] let sum = 0; for (let i = 0; i < numArray.length; ++i) { sum += numArray[i] * numArray[i]; } if (sum === 1) return true; else { if (set.has(sum)) { ...
<filename>src/com/idylwood/utils/OptimizationUtils.java /* * ==================================================== * Copyright (C) 2013 by Idylwood Technologies, LLC. All rights reserved. * * Developed at Idylwood Technologies, LLC. * Permission to use, copy, modify, and distribute this * software is freely grante...
(function(Models, Types) { "use strict"; // Constructor var FindClose2Request = function() { this.types_ = new Types(); this.searchId_ = null; }; // Public functions FindClose2Request.prototype.setSearchId = function(searchId) { this.searchId_ = searchId; }; ...
<filename>src/sentry/static/sentry/app/components/alert.tsx import {css} from '@emotion/core'; import PropTypes from 'prop-types'; import React from 'react'; import classNames from 'classnames'; import styled from '@emotion/styled'; import InlineSvg from 'app/components/inlineSvg'; import space from 'app/styles/space'...
pkill -f movies
def getans(n): S=set() for i in range(n): k=raw_input() if k in S: print "YES" else: print "NO" S.add(k) getans(int(raw_input()))
class Person: def __init__(self, name, age): self.name = name self.age = age def getInformation(self): return "Name: "+ self.name + ", Age: " + str(self.age) person = Person("John", 19) print(person.getInformation())
<reponame>FunMusicalIdeas/zdaubyaos // tslint:disable no-reaching-imports export { applyIntensityScalar } from './applyIntensityScalar' export { applyPitchIndexShift } from './applyPitchIndexShift' export { computeNote } from '../features'
/******************************************************************************* * Copyright 2019 <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.apac...
<reponame>sthagen/aquasecurity-trivy<filename>pkg/scanner/local/mock_applier.go // Code generated by mockery v1.0.0. DO NOT EDIT. package local import ( types "github.com/aquasecurity/trivy/pkg/fanal/types" mock "github.com/stretchr/testify/mock" ) // MockApplier is an autogenerated mock type for the Applier type ...
<filename>src/screens/Home/components/Section/index.js import React, { PureComponent } from 'react'; import PropTypes from 'prop-types'; import { View } from 'react-native'; import { TextInput, Text } from 'react-native-paper'; import Picker from './components/Picker'; import styles from './styles'; class Section exte...
// // JWPerformanceTestViewController.h // IconFont // // Created by <NAME> on 10/10/14. // Copyright (c) 2014 Taodiandian. All rights reserved. // #import <UIKit/UIKit.h> @interface JWPerformanceTestViewController : UIViewController @end
const _ = require('lodash'); const chai = require('chai'); const { expect } = chai; chai.use(require('chai-as-promised')); const errors = require('balena-errors'); const { getRequest } = require('balena-request'); const mockServer = require('mockttp').getLocal(); const request = getRequest({}); const register = requir...
#!/opt/tigersh-deps-0.1/bin/bash # based on templates/build-from-source.sh v6 # Install ncurses / ncursesw on OS X Tiger / PowerPC. # Note: this file builds both the ncurses and ncursesw packages. if test -n "$(echo $0 | grep 'ncursesw')" ; then package=ncursesw else package=ncurses fi version=6.3 upstream=h...
#!/usr/bin/env bash # Copyright 2019 The Go Cloud Development Kit 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 # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless requir...
const express = require('express'); const router = express.Router(); const userModel = require('../models/userModel'); // Route to Handle User Registration router.post("/register", (req, res)=>{ let {name, email, password} = req.body; userModel.create({name, email, password}) .then(user=>{ res.json({status:user....
const MongoClient = require("mongodb").MongoClient; const mongoUrl = "mongodb://tfb-database:27017"; const dbName = "hello_world"; let client; async function getCollection(name) { if (!client) { client = await MongoClient.connect( mongoUrl, { useNewUrlParser: true } ); } const db = client....
package DAO; import models.Ranger; import models.Sighting; import models.SightingEndangeredSpecies; import java.util.List; public interface RangerDAO { //List List<Ranger> getAllRangers(); void addRanger(Ranger ranger); Ranger getRangerById(int id); List<Sighting> getSightingsByRangerId(int id); ...
#pragma once #include <vector> #include <string> #include <Windows.h> #include "string_utils.h" std::vector<std::string> getFilesInDirectory(std::string folder) { using std::vector; using std::string; vector<string> names; string search_path = folder + "/*.*"; WIN32_FIND_DATA fd; HANDLE hFind = FindFirstFile(s...
# frozen_string_literal: true module Neo4j module Driver class AuthTokens class << self def basic(username, password) Internal::Validator.require_non_nil_credentials!(username, password) Bolt::Auth.basic(username, password, nil) end def none Bolt::Auth...
#!/bin/sh # Copyright (c) 2014-2015 The Bitcoin Core developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. if [ -z "$OSSLSIGNCODE" ]; then OSSLSIGNCODE=osslsigncode fi if [ ! -n "$1" ]; then echo "usage: $0 <osslcodesign...
// Basic functionality: // Comments // Starter // Call a method // Self-method // Nested method // Assignment export default ` title TTT 1 @Lambda <<A>> A // comments at the beginning should be ignored group "B C" {@EC2 B @ECS C} "C 2" "B 1" // This is comment // // |col1|col2| // |----|----| // |val1|val2| @Starter("U...
# Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. # SPDX-License-Identifier: MIT-0 set -e if [ -z $1 ] ; then echo "Please provide stack name for SAM template" exit 1 fi sam build -t ./template/template.yaml sam deploy --stack-name $1 --capabilities CAPABILITY_IAM --no-confirm-change...
<gh_stars>0 import React from "react"; import PropTypes from "prop-types"; import CsrfTokenInput from "../utils/authentication-utils"; import { toKeyValueArray } from "../utils/dictionary-utils"; import { restCreate } from "../api/rest-api-consumation"; import capitalizeFirstLetter from "../utils/string-utils"; export...
/* * Tencent is pleased to support the open source community by making 蓝鲸 available. * Copyright (C) 2017-2018 THL A29 Limited, a Tencent company. All rights reserved. * Licensed under the MIT License (the "License"); you may not use this file except * in compliance with the License. You may obtain a copy of the Li...
#!/bin/bash #SBATCH --job-name="rfm_IMB_Uniband__2_job" #SBATCH --ntasks=4 #SBATCH --ntasks-per-node=2 #SBATCH --output=rfm_IMB_Uniband__2_job.out #SBATCH --error=rfm_IMB_Uniband__2_job.err #SBATCH --time=0:10:0 #SBATCH --exclusive module load gcc/9.3.0-5abm3xg module load openmpi/4.0.3-qpsxmnc export SLURM_MPI_TYPE=pm...
#! /bin/bash #set -o xtrace set -o errexit set -o pipefail set -o nounset #------------------------------------------------------------------------------ # Helper functions #------------------------------------------------------------------------------ function log() { echo -e "\n+" "$@" } function get_latest_mac...
<reponame>iarthstar/purescript-sketch "use strict"; exports.copyToPasteboard = (str) => () => { const paste = NSPasteboard.generalPasteboard(); paste.clearContents(); paste.setString_forType(str, "public.utf8-plain-text"); return {}; };
// Algorithm to find the largest rectangular submatrix of 1's in a given binary matrix // Step 1: Create an auxiliary matrix to store the max size of the submatrix // Auxiliary matrix // 0 0 0 0 0 // 0 0 1 0 0 // 0 1 1 1 0 // 0 0 1 2 3 // 0 0 1 2 0 // Step 2: Iterate over the auxiliary matrix and find the maximal va...
<filename>client/admin/users/members/edit/blocks/hb/hb.js 'use strict'; // Make sure that hb field is always present in this form, // true => 'on', false => '' // // It's not there by default unless checked, and server won't change // any fields that aren't present in input. // N.wire.before('admin.users.members.edit...
def fx(nums): return sum(map(lambda x : x*x if x % 2==0 else 0, nums)) print(fx([3, 4, 5, 6, 7, 8, 9, 10])) # Output: 240
<gh_stars>1-10 /** * */ package coca.api; import java.io.IOException; import java.util.Arrays; import java.util.HashMap; import java.util.List; import java.util.Map; import org.junit.After; import org.junit.Assert; import org.junit.Before; import org.junit.Test; import org.slf4j.Logger; import org.slf4j.LoggerFact...
package com.flockinger.poppynotes.notesService.api; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import org.apache.commons.lang3.StringUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.http.HttpStatus; import org.springframe...
window.addEventListener('DOMContentLoaded', () => { const menu = document.querySelector('.menu'), menuItem = document.querySelectorAll('.menu_item'), hamburger = document.querySelector('.hamburger'); hamburger.addEventListener('click', () => { hamburger.classList.toggle('hamburger_active'); ...
"use strict"; /* global jQuery, includeLayout */ (function(root, factory) { if(typeof define === 'function' && define.amd) { define(function(require, exports, module) { require("common.css!"); require("ui/toolbar"); module.exports = factory( require("jq...
# -*- coding: utf-8 -*- # # S3XML Unit Tests # # To run this script use: # python web2py.py -S eden -M -R applications/eden/tests/unit_tests/modules/s3/s3xml.py # import unittest from gluon import * from gluon.contrib import simplejson as json try: from cStringIO import StringIO except: from StringIO import St...
import yaml def process_lidar_data(file_path): # Load the LiDAR sensor data from the provided YAML file lidarmsg = yaml.load(open(file_path, 'r'), Loader=yaml.FullLoader) # Print the list of range values ranges = lidarmsg['ranges'] print("Range values:", ranges) # Print the maximum range valu...
package topology_sort; import java.io.BufferedReader; import java.io.InputStreamReader; import java.util.*; /** * * @author exponential-e * 백준 9470번: Strahler 순서 * * @see https://www.acmicpc.net/problem/9470 * */ public class Boj9470 { private static final String NEW_LINE = "\n"; private static final ...
<filename>pkg/common/report/generate_report.go package report import ( "context" "fmt" "log" "regexp" "sort" "strings" "time" "github.com/openshift/osde2e/pkg/common/config" "github.com/openshift/osde2e/pkg/common/prometheus" "github.com/spf13/viper" v1 "github.com/prometheus/client_golang/api/prometheus/...
import React from 'react'; import { Divider, Layout as AntdLayout } from 'antd'; import CustomHeader from './Header'; const { Content } = AntdLayout; type ILayoutProps = { children: React.ReactNode; }; const Layout = ({ children }: ILayoutProps) => { return ( <AntdLayout style={{ minHeight: '100vh' }}> ...
import fpdf names=open("names.txt","r") x=names.read().split("\n") # print x for i in range(len(x)-2): name = x[i][:-1] filename=name+str(i) # print name pdffile = fpdf.FPDF() pdffile.compress = False pdffile.add_page(orientation = 'L') pdffile.add_font('boldfont','','bold4.otf',uni=True) pdffile.set_font('bold...
class CustomTile(BaseTile): def calculate_area(self): # Assuming DEFAULT_PROJECTIONS_BBOX is a tuple (min_longitude, min_latitude, max_longitude, max_latitude) min_longitude, min_latitude, max_longitude, max_latitude = DEFAULT_PROJECTIONS_BBOX width = max_longitude - min_longitude he...
package com.littlejenny.gulimall.ware.entity; import com.baomidou.mybatisplus.annotation.TableId; import com.baomidou.mybatisplus.annotation.TableName; import java.io.Serializable; import java.util.Date; import lombok.Data; /** * 库存工作单 * * @author littlejenny * @email <EMAIL> * @date 2021-07-16 17:35:23 */ @D...
#!/bin/sh # # Copyright 2019 PingCAP, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed t...
#!/bin/bash -eux mkdir /home/vagrant/.ssh chmod 700 /home/vagrant/.ssh cd /home/vagrant/.ssh wget --no-check-certificate 'https://raw.github.com/mitchellh/vagrant/master/keys/vagrant.pub' -O authorized_keys chmod 600 /home/vagrant/.ssh/authorized_keys chown -R vagrant /home/vagrant/.ssh # sudoers don't need password fo...
import { Injectable } from '@angular/core'; @Injectable({ providedIn: 'root', }) export class ConfigService { private menuOpen: boolean; constructor() { this.menuOpen = true; } toggleMenuOpen() { this.menuOpen = !this.menuOpen; } isMenuOpen() { return this.menuOpen; } }
/* eslint-disable no-undef */ // import globalStyles from './globalStyles.css'; // import buttonStyles from './buttonStyles.css'; <> {/* Hint: inspect the markup to see how the classes differ */} <ThemeProvider classNameMap={globalStyles}> <Button variant="primary">Blue Button</Button> </ThemeProvider>{' '} ...
// Test cases specifically for issue #180 import { Mesh, BufferGeometry, TorusBufferGeometry, Scene, Raycaster, MeshBasicMaterial } from 'three'; import { acceleratedRaycast, computeBoundsTree, disposeBoundsTree, SAH, AVERAGE } from '../src/index.js'; Mesh.prototype.raycast = acceleratedRaycast; BufferGeometry.prototy...
class Compound_Fetcher_Rhea: def __init__(self, compound_id, db='Rhea'): self.compound_id = compound_id self.db = db def get_all_info(self): print(f'Fetching all information for compound {self.compound_id} in {self.db}') # Implement code to retrieve and display all available inf...
#!/bin/bash sudo apt update sudo apt install -y --no-install-recommends gunicorn xvfb wget libnss3 libxss1 libappindicator1 libindicator7 libsdl1.2-dev fonts-liberation libappindicator3-1 libasound2 libatk-bridge2.0-0 libgtk-3-0 libnspr4 libnss3 libxtst6 lsb-release xdg-utils enchant cd /usr/bin sudo wget https://chro...
#!/bin/bash # # Мониторинг 1С Предприятия 8.3 (сервер лицензирования) # # (c) 2019-2020, Алексей Ю. Федотов # # Email: fedotov@kaminsoft.ru # source ${0%/*}/1c_common_module.sh 2>/dev/null || { echo "ОШИБКА: Не найден файл 1c_common_module.sh!" ; exit 1; } function licenses_summary { RING_TOOL=$(check_ring_licen...
if [ -z $1 ]; then echo "dataset name is not given" exit -1 fi dataset=$1 pickle_dir="tmp/${dataset}" extra=$2 # output_dir="/cs/home/hxiao/public_html/event_html/data/${dataset}" output_dir="html/data/${dataset}" remote_host="shell.cs.helsinki.fi" remote_dir="/cs/home/hxiao/public_html/event_html/data/${dataset}" ...
# ------------------------------------------------------------------------------------------------- # Copyright (c) 2015 zsh-syntax-highlighting contributors # All rights reserved. # # Redistribution and use in source and binary forms, with or without modification, are permitted # provided that the following conditions...