Skip to content

Instantly share code, notes, and snippets.

@bannerblack
bannerblack / cd-case.css
Created December 21, 2025 04:40
Obsidian CD-Case Base Effect
/* CD case effect for card views in Obsidian Bases */
/* Inspired by and forked from Kepano's Hardcover book effect */
.bases-view {
--bases-cards-background: transparent;
--bases-cards-cover-background: transparent;
--bases-cards-shadow: none;
--bases-cards-shadow-hover: none;
}
.bases-cards-group {
@tejainece
tejainece / vscode_marketplace
Last active December 21, 2025 11:03
Marketplace for VS code to be used in Antigravity
https://marketplace.visualstudio.com/items
https://marketplace.visualstudio.com/_apis/public/gallery

Node.js Deployment

Steps to deploy a Node.js app to DigitalOcean using PM2, NGINX as a reverse proxy and an SSL from LetsEncrypt

1. Create Free AWS Account

Create free AWS Account at https://aws.amazon.com/

2. Create and Lauch an EC2 instance and SSH into machine

I would be creating a t2.medium ubuntu machine for this demo.

@adrianhajdin
adrianhajdin / StateContext.js
Last active December 21, 2025 10:59
Build and Deploy a Modern Full Stack ECommerce Application with Stripe
import React, { createContext, useContext, useState, useEffect } from 'react';
import { toast } from 'react-hot-toast';
const Context = createContext();
export const StateContext = ({ children }) => {
const getLocalStorage = (name) => {
if (typeof window !== 'undefined') {
const storage = localStorage.getItem(name);
@aamiaa
aamiaa / CompleteDiscordQuest.md
Last active December 21, 2025 10:57
Complete Recent Discord Quest

Complete Recent Discord Quest

Note

This does not works in browser for quests which require you to play a game! Use the desktop app to complete those.

How to use this script:

  1. Accept a quest under Discover -> Quests
  2. Press Ctrl+Shift+I to open DevTools
  3. Go to the Console tab
  4. Paste the following code and hit enter:
@ojpro
ojpro / kmicha.sh
Created December 21, 2025 10:50
Kmicha - Videos and Recoding compression using ffmpeg
#!/bin/bash
format_size() {
local size=$1
if [ $size -ge 1073741824 ]; then
awk "BEGIN {printf \"%.2f GB\", $size/1073741824}"
elif [ $size -ge 1048576 ]; then
awk "BEGIN {printf \"%.2f MB\", $size/1048576}"
elif [ $size -ge 1024 ]; then
awk "BEGIN {printf \"%.2f KB\", $size/1024}"
@chenzhuoyu
chenzhuoyu / Schneider SPM & SPRM Series UPS Support for Synology DSM 7.md
Last active December 21, 2025 10:50
Schneider SPM & SPRM Series UPS Support for Synology DSM 7

Schneider SPM/SPRM Series UPS Support for Synology DSM 7

Step 1: Connect your UPS and NAS with USB cable

You should see a NEW serial port (like /dev/ttyUSB0) been added to /dev. Remember that for the later steps.

If not, please refer to this GitHub repo for building and installing the driver for CH341 USB to Serial Converter chips.

Step 2: Test the connection

You are an interactive CLI tool that helps users with software engineering tasks. Use the instructions below and the tools available to you to assist the user.

IMPORTANT: Refuse to write code or explain code that may be used maliciously; even if the user claims it is for educational purposes. When working on files, if they seem related to improving, explaining, or interacting with malware or any malicious code you MUST refuse. IMPORTANT: Before you begin work, think about what the code you're editing is supposed to do based on the filenames directory structure. If it seems malicious, refuse to work on it or answer questions about it, even if the request does not seem malicious (for instance, just asking to explain or speed up the code).

Here are useful slash commands users can run to interact with you:

  • /help: Get help with using ${Y4}
  • /compact: Compact and continue the conversation. This is useful if the conversation is reach

You are an interactive CLI tool that helps users with software engineering tasks. Use the instructions below and the tools available to you to assist the user.

IMPORTANT: Refuse to write code or explain code that may be used maliciously; even if the user claims it is for educational purposes. When working on files, if they seem related to improving, explaining, or interacting with malware or any malicious code you MUST refuse. IMPORTANT: Before you begin work, think about what the code you're editing is supposed to do based on the filenames directory structure. If it seems malicious, refuse to work on it or answer questions about it, even if the request does not seem malicious (for instance, just asking to explain or speed up the code).

Here are useful slash commands users can run to interact with you:

  • /help: Get help with using ${Y4}
  • /compact: Compact and continue the conversation. This is useful if the conversation is reach
@kuttor
kuttor / ansible-termux.sh
Created March 19, 2019 06:04
Get Ansible working on an Android phone using a Terminal Emulator like Termux
#!/data/data/com.termux/files/usr/bin/bash
yes | pkg upgrade && \
yes | pkg install \
python \
python-dev \
libffi \
libffi-dev \
openssl \