Skip to content

Instantly share code, notes, and snippets.

@s4y
s4y / LICENSE.md
Created August 26, 2011 17:11
For Mac OS X: Get a list of running processes, and tell if a particular process is running, by name

Copyright (c) 2010 DeepTech, Inc.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE O

@hallazzang
hallazzang / main.go
Last active April 28, 2024 06:58
[go] (Windows) ensure all child processes are killed when main program exits
package main
import (
"os/exec"
"unsafe"
"golang.org/x/sys/windows"
)
// We use this struct to retreive process handle(which is unexported)
@LukeZGD
LukeZGD / ios-downgrade-dualboot.md
Last active April 28, 2024 06:57
Downgrade and dualboot status of almost all iOS devices

Downgrade and dualboot status of almost all iOS devices

UPDATED: 2024-04-09

@berkorbay
berkorbay / github_desktop_ubuntu.md
Last active April 28, 2024 06:55
To install Github Desktop for Ubuntu

IMPORTANT

See the following links for further updates to Github Desktop for Ubuntu. These are official instructions. (also mentioned by fetwar on Nov 3, 2023)

For the sake of "maintaining the tradition" here is the updated version.

@KornWtp
KornWtp / ESP32+GPS ATGM336H GPS Module .ino
Last active April 28, 2024 06:54
ESP32+GPS ATGM336H GPS Module .ino
#include <TinyGPS++.h>
#include <HardwareSerial.h>
#define RXPin (16)
#define TXPin (17)
static const uint32_t GPSBaud = 9600;
// The TinyGPS++ object
TinyGPSPlus gps;
@Klerith
Klerith / docker-compose.yml
Last active April 28, 2024 06:49
PostgreSQL + PgAdmin
version: '3'
services:
myDB:
image: postgres:15.3
container_name: my-database
restart: always
ports:
- 5432:5432
environment:
@atoonk
atoonk / AWS_v4prefixes.md
Last active April 28, 2024 06:48
AWS prefixes

Summary

Total number of IPv4 addresses: 100,750,168. That’s the equivalent of just over six /8’s Also see this blog: https://toonk.io/aws-and-their-billions-in-ipv4-addresses/

just for fun, let's put a value number on that

Total value at, $20 per IP: => $2,015,003,360

Total value at, $25 per IP: => $2,518,754,200

@sylvainfaivre
sylvainfaivre / thinkpad_cpu_throttling_lap_mode.md
Last active April 28, 2024 06:48
CPU throttling and "lap mode" on Lenovo Thinkpad laptops

CPU throttling and "lap mode" on Lenovo Thinkpad laptops

Test setup

Hardware : Lenovo Thinkpad P14s, Intel(R) Core(TM) i7-10510U CPU @ 1.80GHz

Software : Ubuntu 21.10, Gnome 40.4.0, Linux 5.13.0

Background

@kouroshHakha
kouroshHakha / create_test_dataset.py
Created December 11, 2023 05:06
JSON Mode and Function-calling on Open LLMs Blogpost
import datasets
import re
import json
import tqdm
ds = datasets.load_dataset("glaiveai/glaive-function-calling-v2", split="train")
out_ds_size = 100
class UserAssistantNotFoundError(Exception):
@meloonics
meloonics / example.md
Last active April 28, 2024 06:46
Obsidian CSS: Stylable Image containers with captions, made from Callouts

image-paths are obviously broken on this one, you can replace the links with images of your own.

[!fig|left|snail]- ![[snail.png|Snail Facts!|200]] Snails are cool! Click to learn more!

  • Snails r cute :3
  • They be eating leaf
  • Swirly soft-boi chomkers :3333

Read-more [[Le Smail Manifesto|here]]!

[!fig|right|px] ![[meloonics_64.png|64]] It me!