这是indexloc提供的服务,不要输入任何密码
Skip to content

Instantly share code, notes, and snippets.

@Dark-Kernel
Dark-Kernel / Music.sh
Created January 19, 2025 12:08
Music Scriptss...
#!/bin/bash
mus=$(curl -s -H "user-agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/88.0.4324.182 Safari/537.36" "https://soundcloud.com/search?q=$1" | grep -Eo '<li><h2>.*' | grep -Eo 'href=".*"' | cut -d = -f2 )
arr=()
while IFS= read -r val; do
arr+=("$val")
done < <(printf '%s\n' "$mus")
if [ "$2" == "l" ]; then
sel=$(echo "$mus" | sed "s/'//g; s/\"//g" | fzf)
@ogrrd
ogrrd / dnsmasq OS X.md
Last active July 26, 2025 15:19
Setup dnsmasq on OS X

Never touch your local /etc/hosts file in OS X again

To setup your computer to work with *.test domains, e.g. project.test, awesome.test and so on, without having to add to your hosts file each time.

Requirements

Install

@DokaDev
DokaDev / mbr.asm
Created July 26, 2025 15:14
16bit-protected-mode-legacy-mbr
[ORG 0]
[BITS 16]
SECTION .text
jmp 0x07C0:ENTRY
TOTALSECTORCOUNT: dw 0x02
KERNEL32SECTORCOUNT: dw 0x02
BOOTSTRAPPROCESSOR: db 0x01 ; BP
STARTGRAPHICMODE: db 0x01
@antirez
antirez / life.c
Created July 5, 2025 13:38
Game of life as implemented in the YouTube C video lessons
#include <stdio.h>
#include <unistd.h>
#define GRID_COLS 20
#define GRID_ROWS 20
#define GRID_CELLS (GRID_COLS*GRID_ROWS)
#define ALIVE '*'
#define DEAD '.'
/* Translate the specified x,y grid point into the index in
@CypherpunkSamurai
CypherpunkSamurai / spec.md
Last active July 26, 2025 15:12
Kiro AI System Prompt

System Prompt

Identity

You are Kiro, an AI assistant and IDE built to assist developers.

When users ask about Kiro, respond with information about yourself in first person.

You are managed by an autonomous process which takes your output, performs the actions you requested, and is supervised by a human user.

You talk like a human, not like a bot. You reflect the user's input style in your responses.

@mfaisalkhatri
mfaisalkhatri / regression_retesting_compare.md
Last active July 26, 2025 15:10
Regression Testing Vs Retesting
Criteria Regression Testing Retesting
Goal The goal of regression testing is to make sure that the new code changes does not break the existing functionality of the software. The goal of retesting is to make sure that the reported bug has been fixed after code changes.
Scope Regression testing covers overall software or critical features of the software to check if everything is working as expected. Retesting covers only the specific failed test case or scenario.
When Performed? Regression testing is performed after a new feature is added to the software or major rework is done. Retesting is performed after the failed test cases are fixed.
Test Cases Regression testing considers the passed as well as failed test cases to check the overall stability of the software. Retesting covers only the specific failed test cases/scenarios.
Example Adding new option to si
@DeezNutq
DeezNutq / info.md
Last active July 26, 2025 15:08
AIDA64 keys for all editions (working @ 08.04.2024)

Note : FinalWire, you can keep trying to stop us, but you can't. You know why ? You've been using the same algorithm for 10 years. Changing it would be an inconvenience for you and your customers.

By the way, I'd suggest that you proofread your DMCA requests. If you didn't know, it's "generated" and not "genereated". Also, when referencing to someone's belonging you use the possessive form "their" and not "there".

FOR EDUCATIONAL PURPOSES ONLY, PLEASE SUPPORT THE DEVELOPPERS :)

Check BLACKLISTED for blacklisted keys

// ==UserScript==
// @name Open YouTube App
// @version 1.0.4
// @author asportnoy
// @match *://*.youtube.com/*
// @downloadURL https://gist.github.com/asportnoy/628b820184297f5fe296c1a5b79c8000/raw/open-youtube-app.user.js
// @updateURL https://gist.github.com/asportnoy/628b820184297f5fe296c1a5b79c8000/raw/open-youtube-app.user.js
// @homepage https://gist.github.com/asportnoy/628b820184297f5fe296c1a5b79c8000/
// @inject-into content
// ==/UserScript==

That time I had to compile Vim from source...

January 2, 2018

Recently, something broke in Homebrew's version of Vim. Several things seemed weird, but what first caught my eye was that misspelled words were no longer highlighted in Markdown files. This is a feature that I have previously configured and I use it often when writing blog posts and such.

Initially, I assumed I had a problem with my Vim settings. After much troubleshooting and no joy, I finally uninstalled Homebrew's version of Vim which caused my system to fall back to the default version of Vim that ships with macOS. Suddenly the highlighting worked fine.

After doing some further research, I decided I would try to compile and install Vim myself. After some googling and patching together a few different articles, this is what worked for me.