Skip to content

Instantly share code, notes, and snippets.

View EnumCode's full-sized avatar
🎯
Focusing

EnumCode

🎯
Focusing
View GitHub Profile
@EnumCode
EnumCode / pyazo.py
Created August 17, 2018 13:24
pyazo client side
import wx
import pyautogui
import requests
import webbrowser
class MyApp(wx.App):
def __init__(self, parent=None):
wx.App.__init__(self, False)
self.frame = MyFrame(parent, -1, passBack=self)
@EnumCode
EnumCode / listener.py
Created August 17, 2018 13:21
listener that triggers the main program
import threading
import pyazo
import keyboard
wxTest.main()
lock=threading.Lock()
while True:
keyboard.wait('ctrl+shift+d')
lock.acquire()
pyazo.main()
lock.release()
@EnumCode
EnumCode / server.py
Created August 17, 2018 13:19
pyazo server side
from flask import Flask, request, redirect, url_for
import os
import random
import string
UPLOAD_FOLDER = '/var/www/html/uploads'
app = Flask(__name__)
app.config['UPLOAD_FOLDER'] = UPLOAD_FOLDER
ALLOWED_EXTENSIONS = set(['png', 'jpg', 'jpeg', 'gif'])
@EnumCode
EnumCode / default.txt
Created August 17, 2018 13:16
nginx config file
##
# You should look at the following URL's in order to grasp a solid understanding
# of Nginx configuration files in order to fully unleash the power of Nginx.
# http://wiki.nginx.org/Pitfalls
# http://wiki.nginx.org/QuickStart
# http://wiki.nginx.org/Configuration
#
# Generally, you will want to move this file somewhere, and start with a clean
# file but keep this around for reference. Or just disable in sites-enabled.
#