Skip to content

Instantly share code, notes, and snippets.

@yifanzz
yifanzz / code-editor-rules.md
Created December 17, 2024 00:01
EP12 - The One File to Rule Them All

[Project Name]

Every time you choose to apply a rule(s), explicitly state the rule(s) in the output. You can abbreviate the rule description to a single word or phrase.

Project Context

[Brief description ]

  • [more description]
  • [more description]
  • [more description]
@mjbalcueva
mjbalcueva / calendar.tsx
Last active August 7, 2025 03:16
shadcn ui calendar custom year and month dropdown
"use client"
import * as React from "react"
import { buttonVariants } from "@/components/ui/button"
import { ScrollArea } from "@/components/ui/scroll-area"
import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from "@/components/ui/select"
import { cn } from "@/lib/utils"
import { ChevronLeft, ChevronRight } from "lucide-react"
import { DayPicker, DropdownProps } from "react-day-picker"
use aws_sdk_s3::{Client, Endpoint, Error, Region};
use http::Uri;
use awaitgroup::WaitGroup;
#[tokio::main]
async fn main() -> Result<(), Error> {
let bucket = "joshuarobinson";
let endpoint = "http://10.62.64.200";
let prefix = "";
@nickwild-999
nickwild-999 / aws-slf-s3.js
Last active August 19, 2024 12:34
S3 Multipart upload with presigned url and progress in React
// this is my aws serverless function
const serverless = require('serverless-http');
const express = require('express');
const AWS = require('aws-sdk');
const app = express();
app.use(express.urlencoded({ extended: true }));
@tekin
tekin / .gitattributes
Last active July 2, 2025 17:00
An example .gitattributes file that will configure custom hunk header patterns for some common languages and file formats. See https://tekin.co.uk/2020/10/better-git-diff-output-for-ruby-python-elixir-and-more for more details.
# Stick this in your home directory and point your Global Git config at it by running:
#
# $ git config --global core.attributesfile ~/.gitattributes
#
# See https://tekin.co.uk/2020/10/better-git-diff-output-for-ruby-python-elixir-and-more for more details
*.c diff=cpp
*.h diff=cpp
*.c++ diff=cpp
*.h++ diff=cpp
#!/bin/bash
###
### my-script — does one thing well
###
### Usage:
### my-script <input> <output>
###
### Options:
### <input> Input file to read.
### <output> Output file to write. Use '-' for stdout.
@IanColdwater
IanColdwater / twittermute.txt
Last active August 3, 2025 09:44
Here are some terms to mute on Twitter to clean your timeline up a bit.
Mute these words in your settings here: https://twitter.com/settings/muted_keywords
ActivityTweet
generic_activity_highlights
generic_activity_momentsbreaking
RankedOrganicTweet
suggest_activity
suggest_activity_feed
suggest_activity_highlights
suggest_activity_tweet
@mossey
mossey / cloudSettings
Created July 10, 2018 16:58
Visual Studio Code Settings Sync Gist
{"lastUpload":"2018-07-10T16:58:55.808Z","extensionVersion":"v2.9.2"}
@cecilemuller
cecilemuller / 2019-https-localhost.md
Last active July 30, 2025 02:06
How to create an HTTPS certificate for localhost domains

How to create an HTTPS certificate for localhost domains

This focuses on generating the certificates for loading local virtual hosts hosted on your computer, for development only.

Do not use self-signed certificates in production ! For online certificates, use Let's Encrypt instead (tutorial).

@CJKinni
CJKinni / boxstarter.ps1
Last active December 31, 2020 03:18
Boxstarter Commands for a new Windows box.
# Description: Boxstarter Script
# Author: Chris Kinniburgh <[email protected]>
# Based heavily on https://gist.github.com/jessfraz/7c319b046daa101a4aaef937a20ff41f
# by Jess Frazelle
# Last Updated: 2017-12-31
#
# Install boxstarter:
# . { iwr -useb http://boxstarter.org/bootstrapper.ps1 } | iex; get-boxstarter -Force
#