Skip to content

Instantly share code, notes, and snippets.

View kslr's full-sized avatar
🤒
I may be slow to respond.

Kslr kslr

🤒
I may be slow to respond.
  • Super Nebule LLC
  • 192.168.2.1
View GitHub Profile
@Brainiarc7
Brainiarc7 / ffmpeg-qsv-enabled-build-ubuntu-18.04lts-testbed.md
Last active July 14, 2024 13:29
This gist will generate an Intel QSV-enabled FFmpeg build using the open source Intel Media SDK. Testbed used: Ubuntu 18.04LTS. A fallback is also provided for the intel vaapi driver where needed.

Build FFmpeg with Intel's QSV enablement on an Intel-based validation test-bed:

Build platform: Ubuntu 18.04LTS

Ensure the platform is up to date:

sudo apt update && sudo apt -y upgrade && sudo apt -y dist-upgrade

Install baseline dependencies first (inclusive of OpenCL headers+)

@bftanase
bftanase / secure_link.php
Last active May 23, 2024 13:47
generate URL for nginx secure_link
@xavierskip
xavierskip / scan.py
Created June 3, 2014 16:45
scan the lan
#!/usr/bin/env python
#-*- coding:utf-8 -*-
import os, re, threading
addrs = {}
def bin8(n):
byte = "{0:08b}".format(n)
if len(byte)<8:
byte = '0'*(8-len(byte))+byte
@kaizhuQin
kaizhuQin / GetImageSrc.php
Last active July 26, 2016 04:07
php:获取字符串中 img src 的路径
<?php
/**
* 获取字符串中 img src 的路径
* @param array $out[4] 图片路径数组
*/
public function GetImageSrc($body)
{
if(!isset($body)){
return '';
}else{
@fpfeng
fpfeng / v2ex_auto_login.py
Last active June 10, 2023 16:54
登录 V2EX 领取每日奖励
# -*- coding: utf-8 -*-
from bs4 import BeautifulSoup
import requests
username = '' ###账号###
password = '' ###密码###
login_url = 'http://v2ex.com/signin' ###如V2EX设置了使用 SSL,必须改 https###
index_url = 'http://v2ex.com' ###同上###
mission_url = 'http://www.v2ex.com/mission/daily' ###同上###
UA = "Mozilla/5.0 (Windows NT 5.1) AppleWebKit/537.36 (KHTML, like Gecko) \
@jancborchardt
jancborchardt / Dealing with issues.md
Last active January 24, 2022 23:07
Dealing with issues

Dealing with issues

Try to reproduce issues

Go through the new issues and try to reproduce them. It’s important to get additional info, logs, and test if an issue occurs on different platforms. That helps us identify the source of the problem.

Triage issues

  • if there’s more info needed, ask the reporter to use the issue template
  • assign relevant labels
import requests
r = requests.get("http://httpbin.org/cookies/set?k1=v1&k2=v2")
print r.cookies
# you can get a dict that stores everything of the CookieJar object
cookies = r.cookies.get_dict()
r = requests.get("http://httpbin.org/cookies", cookies=cookies)
print r.content
@hakre
hakre / magnet-links-bittorrent.php
Created March 1, 2012 13:13
Magnet links library for PHP