Skip to content

Instantly share code, notes, and snippets.

View webrgp's full-sized avatar
💻
Turning coffee into code

Rodrigo Passos webrgp

💻
Turning coffee into code
View GitHub Profile
@webrgp
webrgp / copilot-settings.json
Last active April 8, 2025 14:00
VSCode Copilot Settings
{
"github.copilot.nextEditSuggestions.enabled": true,
"github.copilot.selectedCompletionModel": "claude-3.7-sonnet",
"github.copilot.chat.pullRequestDescriptionGeneration.instructions": [
{ "text": "Prefix the title with the Jira ticket ID extracted from the branch name, formatted as `[ABC-123]`." },
{ "text": "Always start by adding `### What's Changed` markdown header" },
{ "text": "Use Github styled markdown formatting." },
{ "text": "List changes, focusing on what changed and why. No space between list items." },
{ "text": "Be concise and clear." },
{ "text": "When referencing files, always reference full file and wrap it with single backticks." }
@webrgp
webrgp / copilot-instructions.md
Last active April 8, 2025 13:49
Craft 4 + Vite / Copilot Custom Instructions

Cursor AI Prompting Framework

This repository provides a structured set of prompting rules to optimize interactions with Cursor AI. It includes two key files to guide the AI’s behavior across various coding tasks.

Files and Their Roles

core.md

  • Purpose: Establishes foundational rules for consistent AI behavior across all tasks.
  • Usage: Place this file in your project’s .cursor/rules/ folder to apply it persistently:
  • Save core.md under .cursor/rules/ in the workspace root.
@webrgp
webrgp / instructions.md
Created February 17, 2025 19:48
Using NodeJs 14 with Mac Silicon (M1)

Using NodeJs 14 with Mac Silicon (M1)

Workaround to get NodeJs 14 to work with Mac Silicon. Apple provides Rosetta, a translation app that allows applications that are built for Intel Chip (or previous generation Mac) to run under Apple Silicon.

Installing Rosetta

/usr/sbin/softwareupdate --install-rosetta --agree-to-license
@webrgp
webrgp / ECS-CRAFTCMS.md
Last active December 9, 2024 20:42
ECS Configuration for Craft

ECS Configuration for Craft

To utilize the latest ECS features in Craft CMS, such as parallel processing, you must replace craftcms/ecs with this:

composer remove craftcms/ecs
composer require symplify/easy-coding-standard:^12.4 —dev

The attached ecs.php file is configured to align with the Craft CMS coding standards.

@webrgp
webrgp / package-pruner.md
Last active October 15, 2024 12:47
Recursive Package Pruner

Prune ALL node_modules in directory recursively:

# List all node_modules
find . -name "node_modules" -type d -prune | xargs du -chs

# Prune all node_modules
find . -name "node_modules" -type d -prune -exec rm -rf '{}' +
@webrgp
webrgp / incident-report-processor.md
Last active August 1, 2024 18:35
AI Prompt: Incident Report Processor

AI Prompt: Incident Report Processor

Description

We can use the following prompts to get ChatGPT to consistently generate incident reports in markdown format. The prompts will help us generate incident reports in a structured manner, ensuring that all necessary sections are included, properly formatted, and filled with relevant and concise information. The AI will prioritize brevity while maintaining a neutral tone and use neutral language suitable for an audience with technical backgrounds.

Prompts

1. Enter the following prompt:

Timeline

June 5th, 9:00 am Updown monitor reported outage

Notes, Discoveries, and Insights

Free form notes go here. Add as much detail as possible.

Environment / Context Background

Incident Report / Post Mortem

Title: Example Website Outage

Date: MM/DD/YYYY
Critical / High / Medium / Low
Severity

Some code snippets for easy store creation

// makeStore.ts - A function for creating more stores

import {
  Dispatch,
  Reducer,
  useContext,
  useReducer,