Skip to content

Instantly share code, notes, and snippets.

View rench's full-sized avatar
🎯
Focusing

rench rench

🎯
Focusing
View GitHub Profile
@rench
rench / cursor-agent-system-prompt.txt
Created April 17, 2025 15:49 — forked from sshh12/cursor-agent-system-prompt.txt
Cursor Agent System Prompt (March 2025)
You are a powerful agentic AI coding assistant, powered by Claude 3.5 Sonnet. You operate exclusively in Cursor, the world's best IDE.
You are pair programming with a USER to solve their coding task.
The task may require creating a new codebase, modifying or debugging an existing codebase, or simply answering a question.
Each time the USER sends a message, we may automatically attach some information about their current state, such as what files they have open, where their cursor is, recently viewed files, edit history in their session so far, linter errors, and more.
This information may or may not be relevant to the coding task, it is up for you to decide.
Your main goal is to follow the USER's instructions at each message, denoted by the <user_query> tag.
<communication>
1. Be conversational but professional.
@rench
rench / CursorTools.json
Created April 17, 2025 15:39 — forked from ScriptedAlchemy/CursorTools.json
Reverse Engineering cursor prompts
{
"tools": [
{
"type": "function",
"function": {
"name": "codebase_search",
"description": "Find snippets of code from the codebase most relevant to the search query.\nThis is a semantic search tool, so the query should ask for something semantically matching what is needed.\nIf it makes sense to only search in particular directories, please specify them in the target_directories field.\nUnless there is a clear reason to use your own search query, please just reuse the user's exact query with their wording.\nTheir exact wording/phrasing can often be helpful for the semantic search query. Keeping the same exact question format can also be helpful.",
"parameters": {
"type": "object",
"properties": {
@rench
rench / XORCipher.js
Created May 7, 2024 11:16 — forked from sukima/XORCipher.js
A Super simple encryption cipher using XOR and Base64 in JavaScript
// XORCipher - Super simple encryption using XOR and Base64
//
// Depends on [Underscore](http://underscorejs.org/).
//
// As a warning, this is **not** a secure encryption algorythm. It uses a very
// simplistic keystore and will be easy to crack.
//
// The Base64 algorythm is a modification of the one used in phpjs.org
// * http://phpjs.org/functions/base64_encode/
// * http://phpjs.org/functions/base64_decode/
@rench
rench / gist:8acae014fcdd47e9cdfde39e77b02f02
Last active April 18, 2024 16:18
发票代码: 051002100511
发票代码:
051002100511
四川增值税电子普通发票
发票号码:
33531635
开票日期:
2022年07月21日
机器编号:
661620006217
校验码:
@rench
rench / TaskTest.java
Created May 22, 2019 08:26
FutureTaskDemo
import java.util.ArrayList;
import java.util.List;
import java.util.concurrent.Callable;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
import java.util.concurrent.Future;
import java.util.concurrent.Semaphore;
import java.util.stream.IntStream;
public class TaskTest {
@rench
rench / ExtractOriginalMethodNameFromReferenceExample.java
Created April 25, 2019 07:33 — forked from thomasdarimont/ExtractOriginalMethodNameFromReferenceExample.java
One can use a SerializedLambda to unreflect the actual method referred to by a MethodReference
package de.tdlabs.training.hacks;
import java.io.Serializable;
import java.lang.invoke.SerializedLambda;
import java.lang.reflect.Method;
import java.util.Objects;
import java.util.function.Consumer;
import java.util.function.Supplier;
import static java.util.Arrays.asList;
@rench
rench / node --v8-options
Created July 4, 2017 15:39
node --v8-options
root@LEDE:~# ./node --v8-options
target arm v7 vfp3-d16 softfp
ARMv8=0 ARMv7=1 VFP3=1 VFP32DREGS=0 NEON=0 SUDIV=0 MLS=1UNALIGNED_ACCESSES=1 MOVW_MOVT_IMMEDIATE_LOADS=0 COHERENT_CACHE=0 USE_EABI_HARDFLOAT=0
Usage:
@rench
rench / elgato-eve.md
Created June 21, 2017 09:30 — forked from gomfunkel/elgato-eve.md
Elgato Eve HomeKit Services & Characteristics

Elgato Eve HomeKit Services & Characteristics

A work in progress collection of proprietary and as of yet undocumented HomeKit characteristics and their UUIDs used by Elgato Eve.

This list is not including all Eve accessories available and some services and characteristics still make no sense to me. If you have anything to contribute, please leave a comment. There is no guarantee that the information listed below is correct.

Elgato Eve Energy (Firmware Revision 1.3.1;466)

Service - Characteristic UUID R W Type Description
@rench
rench / broadlinkjs-sm_index.js
Created June 15, 2017 14:22
broadlinkjs-sm_index.js
var util = require('util');
let EventEmitter = require('events');
let dgram = require('dgram');
let os = require('os');
let crypto = require('crypto');
var Broadlink = module.exports = function() {
EventEmitter.call(this);
this.devices = {};
}
//js fn
function diag_k3_screen(element){
var name = element.name;
var value = element.value; //
if(value === 'all'){
var legend = document.getElementById('diag-rc-legend');
var output = document.getElementById('diag-rc-output');
if (legend && output)
{
output.innerHTML =