Skip to content

Instantly share code, notes, and snippets.

import urllib
import clipboard
import bs4
import console
link = clipboard.get()
console.show_activity()
soup = bs4.BeautifulSoup(urllib.urlopen(link))
import selenium
from selenium import webdriver
import time
URL = "http://edatai.us/blog/2012/11/20/placing-kpis-different-cron-schedules"
b = webdriver.Firefox()
b.get(URL)
for i in range(2, 806):
@mygeekdaddy
mygeekdaddy / stopTimer.py
Created July 26, 2014 02:35
stopTimer.py script for WorkLog workflow
# stopTimer.py - generates closure notes for Drafts action
# & removes the temporary 'timer.txt' file
# by: Jason Verly
# rev date: 2014-07-25
import time
import console
import os
import os.path
import webbrowser
import clipboard
@mygeekdaddy
mygeekdaddy / startTimer.py
Created July 26, 2014 02:54
startTimer.py script for WorkFlow process
# startTimer.py - writes epoch time to text file for work log
# by: Jason Verly
# rev date: 2014-07-25
import time
import console
import os
import os.path
import clipboard
import webbrowser
import urllib
@mygeekdaddy
mygeekdaddy / hdspace.js
Created August 10, 2014 18:20
Javascript widget for Übersicht to show available HD space
command: "df -Hl | grep 'disk1' | awk '{print $4\" used/\"$2 \" free (\"$5\" used )\"}'",
refreshFrequency: 60000000,
render: function (output) {
return "<div><h1>" + output + "</h1></div>";
},
style: " \n\
bottom: 300px \n\
@mygeekdaddy
mygeekdaddy / index.coffee
Created August 10, 2014 18:21
Coffeescript widget for Übersicht to monitor available HD space
command: "df -Hl | grep 'disk1' | awk '{print $4\" used/\"$2 \" free (\"$5\" used )\"}'"
refreshFrequency: 60000000
style: """
bottom: 350px
left: 15px
color: #fff
font-family: Helvetica Neue
@mygeekdaddy
mygeekdaddy / index.coffee
Created August 11, 2014 03:45
Übersicht widget to display your current IP address
command: "/Users/mygeekdaddy/Dropbox/bin/Python/curipaddr.py"
refreshFrequency: 6000000
style: """
bottom: 212px
left: 15px
color: #fff
font-family: Helvetica Neue
@mygeekdaddy
mygeekdaddy / curipaddr.py
Created August 11, 2014 03:46
Print current IP address of system
#!/usr/bin/python
import socket
fqdn = socket.getfqdn()
ip_addr = socket.gethostbyname(fqdn)
print ip_addr
@mygeekdaddy
mygeekdaddy / curipaddr.py
Created August 19, 2014 01:59
Python script to get current IP address
#!/usr/bin/env python
import sys, socket
def main():
try:
# fqdn = socket.getfqdn()
ip_addr = socket.gethostbyname(socket.getfqdn())
print ip_addr
return 0
@mygeekdaddy
mygeekdaddy / universal_image_merge.py
Created October 14, 2014 04:08
Pythonista script to merge two images together
# ** Universal iOS screenshot merge **
# Script will take two images of same orientation and merge them together.
#
# By: Jason Verly (@mygeekdaddy)
# Date: 2014-10-13
# Ver: 1.02
import clipboard
import Image
import console