Skip to content

Instantly share code, notes, and snippets.

View jseanj's full-sized avatar
💭
I may be slow to respond.

Jseanj jseanj

💭
I may be slow to respond.
  • kwai
  • 中国 北京
View GitHub Profile
@jakebellacera
jakebellacera / how-to-get-youtube-video-id.md
Last active August 19, 2025 17:22
Learn how to get the ID of any YouTube video.

How to get the ID of any YouTube Video

This article walks you through how to get the ID of any YouTube video.

How to get a YouTube video ID from a youtube.com page URL

You may be watching the video or just happened to visit a link to a video. The video ID will be located in the URL of the video page, right after the v= URL parameter.

@bang590
bang590 / linkmap.js
Last active August 18, 2025 03:48
XCode Linkmap Parser
var readline = require('readline'),
fs = require('fs');
var LinkMap = function(filePath) {
this.files = []
this.filePath = filePath
}
LinkMap.prototype = {
start: function(cb) {
@onevcat
onevcat / orientation-in-framework.m
Created October 28, 2014 02:43
Swizzle to solve Landscape mode in a Portrait app. Can be used in third party framework. If you are working on an app, you can only modify the app delegate to achieve it.
#pragma mark - Magic
// Need for supporting orientation when not supported in host app plist.
// Swizzle original -application:supportedInterfaceOrientationsForWindow: to change supported orientation in runtime.
-(void) swizzleSupportedInterfaceOrientationsForWindow
{
Class applicationDelegateClass = [[UIApplication sharedApplication].delegate class];
Class sdkClass = [self class];
SEL originalSelector = @selector(application:supportedInterfaceOrientationsForWindow:);
SEL swizzledSelector = @selector(las_application:supportedInterfaceOrientationsForWindow:);
import Foundation
extension String
{
var length: Int {
get {
return countElements(self)
}
}
@clayton
clayton / ffmpeg-install.sh
Created August 9, 2013 18:55
Install FFMPEG on OS X with HomeBrew to convert Mp4 to WebM
# Installation
brew install ffmpeg --with-vpx --with-vorbis --with-libvorbis --with-vpx --with-vorbis --with-theora --with-libogg --with-libvorbis --with-gpl --with-version3 --with-nonfree --with-postproc --with-libaacplus --with-libass --with-libcelt --with-libfaac --with-libfdk-aac --with-libfreetype --with-libmp3lame --with-libopencore-amrnb --with-libopencore-amrwb --with-libopenjpeg --with-openssl --with-libopus --with-libschroedinger --with-libspeex --with-libtheora --with-libvo-aacenc --with-libvorbis --with-libvpx --with-libx264 --with-libxvid
# Easy Peasy
ffmpeg -i video.mp4 video.webm
@ragingwind
ragingwind / Backend Architectures Keywords and References.md
Last active October 22, 2025 20:58
Backend Architectures Keywords and References
from sys import argv
import random
import time
n=int(argv[1]) #recibe parametros n= longitud de cadena donde se busca
m=int(argv[2]) #recibe parametros m=longitud de patron a buscar
def generar(tam): #Funcion para generar patron o texto
x='' #Variable para guardar el texto o patron a generar
for i in range(tam):