anonymous No title
No License Python
2020年09月14日
Copy
import notification
import clipboard
import keyboard
import datetime
import tweepy
import json
import time
import glob
import base64
import calendar
import os
import sys
import re

"""
made by @Eevee_xx_

"""
consumerkey = "cCCen2etdT0a1bDAUf5WVUj6T"
consumersecret = "uNp6N6FGnYGvw5Ywy0s5utLWioCyz9NWoGkmDRxjXA99aU5Bd8"
accesstoken = "1286668057536942081-fkjPXybeIMDCO2WU2qkNFqGm0HNJlM"
accesstokensecret = "fFHHBmJgB9uj57BhSo76YS0qOXpe5P78lhs5zjht3xyy3"

# ルーム番号
roomid = "0000" 
# パスツイ分
passtime = "00"












username = clipboard.get()
password = ""


font_item = ["⓪①②③④⑤⑥⑦⑧⑨",
             "⓿❶❷❸❹❺❻❼❽❾",
             "0123456789",
             "𝟘𝟙𝟚𝟛𝟜𝟝𝟞𝟟𝟠𝟡",]

basenumber = "0123456789"

def tweet_filter(Tweettext):
	for i in range(10):
		if(font_item[0][i] in Tweettext):
			Tweettext = Tweettext.replace(font_item[0][i],basenumber[i])
		for j in range(10):
			if(font_item[1][j] in Tweettext):
				Tweettext = Tweettext.replace(font_item[1][j],basenumber[j])
			for k in range(10):
				if(font_item[2][k] in Tweettext):
					Tweettext = Tweettext.replace(font_item[2][k],basenumber[k])
				for l in range(10):
					if(font_item[3][l] in Tweettext):
						Tweettext = Tweettext.replace(font_item[3][l],basenumber[l])
	return Tweettext
	

def tweet_trim(tweet):
	tweet = tweet_filter(tweet)
	itemlist = ["@[a-zA-Z0-9_]+","[0-9]{1,2}:[0-5][0-9]","[0-9]{1,2}時[0-59]分","([0-9]|[0-2][0-9])時","[0-5][0-9]分","[1-9]{1,2}/[0-9]{1,2}",]
	for i in itemlist:
		tweet = re.sub(i,"",tweet)	
	tweet = tweet.replace(" ","")
	tweet = tweet.replace(" ","")
	tweet = re.findall(r"\d+",tweet)
	return tweet


Auth = tweepy.OAuthHandler(consumerkey,consumersecret)
Auth.set_access_token(accesstoken,accesstokensecret)
Api = tweepy.API(Auth)

now   = datetime.datetime.now()
minute = now.minute

if("/" in str(username)):
	username = username.split("/")
	username = username[3].split("?")
	username = username[0]
else:
	print("パスツイ主のリンクをコピーしてください")
	sys.exit()

for i, status in enumerate(tweepy.Cursor(Api.user_timeline,id=username,tweet_mode="extended").items(1)):
	tweet = status.full_text
	tweettime = status.created_at
	
print(tweet)
		
tweet = tweet_trim(tweet)
tweettime = re.findall(r"\d+",str(tweettime))

count = len(tweet)

# Just パスツイ
if(passtime in tweettime):
	print("loading...")
else:
	print("もう一回タップ!")
	sys.exit()

if(len(tweet) == 0):
   print("パスワードが見つかりませんでした。")
   sys.exit()
if(roomid in tweet and len(tweet) >= 2):
	room_id_index = tweet.index(roomid)
	if(room_id_index == 0):
		password = str(tweet[1])
	elif(room_id_index == 1):
		password = str(tweet[0])
	elif(len(tweet) >= 1):
		password = str(tweet[0])
else:
	password = tweet[0]

if(password == ""):
	print("対応していない形式です。")
else:
	notification.schedule(password)
	keyboard.insert_text(password)
	keyboard.insert_text("\n")
	print("Password:"+password)
import notification
import clipboard
import keyboard
import datetime
import tweepy
import json
import time
import glob
import base64
import calendar
import os
import sys
import re

"""
made by @Eevee_xx_

"""
consumerkey = "cCCen2etdT0a1bDAUf5WVUj6T"
consumersecret = "uNp6N6FGnYGvw5Ywy0s5utLWioCyz9NWoGkmDRxjXA99aU5Bd8"
accesstoken = "1286668057536942081-fkjPXybeIMDCO2WU2qkNFqGm0HNJlM"
accesstokensecret = "fFHHBmJgB9uj57BhSo76YS0qOXpe5P78lhs5zjht3xyy3"

# ルーム番号
roomid = "0000" 
# パスツイ分
passtime = "00"












username = clipboard.get()
password = ""


font_item = ["⓪①②③④⑤⑥⑦⑧⑨",
             "⓿❶❷❸❹❺❻❼❽❾",
             "0123456789",
             "𝟘𝟙𝟚𝟛𝟜𝟝𝟞𝟟𝟠𝟡",]

basenumber = "0123456789"

def tweet_filter(Tweettext):
	for i in range(10):
		if(font_item[0][i] in Tweettext):
			Tweettext = Tweettext.replace(font_item[0][i],basenumber[i])
		for j in range(10):
			if(font_item[1][j] in Tweettext):
				Tweettext = Tweettext.replace(font_item[1][j],basenumber[j])
			for k in range(10):
				if(font_item[2][k] in Tweettext):
					Tweettext = Tweettext.replace(font_item[2][k],basenumber[k])
				for l in range(10):
					if(font_item[3][l] in Tweettext):
						Tweettext = Tweettext.replace(font_item[3][l],basenumber[l])
	return Tweettext
	

def tweet_trim(tweet):
	tweet = tweet_filter(tweet)
	itemlist = ["@[a-zA-Z0-9_]+","[0-9]{1,2}:[0-5][0-9]","[0-9]{1,2}時[0-59]分","([0-9]|[0-2][0-9])時","[0-5][0-9]分","[1-9]{1,2}/[0-9]{1,2}",]
	for i in itemlist:
		tweet = re.sub(i,"",tweet)	
	tweet = tweet.replace(" ","")
	tweet = tweet.replace(" ","")
	tweet = re.findall(r"\d+",tweet)
	return tweet


Auth = tweepy.OAuthHandler(consumerkey,consumersecret)
Auth.set_access_token(accesstoken,accesstokensecret)
Api = tweepy.API(Auth)

now   = datetime.datetime.now()
minute = now.minute

if("/" in str(username)):
	username = username.split("/")
	username = username[3].split("?")
	username = username[0]
else:
	print("パスツイ主のリンクをコピーしてください")
	sys.exit()

for i, status in enumerate(tweepy.Cursor(Api.user_timeline,id=username,tweet_mode="extended").items(1)):
	tweet = status.full_text
	tweettime = status.created_at
	
print(tweet)
		
tweet = tweet_trim(tweet)
tweettime = re.findall(r"\d+",str(tweettime))

count = len(tweet)

# Just パスツイ
if(passtime in tweettime):
	print("loading...")
else:
	print("もう一回タップ!")
	sys.exit()

if(len(tweet) == 0):
   print("パスワードが見つかりませんでした。")
   sys.exit()
if(roomid in tweet and len(tweet) >= 2):
	room_id_index = tweet.index(roomid)
	if(room_id_index == 0):
		password = str(tweet[1])
	elif(room_id_index == 1):
		password = str(tweet[0])
	elif(len(tweet) >= 1):
		password = str(tweet[0])
else:
	password = tweet[0]

if(password == ""):
	print("対応していない形式です。")
else:
	notification.schedule(password)
	keyboard.insert_text(password)
	keyboard.insert_text("\n")
	print("Password:"+password)

Output

    
Run
No one still commented. Please first comment.