Skip to content

Instantly share code, notes, and snippets.

@felix-schwarz
felix-schwarz / openssl-build.sh
Last active March 19, 2024 03:16 — forked from steipete/openssl-build.h
Updated script that builds OpenSSL for OS X, iOS and tvOS. Bitcode enabled for iOS, tvOS. Updated to build for tvOS, use the latest SDKs, skip installing man pages (to save time), download the OpenSSL source over HTTPS, patch OpenSSL for tvOS to not use fork(). Currently requires Xcode7.1b or later (for the tvOS SDK).
#!/bin/bash
# This script downloads and builds the iOS, tvOS and Mac openSSL libraries with Bitcode enabled
# Credits:
# https://github.com/st3fan/ios-openssl
# https://github.com/x2on/OpenSSL-for-iPhone/blob/master/build-libssl.sh
# https://gist.github.com/foozmeat/5154962
# Peter Steinberger, PSPDFKit GmbH, @steipete.
# Felix Schwarz, IOSPIRIT GmbH, @felix_schwarz.
var LRU = require('lru-cache');
var i = 0;
var sets = 0;
var start = Date.now();
var last = Date.now();
var max = 8193; // 8192 is the magic number upper perf limit of plain objects
var maxAge = 1000 * 60 * 60 * 24;
#!/bin/bash
LOCALADMIN="username"
kickstart=/System/Library/CoreServices/RemoteManagement/ARDAgent.app/Contents/Resources/kickstart
echo "Configuring Remote Management"
if id -u $LOCALADMIN >/dev/null 2>&1; then
echo "Defined local admin account exists"
# Deactivate ARD agent, deny all access
echo "Deactivating ARD agent"
@minhoryang
minhoryang / getAppleBluetoothBatteryStatus.sh
Created December 3, 2015 03:50
Get the battery status of Apple Bluetooth Devices
# for Release Friends
ioreg -c BNBMouseDevice | grep BatteryPercent
ioreg -c BNBTrackpadDevice | grep BatteryPercent
ioreg -c AppleBluetoothHIDKeyboard | grep BatteryPercent
@jonschlinkert
jonschlinkert / markdown-toc_repeated-headings.md
Created December 15, 2015 19:42
Example table of contents generated by markdown-toc, correctly links repeated headings.
@pyrtsa
pyrtsa / .prompt-time
Last active February 12, 2023 05:12
Make Bash report the start times all commands, and total durations of long-running ones.
export _ps1_timer
function _ps1_timer_start {
# echo START
_ps1_timer=${_ps1_timer:-`gdate +%s%N 2> /dev/null || date +%s%N`};
}
function _ps1_timer_stop {
# echo STOP
if [ -z "$_ps1_timer" ]; then
@dteare
dteare / blogpost-staying-organized-with-teams.md
Created January 18, 2016 20:06
Staying Organized with 1Password for Teams

Staying Organized with 1Password for Teams

In our recent newsletter I had planned to share my New Year resolution to get organized and how I am using 1Password for Teams to keep my Family and Work information separate. It got too long for a newsletter so I thought I'd write a blog post instead.

First, a little bit of history is in order. I started using 1Password nearly 10 years ago and have accumulated well over 2000 items during that time. These thousands of items include work, personal, and family logins, secure notes, and just about anything else you can think of.

Here's just a few of the things I have in 1Password:

  • Personal logins for Twitter, Facebook, etc.
  • Tons of AgileBits logins and keys. Running a company needs a lot of passwords!
@pahud
pahud / build_dm_awsec2.sh
Last active September 17, 2021 13:49
build your docker-machine on AWS EC2 instance
#!/bin/bash
machine='docker-builder'
export AWS_PROFILE='pahud'
AWS_ACCESS_KEY_ID=$(aws configure get aws_access_key_id)
AWS_SECRET_ACCESS_KEY=$(aws configure get aws_secret_access_key)
VPC='vpc-xxxxxx'
docker-machine create --driver amazonec2 \
@leplatrem
leplatrem / index.html
Last active January 13, 2023 16:32
passwords
<!DOCTYPE html><html><head><title></title><meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" /><style type='text/css'>
body {
font-family:'Helvetica';
letter-spacing:-5px;
background:#000;
background-size:100%;
color:#fff;
margin:0;
padding:0;
font-weight:bold;
@ericclemmons
ericclemmons / example.md
Last active September 20, 2024 12:46
HTML5 <details> in GitHub

Using <details> in GitHub

Suppose you're opening an issue and there's a lot noisey logs that may be useful.

Rather than wrecking readability, wrap it in a <details> tag!

<details>
 Summary Goes Here