Skip to content

Instantly share code, notes, and snippets.

View kraptor's full-sized avatar
🏠
Working from home

kraptor kraptor

🏠
Working from home
View GitHub Profile
@gasman
gasman / pnginator.rb
Created April 30, 2012 18:08
pnginator: pack Javascript into a self-extracting PNG
#!/usr/bin/env ruby -w
# pnginator.rb: pack a .js file into a PNG image with an HTML payload;
# when saved with an .html extension and opened in a browser, the HTML extracts and executes
# the javascript.
# Usage: ruby pnginator.rb input.js output.png.html
# By Gasman <http://matt.west.co.tt/>
# from an original idea by Daeken: http://daeken.com/superpacking-js-demos
@jbmohler
jbmohler / selmodel.py
Created September 16, 2014 11:18
QItemSelectionModel crash
from PySide import QtCore, QtGui
class MyWindow(QtGui.QDialog):
def __init__(self, parent=None):
super(MyWindow, self).__init__(parent)
self.model = QtGui.QStringListModel(['sam', 'sally', 'jack'], self)
self.v = QtGui.QListView()
self.v.setModel(self.model)
@aitormagan
aitormagan / movistar_tv_channel_retriever.py
Created February 25, 2015 22:58
Script to retrieve the streaming URLs of Movistar TV channels
import requests
# Basic Variables
MIN_RANGE = 22000
MAX_RANGE = 40000
BASE_URL = 'http://B%d.cdn.telefonica.com/%d/%s_SUB.m3u8'
CHANNELS_IDS = ['NICK', 'DSNJR', '40TV', 'DSNYXD', 'COCINA', '24HORAS', 'INVITADO', 'FOX',
'AXN', 'CLL13', 'TNT', 'FOXCRIME', 'CSMO', 'AXNWHITE', 'PCMDY', 'SYFY', 'TCM',
'CPLUSLG', 'MOVFUTBOL', 'CPLUSCHP', 'NTLG', 'NATGEOWILD', 'CPLUS1']
@bkaradzic
bkaradzic / orthodoxc++.md
Last active November 17, 2024 00:54
Orthodox C++

Orthodox C++

What is Orthodox C++?

Orthodox C++ (sometimes referred as C+) is minimal subset of C++ that improves C, but avoids all unnecessary things from so called Modern C++. It's exactly opposite of what Modern C++ suppose to be.

Why not Modern C++?

@mmellison
mmellison / grpc_asyncio.py
Last active August 6, 2024 01:23
gRPC Servicer with Asyncio (Python 3.6+)
import asyncio
from concurrent import futures
import functools
import inspect
import threading
from grpc import _server
def _loop_mgr(loop: asyncio.AbstractEventLoop):
@dafthack
dafthack / azure_client_ids.txt
Created June 16, 2023 11:57
A collection of client IDs that can be used to authenticate a user, and their associated application name that shows up in Azure Sign-In logs.
00b41c95-dab0-4487-9791-b9d2c32c80f2 - Office 365 Management
04b07795-8ddb-461a-bbee-02f9e1bf7b46 - Microsoft Azure CLI
0ec893e0-5785-4de6-99da-4ed124e5296c - Office UWP PWA
18fbca16-2224-45f6-85b0-f7bf2b39b3f3 - Microsoft Docs
1950a258-227b-4e31-a9cf-717495945fc2 - Microsoft Azure PowerShell
1b3c667f-cde3-4090-b60b-3d2abd0117f0 - Windows Spotlight
1b730954-1685-4b74-9bfd-dac224a7b894 - Azure Active Directory PowerShell
1fec8e78-bce4-4aaf-ab1b-5451cc387264 - Microsoft Teams
22098786-6e16-43cc-a27d-191a01a1e3b5 - Microsoft To-Do client
268761a2-03f3-40df-8a8b-c3db24145b6b - Universal Store Native Client