Skip to content

Instantly share code, notes, and snippets.

#!/bin/zsh
# WARNING! The script is meant to show how and what can be disabled. Don’t use it as it is, adapt it to your needs.
# Credit: Original idea and script disable.sh by pwnsdx https://gist.github.com/pwnsdx/d87b034c4c0210b988040ad2f85a68d3
# Disabling unwanted services on macOS Big Sur (11), macOS Monterey (12), macOS Ventura (13) and macOS Sonoma (14)
# Disabling SIP is required ("csrutil disable" from Terminal in Recovery)
# Modifications are written in /private/var/db/com.apple.xpc.launchd/ disabled.plist, disabled.501.plist
# To revert, delete /private/var/db/com.apple.xpc.launchd/ disabled.plist and disabled.501.plist and reboot; sudo rm -r /private/var/db/com.apple.xpc.launchd/*
# user
@b0gdanw
b0gdanw / Disable-Ventura-Bloatware.sh
Last active February 11, 2025 08:52
Disable Ventura Bloatware
#!/bin/zsh
# Credit: Original idea and script disable.sh by pwnsdx https://gist.github.com/pwnsdx/d87b034c4c0210b988040ad2f85a68d3
# Disabling unwanted services on macOS Big Sur (11), macOS Monterey (12) and macOS Ventura (13)
# Disabling SIP is required ("csrutil disable" from Terminal in Recovery)
# Modifications are written in /private/var/db/com.apple.xpc.launchd/ disabled.plist, disabled.501.plist
# To revert, delete /private/var/db/com.apple.xpc.launchd/ disabled.plist and disabled.501.plist and reboot; sudo rm -r /private/var/db/com.apple.xpc.launchd/*
# user
@b0gdanw
b0gdanw / DisableBigSur.sh
Last active January 10, 2025 05:15
Disable Big Sur services
#!/bin/zsh
#Credit: Original idea and script disable.sh by pwnsdx https://gist.github.com/pwnsdx/d87b034c4c0210b988040ad2f85a68d3
#Disabling unwanted services on macOS 11 Big Sur (11) and macOS Monterey (12)
#Disabling SIP is required ("csrutil disable" from Terminal in Recovery)
#Modifications are written in /private/var/db/com.apple.xpc.launchd/ disabled.plist and disabled.501.plist
# user
TODISABLE=()
@crawc
crawc / rate_to_influx.sh
Last active December 24, 2021 15:27 — forked from lfdominguez/rate_to_influx.sh
Send traffics stats by ip from pfsense to influxdb
#!/bin/sh
#
# Author: Luis Felipe Domínguez Vega <[email protected]>
# https://gist.github.com/lfdominguez/08de623d9f9c0fa84e6b4d5d0d25025c
# Program to use with the rate software to send to InfluxDB the
# rate of each IP on interface
#
# rate_to_influx <influxdb_url> <influxdb_database> <local_network> <interface>
# rate_to_influx http://127.0.0.1:8086 network 192.168.0.0/24 re1
@sobolevn
sobolevn / hkt_in_python.py
Last active May 30, 2022 20:04
Higher Kinded Types in Python
import abc
import dataclasses
from typing import Callable, Generic, TypeVar
# TODO: pip install returns
# TODO: add `returns.contrib.mypy.returns_plugin` to mypy plugins
# TODO: read the docs at https://github.com/dry-python/returns
from returns.primitives.hkt import Kind1, SupportsKind1, kinded
_ValueType = TypeVar('_ValueType')
@dale3h
dale3h / autocopy.sh
Created August 27, 2020 03:53
[unRAID] Auto-Copy for Unassigned Devices Plugin
#!/usr/bin/env bash
################################################################
# Auto-Copy Script for unRAID Unassigned Devices Plugin
# Original script: https://gitlab.com/snippets/1737763
################################################################
PATH=/usr/local/sbin:/usr/sbin:/sbin:/usr/local/bin:/usr/bin:/bin
# Available variables:
#
//
// FakeKeyEvents.swift
// CutBox
//
// Created by Jason Milkins on 26/3/18.
// Copyright © 2019-2020 ocodo. All rights reserved.
//
import Foundation
import Carbon
@czombos
czombos / smb.conf
Last active December 26, 2023 16:45
Configure Samba to Work Better with Mac OS X
[global]
use sendfile = yes
allow insecure wide links = yes
min protocol = SMB2
vfs objects = catia fruit streams_xattr
fruit:aapl = yes
fruit:nfs_aces = no
fruit:model = Xserve
fruit:resource = stream
fruit:metadata = stream
@apearson
apearson / node-red
Last active February 28, 2024 09:50
Node-RED FreeBSD RC Script
#!/bin/sh
#
# PROVIDE: nodered
# REQUIRE: LOGIN
# KEYWORD: shutdown
# Author: Andrew Pearson (apearson.io)
# Version: 1.0.2
# Description:
@roman-ku
roman-ku / flask_unveil_server.py
Created January 1, 2019 01:56 — forked from peterkuma/server.py
A flask server for serving all JPEG images in a local directory and subdirectories. Uses unveil.js for lazy-loading of images. Thumbnails are created on the fly by PIL.
# you also need to download this file: https://github.com/luis-almeida/unveil/blob/master/jquery.unveil.js
# and place it in the same directory as this python file with the name "jquery.unveil.js"
import os
from io import BytesIO
from flask import Flask, Response, request, abort, render_template_string, send_from_directory
from PIL import Image