Skip to content

Instantly share code, notes, and snippets.

View hungthai1401's full-sized avatar
πŸš€
Focusing

Thai Nguyen Hung hungthai1401

πŸš€
Focusing
View GitHub Profile
@ruvnet
ruvnet / .roomodes.json
Last active April 21, 2025 03:48
This guide introduces Roo Code and the innovative Boomerang task concept, now integrated into SPARC Orchestration. By following the SPARC methodology (Specification, Pseudocode, Architecture, Refinement, Completion) and leveraging advanced reasoning models such as o3, Sonnet 3.7 Thinking, and DeepSeek, you can efficiently break down complex proj…
{
"customModes": [
{
"slug": "sparc",
"name": "⚑️ SPARC Orchestrator",
"roleDefinition": "You are SPARC, the orchestrator of complex workflows. You break down large objectives into delegated subtasks aligned to the SPARC methodology. You ensure secure, modular, testable, and maintainable delivery using the appropriate specialist modes.",
"customInstructions": "Follow SPARC:\n\n1. Specification: Clarify objectives and scope. Never allow hard-coded env vars.\n2. Pseudocode: Request high-level logic with TDD anchors.\n3. Architecture: Ensure extensible system diagrams and service boundaries.\n4. Refinement: Use TDD, debugging, security, and optimization flows.\n5. Completion: Integrate, document, and monitor for continuous improvement.\n\nUse `new_task` to assign:\n- spec-pseudocode\n- architect\n- code\n- tdd\n- debug\n- security-review\n- docs-writer\n- integration\n- post-deployment-monitoring-mode\n- refinement-optimization-mode\n\nValidate:\nβœ… Files < 500 lines\nβœ… No hard-coded
@iamhenry
iamhenry / cline_custom_modes.json
Last active April 21, 2025 03:52
My Roocode Custom Modes Config
{
"customModes": [
{
"slug": "lean-prompt-code",
"name": "Code (@GosuCoder Lean Prompt)",
"roleDefinition": "You are Roo, a highly skilled software engineer with extensive knowledge in many programming languages, frameworks, design patterns, and best practices.",
"groups": [
"read",
"edit",
"command",
@Dowwie
Dowwie / prd_tod.txt
Created March 13, 2025 09:07
Product requirement document generation using LLM task oriented dialogue
This is an LLM-assisted workflow for creating a product requirement document using LLM assistance for task completion.
It keeps track of inputs for the template and works with the user to acquire them, finally generating a completed PRD
prompt when all slots are addressed.
credit: Ian Nuttall - https://gist.github.com/iannuttall/f3d425ad5610923a32397a687758ebf2
**System-Prompt for Facilitating Chat-Based PRD Creation**
@sontl
sontl / country-detect-cf-worker.js
Created December 27, 2024 07:49
Country detection using CF Worker
addEventListener('fetch', event => {
event.respondWith(handleRequest(event.request))
})
async function handleRequest(request) {
const headers = {
'Access-Control-Allow-Origin': '*',
'Content-Type': 'application/json'
}
@shinsenter
shinsenter / Experimental Docker structure.md
Last active December 27, 2024 09:14
Docker structure for deploying to multiple environments

Beginning

There are many approaches to implementing a reuse of a common preset for Docker services for multiple environments, such as production and local environments.

This makes it possible to ensure the highest consistency for different environments with the same code-base. Implementing reuse of docker compose options also makes it easier to manage them.

I found on github a project called serversideup/spin. They took an approach using a feature called Docker overrides, to change some properties of common services for different environments.

After reading through their documentation, I realized that there are a few real-life cases where this project can not implement (or is difficult to archive).

@kesor
kesor / component-app.js
Last active April 23, 2024 15:18
Vue.js 3.x with ES6 modules in the browser using import-map
import { defineAsyncComponent } from 'vue'
const Content = defineAsyncComponent(() => import('./component-content.js'))
export default {
name: 'App',
components: { Content },
template: /*html*/`
<Content />
`
@ChristopherA
ChristopherA / brew-bundle-brewfile-tips.md
Last active April 16, 2025 15:50
Brew Bundle Brewfile Tips

Brew Bundle Brewfile Tips

Copyright & License

Unless otherwise noted (either in this file or in a file's copyright section) the contents of this gist are Copyright ©️2020 by Christopher Allen, and are shared under spdx:Creative Commons Attribution Share Alike 4.0 International (CC-BY-SA-4.) open-source license.

Sponsor

If you more tips and advice like these, you can become a monthly patron on my GitHub Sponsor Page for as little as $5 a month; and your contributions will be multipled, as GitHub is matching the first $5,000! This gist is all about Homebrew, so if you like it you can support it by donating to them or becoming one of their Github Sponsors.

@matteocrippa
matteocrippa / flutter.md
Last active April 20, 2025 03:41
Flutter Cheatsheet

Flutter

A quick cheatsheet of useful snippet for Flutter

Widget

A widget is the basic type of controller in Flutter Material. There are two type of basic Widget we can extend our classes: StatefulWidget or StatelessWidget.

Stateful

StatefulWidget are all the widget that interally have a dynamic value that can change during usage. It can receive an input value in the constructor or reference to functions. You need to create two classes like:

@ZwodahS
ZwodahS / copy_redis_key.sh
Created March 1, 2016 06:07
copy a redis db key to another place (use MIGRATE COPY for v3.0<= redis)
#!/bin/bash
# source http://stackoverflow.com/questions/23222616/copy-all-keys-from-one-db-to-another-in-redis
#set connection data accordingly
source_host=localhost
source_port=6379
source_db=1
target_host=localhost
target_port=6379
target_db=2
.
β”œβ”€β”€ books
β”‚Β Β  β”œβ”€β”€ handlers.go
β”‚Β Β  └── models.go
β”œβ”€β”€ config
β”‚Β Β  └── db.go
└── main.go