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
| global recents | |
| recents = dict() | |
| def recent(nick): | |
| global recents | |
| recents[nick] = time() | |
| on_recents = list() | |
| for key in recents.keys(): | |
| if recents[key] < time() - 1800: | |
| del recents[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
| #!/usr/bin/env python3 | |
| #Deleting of incoming and outdated SQL backups - Using with crontab | |
| import os, re | |
| d_list = sorted( #Filenames containing unix-timestamp, sorted() will set 'd_list' ordered, from old to new | |
| re.findall(r'\w+\.sql\.gz', #searching for filenames | |
| ','.join(os.listdir('/home/kirika')))) #Listing all files in directory and putting them comma-seperated together | |
| for i in range(len(d_list)-4): #Count of found files -4 | |
| os.remove(d_list[i]) #the newest 4 files wont be deleted |
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 | |
| """Yama's A.T.S.P.-Bot for IRC-Tasks""" | |
| import irc.bot | |
| import irc.strings | |
| import re | |
| import logging | |
| from threading import Timer | |
| from irc.client import ip_numstr_to_quad, ip_quad_to_numstr | |
| irc.client.ServerConnection.buffer_class.errors = 'ignore' |
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
| rxvt.background: #000000 | |
| rxvt.foreground: #D3D2D3 | |
| rxvt.color0: #000000 | |
| rxvt.color1: #FF7768 | |
| rxvt.color2: #ABFA68 | |
| rxvt.color3: #FFFD88 | |
| rxvt.color4: #98D0FE | |
| rxvt.color5: #FF85FD | |
| rxvt.color6: #CACBFE | |
| rxvt.color7: #EFEFEF |