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 'dart:io'; | |
import 'package:flutter/material.dart'; | |
import 'package:path/path.dart' as Path; | |
import 'package:desktop_drop/desktop_drop.dart'; | |
import 'package:video_player_win/video_player_win.dart'; | |
// Simple video player with subtitle support (Flutter) | |
/* Using package |
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
# Example of getting a Tweets with Python. | |
# require 'python-twitter-v2' | |
# This hasn't worked since the Twitter API policy changed. Since roughly July 2023 | |
from pytwitter import Api | |
import sqlite3 | |
def createTableIfNotExist(con): | |
try: | |
sqlcmd = "CREATE TABLE IF NOT EXISTS data (id BIGINT UNSIGNED NOT NULL PRIMARY KEY UNIQUE, text TEXT)" |
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
# puzzled_image.py | |
# pip install pillow | |
import os | |
import sys | |
import random | |
from PIL import Image | |
from PIL import ImageOps | |
def puzzled_image(filepath, count_x, count_y,shuffle_count, invert=False): | |
filename = os.path.splitext(filepath)[0] |
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 paramiko | |
import re | |
import time | |
# reference sites | |
# * https://stackoverflow.com/questions/1911690/nested-ssh-session-with-paramiko | |
# * https://stackoverflow.com/questions/53707630/paramiko-how-to-detect-if-command-executed-using-invoke-shell-has-finished | |
# use paramiko library | |
class SSHConnect: |
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 json | |
import sys | |
import urllib3 | |
YOUTUBE_API_KEY = "" | |
http = urllib3.PoolManager() | |
def main(videoId): | |
api_url = "https://www.googleapis.com/youtube/v3/videos?part=statistics&id=%s&key=%s" % (videoId, YOUTUBE_API_KEY); |
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 urllib3 | |
import json | |
import sys | |
YOUTUBE_API_KEY = "" | |
http = urllib3.PoolManager() | |
# reference (참고사이트) | |
# https://stackoverflow.com/questions/18953499/youtube-api-to-fetch-all-videos-on-a-channel |