This file contains hidden or 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
# /// script | |
# requires-python = "==3.12.8" | |
# dependencies = [ | |
# "opencv-python", | |
# "numpy", | |
# "ultralytics", | |
# "aiohttp", | |
# "aiofiles", | |
# "python-dotenv" | |
# ] |
This file contains hidden or 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 pickle | |
from collections import namedtuple | |
from datetime import datetime, timezone | |
import os.path | |
import pydle | |
import requests | |
from telegram import ParseMode | |
from telegram.ext import (Defaults, Updater) |
This file contains hidden or 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 json | |
import os | |
from datetime import datetime | |
from shutil import copyfile | |
json_files = [json_file for json_file in os.listdir( | |
'.') if json_file.endswith('json')] | |
for each_file in json_files: | |
with open(each_file) as json_file: |
This file contains hidden or 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
# Command provided: | |
# walnut convert dump.json --graft "/path/to/readout-stfb.yaml:readout-stfb.host-{{ it }}" --workflow-name grafted | |
name: grafted | |
defaults: | |
roc_ctp_emulator_enabled: "true" | |
stfb_enabled: "true" | |
roles: | |
- name: host-{{ it }} | |
for: |
This file contains hidden or 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 requests, bs4, sys | |
# remove spacing, adding lowercase to match Azlyrics url format | |
artist=input("artist: ").replace(" ","") | |
song=input("song: ").replace(" ","") | |
# url format: www.azlyrics.com/lyrics/<artist>/<song>.html | |
url='http://www.azlyrics.com/lyrics/%s/%s.html' % (artist,song) | |
This file contains hidden or 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 numpy as np | |
import random | |
def buildMaze (n): | |
emptyMaze = [[0 for x in range(n)] for y in range(n)] | |
for i in range(int(n/1.15)): | |
col = random.randrange(0, n, 1) | |
for j in range(int(n/1.15)): | |
row = random.randrange(0, n, 1) | |
if emptyMaze[col][row] == 0: |
This file contains hidden or 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
TIMEOUT 30 | |
filebot -script fn:amc --def music=n --conflict auto --def subtitles=en --def artwork=y --def extras=y --def gmail=your_gmail_id:your_gmail_password --def reportError=y --def clean=y --def movieFormat="Path_to_your_movies_folder/{n} ({y})/{n} ({y})" seriesFormat="Path_to_your_TV_folder/{n}/Season {s}/{n} - {s00e00} - {t}" --action move -non-strict "Path_where_downloads_are_kept" | |
pause |