Skip to content

Instantly share code, notes, and snippets.

@jlia0
jlia0 / agent loop
Last active April 30, 2025 06:17
Manus tools and prompts
You are Manus, an AI agent created by the Manus team.
You excel at the following tasks:
1. Information gathering, fact-checking, and documentation
2. Data processing, analysis, and visualization
3. Writing multi-chapter articles and in-depth research reports
4. Creating websites, applications, and tools
5. Using programming to solve various problems beyond development
6. Various tasks that can be accomplished using computers and the internet
@markusand
markusand / Brewfile
Last active March 15, 2025 17:08
macOS auto setup
tap "homebrew/bundle"
# BASIC SOFTWARE -->
brew "mas"
# mas "Slack", id: 803453959
mas "The Unarchiver", id: 425424353
mas "Spark", id: 1176895641
mas "Dropover", id: 1355679052
mas "Bitwarden", id: 1352778147
cask "rectangle"
@apizz
apizz / Install_AirPrint_Printer.sh
Last active February 17, 2025 10:27
Programmatically adds an AirPrint printer, ideally with an icon
#!/bin/bash
# Use the built-in ipp2ppd tool to create a PPD file for AirPrint
# Add icon to PPD (if we can get one) and install the printer
# Required printer info
readonly PRINTER_IP='XXX.XXX.XXX.XXX'
readonly PRINTER_NAME='PRINTER_NAME'
readonly PRINTER_DISPLAY_NAME='PRINTER NAME'
readonly PRINTER_LOCATION='PRINTER LOCATION'
@vikytech
vikytech / clean-my-mac.sh
Last active November 4, 2024 13:20
Script to clean the mac Almost like a new one
#!/usr/bin/env bash
# Ask for the administrator password upfront
sudo -v
HOST=$( whoami )
function install() {
echo "Download Mac Cleaner"
curl -o /Users/${HOST}/cmm.sh https://gist.githubusercontent.com/vikytech/f28c5480c1e1d8c2688981803b45a29a/raw/cleaner.sh
echo "Init Mac Cleanup"
@0187773933
0187773933 / OneDriveRemoverOSX.sh
Last active April 1, 2025 16:35
Completely Uninstalls OneDrive from Mac OSX and all settings just change username
#!/bin/bash
sudo pkill -9 OneDrive
sudo rm -rf /Applications/OneDrive.app/
sudo rm /Library/LaunchAgents/com.microsoft.OneDriveStandaloneUpdater.plist
sudo rm /Library/LaunchDaemons/com.microsoft.OneDriveStandaloneUpdaterDaemon.plist
sudo rm /Library/LaunchDaemons/com.microsoft.OneDriveUpdaterDaemon.plist
sudo rm -rf /Library/Logs/Microsoft/OneDrive
sudo rm /private/var/db/receipts/com.microsoft.OneDrive-mac.bom
@b0gdanw
b0gdanw / osx-software-update-urls-10.3-to-14.txt
Last active December 4, 2024 01:19 — forked from deltakhan/osx-software-update-urls.txt
URLs of the index files used by the software update client on OS X
10.3 (Panther):
https://swscan.apple.com/scanningpoints/scanningpointX.xml
10.4 (Tiger):
https://swscan.apple.com/content/catalogs/index.sucatalog
https://swscan.apple.com/content/catalogs/index-1.sucatalog
10.5 (Leopard):
https://swscan.apple.com/content/catalogs/others/index-leopard.merged-1.sucatalog
@painor
painor / FastTelethon.py
Last active April 18, 2025 16:50
This will increase the download/upload speed when using telethon
# copied from https://github.com/tulir/mautrix-telegram/blob/master/mautrix_telegram/util/parallel_file_transfer.py
# Copyright (C) 2021 Tulir Asokan
import asyncio
import hashlib
import inspect
import logging
import math
import os
from collections import defaultdict
from typing import Optional, List, AsyncGenerator, Union, Awaitable, DefaultDict, Tuple, BinaryIO
@sabas1080
sabas1080 / ESP32_HID.ino
Last active November 25, 2024 08:30
Example of HID Keyboard BLE with ESP32
/*
Copyright (c) 2014-2020 Electronic Cats SAPI de CV. All right reserved.
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
@youandhubris
youandhubris / AppleScript Mail Send.scpt
Last active March 4, 2025 18:45
AppleScript to send e-mail, using Apple's Mail, with multiple recipients, cc, bcc and attachments
tell application "Mail"
set theFrom to ""
set theTos to {}
set theCcs to {}
set theBccs to {}
set theSubject to ""
set theContent to ""
set theSignature to ""
@masklinn
masklinn / cheatsheet.md
Last active April 17, 2025 02:20
launchctl/launchd cheat sheet

I've never had great understanding of launchctl but the deprecation of the old commands with launchctl 2 (10.10) has been terrible as all resources only cover the old commands, and documentation for Apple utilities is generally disgracefully bad, with launchctl not dissembling.

Mad props to https://babodee.wordpress.com/2016/04/09/launchctl-2-0-syntax/ which contains most details

domains

Internally, launchd has several domains, but launchctl 1 would only ask for service names,