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 random | |
import sys | |
import kivy | |
from kivy.app import App | |
from kivy.uix.boxlayout import BoxLayout | |
from kivy.uix.button import Button | |
from kivy.uix.label import Label | |
from kivy.uix.popup import Popup | |
class PigGame: |
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
#Simple List In Python Using Pyside6 GUI Library | |
import sys | |
import os | |
from PySide6.QtWidgets import QApplication, QWidget, QPushButton, QLineEdit, QListWidget, QMessageBox, QFileDialog, QMenu, QSystemTrayIcon | |
from PySide6.QtCore import Qt, QSize, QFile, QTextStream | |
from PySide6.QtGui import QPixmap, QIcon | |
import myResources | |
class PyListApp(QWidget): |
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
#!/usr/bin/env python | |
import subprocess | |
import json | |
def ex(cmd): | |
return subprocess.getoutput(cmd) | |
engineList = ex('ibus read-config | grep preload-engines | sed "s/preload-engines://g; s/\'/\\"/g"') | |
engineList = json.loads(engineList) |
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
#!/bin/bash | |
#yakuake wayland focus fix | |
#Copy The Global Yakuake Config To Local | |
cp /usr/share/applications/org.kde.yakuake.desktop ~/.local/share/applications/ | |
#Make Needed Adjustments To The Config | |
sed -i -e "s/'Exec=yakuake'/'Exec=env QT_QPA_PLATFORM=xcb yakuake'/g" ~/.local/share/applications/org.kde.yakuake.desktop | |
#DONE! | |
echo -e "\e[35mYakuake Focus Should Now Be Working Under Wayland!\e[0m" | |
#May Or May Not Be Needed Afterwards? |
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
SteamOS MODS: | |
#Increase To 2GB Memory Limit: | |
cat << EOF | sudo tee /etc/security/limits.d/memlock.conf | |
* hard memlock 2147484 | |
* soft memlock 2147484 | |
EOF | |
#Revert To Default Memory Limit: |
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
'User Unfriendly StartUp Script | |
function shutdown() | |
Dim objShell | |
Set objShell = WScript.CreateObject("WScript.Shell") | |
'objShell.Run "cmd /c shutdown -s -t 90" | |
wscript.sleep 6000 | |
objShell.Run "cmd /c shutdown -s -t 00" | |
end function | |
Dim msg, sapi |
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
#Scrape quotes using requests and BeautifulSoup4 | |
import requests | |
from bs4 import BeautifulSoup | |
urls = ["http://qoutes.toscrape.com", "http://quotes.toscrape.com/tag/love/", "http://quotes.toscrape.com/tag/inspirational/", "http://quotes.toscrape.com/tag/humor/"] | |
for page in urls: | |
html = requests.get(page) | |
soup = BeautifulSoup(html.text, "html.parser") | |
quotes = soup.find_all("span",class_="text") |
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 random | |
import sys | |
class PigGame: | |
MAX_SCORE = 100 | |
scores = [0, 0] | |
@staticmethod | |
def roll(): |
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
#!/bin/bash | |
#This Script Will Prompt For An AutoRemote Message To Send | |
#Usage: | |
#./AutoRemote-Message MESSAGE_TO_SEND | |
#Don't Forget To Modify These Values To Match Your Device | |
PASSWORD="YOUR_DEVICE_PASSWORD" | |
KEY="YOUR_DEVICE_KEY" |
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
#!/bin/bash | |
#This Script Will Prompt For An AutoRemote Message To Send | |
#Usage: | |
#./AutoRemoteMessage | |
#Don't Forget To Edit These Values To Match Your Device | |
PASSWORD="YOUR_DEVICE_PASSOWRD" | |
KEY="YOUR_DEVICE_KEY" |
NewerOlder