Skip to content

Instantly share code, notes, and snippets.

Exodus111

Block or report user

Report or block Exodus111

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View main.kv
#: kivy 1.9.1
<Main>:
HUD:
size_hint: 1., 1.
pos: 0,0
<HUD>:
spacing: 10
Button:
View image_check.py
#!/usr/bin/python3
import kivy
kivy.require("1.9.0")
from kivy.app import App
from kivy.uix.widget import Widget
from kivy.uix.image import Image
from kivy.graphics import Rectangle
from kivy.clock import Clock
from kivy.properties import ObjectProperty
View line.kv
<Main>
size: 400, 400
canvas:
Rectangle:
pos: self.pos1
size: 30, 30
View line.kv
<Main>
size: 400, 400
canvas:
Line:
points: root.line1
width: 1.0
Rectangle:
pos: self.pos1
size: 30, 30
View atom_fix.py
import os
def set_dir(file_path):
here = os.path.dirname(file_path)
os.chdir(here)
if __name__ == "__main__":
set_dir(__file__)
View gist:0d1718e55a85d85ed131
import numpy as np
from PIL import Image, ImageDraw
from vec2d import vec2d
from random import randint as rai
class Poly(object):
"""This generates a polygon in a numpy Array"""
View main.py
from kivy.config import Config
xwidth, xheight = 1024, 960
Config.set("graphics", "width", xwidth)
Config.set("graphics", "height", xheight)
Config.write()
from kivy.app import App
from kivy.core.window import Window
View gist:0a806f4c1191f618a646
from bs4 import BeautifulSoup as bs
import requests
url = "en.wikipedia.org/wiki/List_of_X-Men_comics"
r = requests.get("http://" +url)
data = r.text
soup = bs(data)
text = soup.get_text()
View Wallpaper Cycler
#!/bin/bash
while [[ 1 -eq 1 ]]; do
for i in $(echo /usr/share/backgrounds/*.jpg); do
echo $i
gsettings set org.gnome.desktop.background picture-uri file:///${i}
sleep 60;
done
done
View gist:9747857
#!/bin/bash
uri=$1 #URI of RSS Feed
lines=$2 #Number of headlines
titlenum=$3 #Number of extra titles
#Script start
#Require a uri, as a minimum
if [[ "$uri" == "" ]]; then
echo "No URI specified, cannot continue!" >&2
You can’t perform that action at this time.