Skip to content

Instantly share code, notes, and snippets.

View pedramamini's full-sized avatar
👋

Pedram Amini pedramamini

👋
View GitHub Profile
const ignoreFolders = ["YouTube"];
const ignoreContent = "Watched"; // Define the content to ignore

const results = dv.pages(`"/"`)
  .file.tasks
  .where(task => !ignoreFolders.includes(task.path.split("/")[0]) && !task.text.includes(ignoreContent));
const tasks = [...results].flat();

const completedTasks = tasks.filter(task => task.completed);
@pedramamini
pedramamini / ped_bjj_glossary.md
Created June 11, 2024 02:23
These prompts and bash script provide a pipeline for downloading, transcribing, and summarizing videos from my YouTube playlist into my Obsidian notebook.

IDENTITY and PURPOSE

You are a No-Gi Brazilian Jiu Jitsu Black belt who is fluent in Japanese and knows all the modern day positional lingo.

You'll be creating a glossary of No-Gi BJJ terminology.

Take a deep breath and think step-by-step how to do the following STEPS.

STEPS

@pedramamini
pedramamini / ped_sitrip.md
Last active August 1, 2024 16:08
Give me a precise and concise report from the provided content.

Identity and Purpose

You are the worlds greatest content summarizer with an IQ of 479. You've been hired by the President of the United States of America to act as the official summarizer of all content that she's to read. To accomplish this job well you must be both PRECISE and CONCISE. Do not lose any information, but exercise extreme brevity when relaying that information. Spend 8 virtual hours following this step-by-step methodology and then producing a report following the Template defined below, finally read in the content to summarize under the Input section.

Step-by-Step Methodology

  1. Initial Reading and Understanding
    • Objective: Grasp the core message and main points.
    • Action: Read the entire document quickly to get an overview.
  2. Identify Key Sections
  • Objective: Locate sections with essential information.
#### Sigma Rule: Initial Access via Social Engineering and RMM Tool Installation
```yaml
title: Initial Access via Social Engineering and RMM Tool Installation
id: 1a2b3c4d-5e6f-7g8h-9i0j-1k2l3m4n5o6p
description: Detects the installation of Remote Monitoring and Management (RMM) utilities following social engineering attacks, which may indicate initial access by threat actors.
status: experimental
author: Your Name
logsource:
category: process_creation
product: windows
#!/bin/bash
# pop-working: Pops the top block of multiline content from the "working" file.
# It reads lines until it finds a line with at least 3 hyphens (e.g. "------").
# If a separator is found, the lines before it are copied to the clipboard (via pbcopy),
# displayed to the user, and removed (including the separator) from the file.
# If no separator is found, the entire file is copied to the clipboard and the file is emptied.
# If the file exists but is empty, the script exits with a message.
# Finally, the script counts the number of remaining blocks (separated by lines of ≥3 hyphens)
# and displays that count.