Skip to content

Instantly share code, notes, and snippets.

Active Profiles:
Battery Power -1
AC Power -1*
Currently in use:
standbydelay 10800
standby 1
womp 0
halfdim 1
hibernatefile /var/vm/sleepimage
darkwakes 0
@gklka
gklka / gist:ffb06bc8e5e2066bf07c
Last active August 29, 2015 14:10
Kiírja a FUTÁR API-kat használva a Báthory utca megállóhelyről induló legközelebbi járatokat
import urllib2
import json
import datetime
def find_start_time(datas, identifier):
if datas.has_key('data'):
if datas['data'].has_key('entry'):
if datas['data']['entry'].has_key('stopTimes'):
for stopTime in datas['data']['entry']['stopTimes']:
if stopTime['tripId'] == identifier:
root@hitchcock:~# cat /etc/apt/sources.list
# deb cdrom:[Ubuntu 14.10 _Utopic Unicorn_ - Release amd64 (20141022.1)]/ utopic main restricted
# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.
deb http://hu.archive.ubuntu.com/ubuntu/ utopic main restricted
deb-src http://hu.archive.ubuntu.com/ubuntu/ utopic main restricted
## Major bug fix updates produced after the final release of the
## distribution.
@gklka
gklka / hosts
Last active March 7, 2022 16:28
/etc/hosts
##
# Host Database
#
# localhost is used to configure the loopback interface
# when the system is booting. Do not change this entry.
##
127.0.0.1 localhost
255.255.255.255 broadcasthost
::1 localhost
fe80::1%lo0 localhost
@gklka
gklka / safari_custom_stylesheet.css
Last active December 10, 2023 15:35
safari_custom_stylesheet.css
#hcdb {
display: none;
}
div.hird_120 {
display: none;
}
body.terkep {
padding-top: 0 !important;
/**
* Welcome to Pebble.js!
*
* This is where you write your app.
*/
var UI = require('ui');
var ajax = require('ajax');
var Vector2 = require('vector2');
@gklka
gklka / gist:4a37e89b4ef1b5f4657b
Created June 2, 2015 14:45
IP change detection and display in OS X Notification
from pync import Notifier
import urllib2
import time
ip = None
while True:
response = urllib2.urlopen('http://ip1.dynupdate.no-ip.com')
new_ip = response.read()
# print new_ip
//
// UIAlertAction+Extensions.m
//
// Created by GK on 15.09.17..
//
//
#import "UIAlertAction+Extensions.h"
@implementation UIAlertAction (Extensions)
#!/bin/sh
curl -X POST -u "user:pass" -H "Content-Type: application/json" --data "{\"alert\": \"Download complete: $TR_TORRENT_NAME\", \"url\": \"http://url-ami-forwardol-a-transmission-url-edre\"}" https://go.goroost.com/api/push
#!/bin/bash
for f
do
scp -P PORTOD $f USERED@HOSTOD:/mnt/disk2/Plex/Download/
if [ $? -eq 0 ]
then
mv $1 ~/.Trash/
/usr/local/bin/terminal-notifier -message "$f" -title "Successful upload" -open "http://TRANSMISSION-OD-URL-JE"
else