This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name scriptflem_getInfo | |
// @namespace Violentmonkey Scripts | |
// @version 1.0.0 | |
// @match | |
// @downloadURL | |
// @updateURL | |
// @homepageURL | |
// @grant GM_setClipboard | |
// @grant GM_notification |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from re import A | |
import subprocess | |
import os | |
import time | |
import logging | |
import sys | |
from shutil import copyfile | |
from pathlib import Path | |
from pydantic import FilePath |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python3 | |
from datetime import datetime, time | |
from time import sleep | |
from requests import exceptions | |
import pymodbus | |
import serial | |
import math |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import asyncio | |
import httpx | |
async def async_client(): | |
async with httpx.AsyncClient() as client: | |
async with client.stream('GET', 'http://127.0.0.1:5000/large.csv') as response: | |
async for chunk in response.aiter_text(): | |
print(chunk) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
updateGame = function(delta) { | |
/* to update the location of the game, we're going to simulate it's position at | |
every millisecond since the last update. */ | |
for (var i = 0; i < delta && state == updateGame; ++i) { | |
// move the ball | |
ball.advance(); | |
// check to see what happened to the ball | |
if (!ball.bounced(p1, p2, PLAY_HEIGHT - LINE_WIDTH)) { | |
var scoringPlayer = null; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import asyncio | |
import json | |
import random | |
import websockets | |
from time import sleep | |
async def consumer(message): | |
if json.loads(message)['next'] == '0': | |
sleep(15) # Do what you want |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from pysnmp.hlapi import * | |
# credential is like CommunityData('public') (for v2) | |
# target is a IP | |
# then simply do : | |
# s = snmpy('demo.snmplabs.com', CommunityData('public')) | |
# o = s.get_Tree(['1.3.6.1.2.1.2.2.1.2']) | |
# v = s.get(['1.3.6.1.2.1.2.2.1.2.2']) | |
# print(v) | |
# for a in o: | |
# print(a) |