mirror of
https://github.com/MCV-Software/TWBlue.git
synced 2024-11-22 19:28:09 -06:00
ADded libraries for the new stable version.
This commit is contained in:
parent
67412125df
commit
f24c0955ce
@ -1,6 +1,6 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
name = 'TWBlue'
|
||||
snapshot = True
|
||||
snapshot = False
|
||||
if snapshot == False:
|
||||
version = "0.80"
|
||||
update_url = 'http://twblue.es/updates/twblue_ngen.json'
|
||||
|
@ -5,10 +5,17 @@ import exceptions
|
||||
from ctypes import c_char_p
|
||||
from libloader import load_library
|
||||
import paths
|
||||
if platform.architecture()[0][:2] == "32":
|
||||
lib = load_library("api_keys32", x86_path=paths.app_path("keys/lib"))
|
||||
if application.snapshot == True:
|
||||
if platform.architecture()[0][:2] == "32":
|
||||
lib = load_library("snapshot_api_keys32", x86_path=paths.app_path("keys/lib"))
|
||||
else:
|
||||
lib = load_library("snapshot_api_keys64", x64_path=paths.app_path("keys/lib"))
|
||||
else:
|
||||
lib = load_library("api_keys64", x64_path=paths.app_path("keys/lib"))
|
||||
if platform.architecture()[0][:2] == "32":
|
||||
lib = load_library("stable_api_keys32", x86_path=paths.app_path("keys/lib"))
|
||||
else:
|
||||
lib = load_library("stable_api_keys64", x64_path=paths.app_path("keys/lib"))
|
||||
|
||||
# import linuxKeys
|
||||
# lib = linuxKeys
|
||||
|
||||
|
BIN
src/keys/lib/stable_api_keys32.dll
Normal file
BIN
src/keys/lib/stable_api_keys32.dll
Normal file
Binary file not shown.
BIN
src/keys/lib/stable_api_keys64.dll
Normal file
BIN
src/keys/lib/stable_api_keys64.dll
Normal file
Binary file not shown.
@ -18,6 +18,7 @@
|
||||
############################################################
|
||||
import requests
|
||||
import keys
|
||||
import application
|
||||
from twitter import utils
|
||||
|
||||
def get_twishort_uri(url):
|
||||
@ -41,10 +42,14 @@ def get_full_text(uri):
|
||||
# return False
|
||||
|
||||
def create_tweet(user_token, user_secret, text, media=0):
|
||||
if application.snapshot == True:
|
||||
url = "http://twblue.es/snapshot_twishort.php"
|
||||
else:
|
||||
url = "http://twblue.es/stable_twishort.php"
|
||||
data = {"user_token": user_token,
|
||||
"user_secret": user_secret,
|
||||
"text": text.encode("utf-8"),
|
||||
"media": media}
|
||||
response = requests.post("http://twblue.es/twishort.php", data=data)
|
||||
response = requests.post(url, data=data)
|
||||
# print response.json()
|
||||
return response.json()["text_to_tweet"]
|
Loading…
Reference in New Issue
Block a user