Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View Coldblackice's full-sized avatar

Coldblackice

  • NYC
View GitHub Profile
@Coldblackice
Coldblackice / offset.md
Created April 21, 2024 11:40 — forked from hexcowboy/offset.md
Twitch Helix API - Get Video/VOD Offset and Comments from Clip ID

Since Twitch decomissioned API V5, there's no correct way to get the VOD offset for a clip. So I just inspected what the Twitch web app was doing and came up with a super cool hack.

I know this looks really complicated but really it just does two things. First it gets the clip information from the official API, then it uses Twitch GraphQL API to get the offset.

kimne78kx3ncx6brgo4mv6wki5h1ko is the Client ID that the Twitch web app uses. It can be used to access Twitch's GraphQL API (undocumented & not for public use). The postData variable contains a request and a sha256Hash. The sha256Hash is basically a job ID and may change in the future, but I added the current hash which should work for all clips as of posting this.

const clientId = "" // Put your Twitch Client ID here
const clientSecret = "" // Put your Twitch Client Secret here
@Coldblackice
Coldblackice / hide_map.ahk
Created April 20, 2024 17:13 — forked from milypoint/hide_map.ahk
Hide map in Rust (playrust.com) while streaming for OBS Studio
/*
AutoHotKey script for hide map in Rust game while streaming in OBS Studio.
Steps for setup:
1. Download and install AutoHotKey from official website "www.autohotkey.com".
2. In your main scene in OBS create a new source that will be cover game capture scene. For example it can be some image source. Let's call it <hidden content>.
3. In OBS settings go to hotkeys and bind
@Coldblackice
Coldblackice / tst-colored-tab-groups.css
Created April 17, 2024 12:08 — forked from FabulousCupcake/tst-colored-tab-groups.css
TreeStyleTabs – Colored and Spaced Tab Groups
/* ---
Config: moz-extension://61148767-1029-7e4d-810c-8847305901bd/options/options.html
Docs: https://github.com/piroor/treestyletab/wiki/How-to-inspect-tree-of-tabs
--- */
#tabbar {
background: linear-gradient(to bottom, #342735 0%, #4B5670 50%);
}
@Coldblackice
Coldblackice / byobuCommands
Created February 15, 2024 07:30 — forked from jshaw/byobuCommands
Byobu Commands
Byobu Commands
==============
byobu Screen manager
Level 0 Commands (Quick Start)
------------------------------
<F2> Create a new window
@Coldblackice
Coldblackice / sorttables.js
Created January 12, 2024 06:00 — forked from ubershmekel/sorttables.js
Sort tables bookmarklet
/*
SortTable
version 2
7th April 2007
Stuart Langridge, http://www.kryogenix.org/code/browser/sorttable/
Instructions:
Download this file
Add <script src="sorttable.js"></script> to your HTML
Add class="sortable" to any table you'd like to make sortable
@Coldblackice
Coldblackice / copy-to-clipboard-bookmarklet.md
Created January 11, 2024 09:59 — forked from stefanmaric/copy-to-clipboard-bookmarklet.md
Create Bookmarklet (browser bookmark that executes Javsacript) to copy a given text to Clipboard

Copy-to-clipboard Bookmarklet

Create Bookmarklet (browser bookmark that executes Javsacript) to copy a given text to Clipboard.

This is the base javascript:

(function (text) {
  var node = document.createElement('textarea')
  var selection = document.getSelection()
@Coldblackice
Coldblackice / DDM2.0.md
Created June 3, 2023 09:00 — forked from nebriv/DDM2.0.md
Dell Display Manager 2.0 command line documentation

Dell Display Manager 2.0 Command Line

Decompiled DLL with ILSpy to identify various commands.

Most commands can be found in DDM2._0_UX.CmdBackground.cmdService_DoWork

Write commands can be prefixed with int:command to specify which monitor to send the command to.

.\DDM.exe /0:writebrightnesslevel 50

@Coldblackice
Coldblackice / places-exploration.sql
Created April 20, 2023 15:41 — forked from olejorgenb/places-exploration.sql
Firefox places.sqlite exploration
--- Firefox places.sqlite exploration
-- https://developer.mozilla.org/en-US/docs/Mozilla/Tech/Places/Database
-- https://wiki.mozilla.org/images/d/d5/Places.sqlite.schema3.pdf
-- http://forensicswiki.org/wiki/Mozilla_Firefox_3_History_File_Format (probably somewhat outdated)
-- [select text -> right click -> search] does not set from_visit :(
--- Magic numbers
@Coldblackice
Coldblackice / deleteDiscordMessages.js
Created April 19, 2023 13:41 — forked from victornpb/deleteDiscordMessages.js
Delete all your messages from DM or Channel in Discord
/*
This file is now hosted here:
https://github.com/victornpb/undiscord
*/
javascript:(function(){
//inspired by http://userscripts.org/scripts/show/8924
var s = document.createElement('script');
s.setAttribute('src','http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.js');
if(typeof jQuery=='undefined') document.getElementsByTagName('head')[0].appendChild(s);
(function() {
if(typeof jQuery=='undefined') setTimeout(arguments.callee, 100)
else{
jQuery("*").one("click",function(event){
//http://snippets.dzone.com/posts/show/4349