Skip to content

Instantly share code, notes, and snippets.

View d2s's full-sized avatar

Daniel Schildt d2s

View GitHub Profile
@d2s
d2s / macos-wifi-aliases.sh
Last active February 4, 2020 21:31
Bash / Zsh aliases for macOS WiFi configuration management
# -----------------------------------------------------------
# Network configuration metadata
#
# - https://github.com/drduh/macOS-Security-and-Privacy-Guide#wi-fi
# -----------------------------------------------------------
alias macos-wifi-configuration="defaults read /Library/Preferences/SystemConfiguration/com.apple.airport.preferences.plist"
alias macos-wifi-configuration-backup="macos-wifi-configuration > ~/Desktop/macos-wifi-configuration-backup-$(date +%F-%H%M).txt"
alias macos-wifi-grep-ssid="macos-wifi-configuration | grep wifi.ssid | tr -d \"[:blank:]\" | sort | uniq"
alias macos-wifi-grep-SSIDString="macos-wifi-configuration | grep SSIDString | tr -d \"[:blank:]\" | sort | uniq"
alias macos-wifi-network-names="macos-wifi-grep-SSIDString"
@d2s
d2s / pull-changes-from-upstream.sh
Created June 20, 2019 18:56
Pull changes from an upstream Git repository
#!/usr/bin/env bash
# Add `upstream` Git repository
# git remote add upstream https://github.com/d2s/companies.git
# Merge latest changes from the `upstream` Git repository
git fetch upstream
git checkout master
git merge upstream/master
@d2s
d2s / index.html
Created September 12, 2019 23:20
Kokonaisarvio datan hyötypotentiaalista (Heat Map with Plotly.js)
<head>
<!-- Plotly.js -->
<script src="https://cdn.plot.ly/plotly-latest.min.js"></script>
</head>
<body>
<header>
<h1>Heat Map with Plotly.js</h1>
</header>
@d2s
d2s / afp.conf
Last active May 6, 2018 10:57 — forked from dinigo/afp.conf
Install netatalk (afp) in Ubuntu with service announcing and provide a Time Machine share. Users must belong to `timemachine` group to be allowed to use it.
[TimeMachine]
path = /store/time-machine
time machine = yes
valid users = @timemachine
@d2s
d2s / hugo.md
Last active July 17, 2017 21:08
Installing Hugo
@d2s
d2s / settings.json
Last active March 2, 2017 08:14
Visual Studio Code configuration
// Place your settings in this file to overwrite the default settings
{
// ==================================
// PRIVACY SETTINGS
// Disable crash reporting
// https://code.visualstudio.com/Docs/supporting/faq#_how-to-disable-crash-reporting
"telemetry.enableCrashReporter": false,
// Disable telemetry reporting
// https://code.visualstudio.com/Docs/supporting/faq#_how-to-disable-telemetry-reporting
@d2s
d2s / terminal-error-log.txt
Created March 31, 2012 19:58
Install error: brew install redis-php
ada:~ d2s$ brew install redis-php
==> Downloading https://github.com/nicolasff/phpredis/tarball/2.1.3
Already downloaded: /Users/d2s/Library/Caches/Homebrew/redis-php-2.1.3.tgz
==> phpize
==> ./configure --prefix=/usr/local/Cellar/redis-php/2.1.3
==> make
/bin/sh /private/tmp/homebrew-redis-php-2.1.3-pyGo/nicolasff-phpredis-43bc590/libtool --mode=compile /usr/bin/clang -I. -I/private/tmp/homebrew-redis-php-2.1.3-pyGo/nicolasff-phpredis-43bc590 -DPHP_ATOM_INC -I/private/tmp/homebrew-redis-php-2.1.3-pyGo/nicolasff-phpredis-43bc590/include -I/private/tmp/homebrew-redis-php-2.1.3-pyGo/nicolasff-phpredis-43bc590/main -I/private/tmp/homebrew-redis-php-2.1.3-pyGo/nicolasff-phpredis-43bc590 -I/usr/local/Cellar/php/5.3.10/include/php -I/usr/local/Cellar/php/5.3.10/include/php/main -I/usr/local/Cellar/php/5.3.10/include/php/TSRM -I/usr/local/Cellar/php/5.3.10/include/php/Zend -I/usr/local/Cellar/php/5.3.10/include/php/ext -I/usr/local/Cellar/php/5.3.10/include/php/ext/date/lib -DHAVE_CONFIG_H -Os -w -pipe -march=nat
Unbrewed static libraries were found in /usr/local/lib.
If you didn't put them there on purpose they could cause problems when
building Homebrew formulae, and may need to be deleted.
Unexpected static libraries:
/usr/local/lib/libassuan-pth.a
/usr/local/lib/libassuan.a
Unbrewed .la files were found in /usr/local/lib.
~ > brew install imagemagick
/usr/local/git/bin/git
==> Cloning https://github.com/adamv/ImageMagick.git
M www/api/animate.html
M www/api/annotate.html
M www/api/attribute.html
M www/api/blob.html
M www/api/cache-view.html
M www/api/cache.html
M www/api/cipher.html
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by GnuTLS configure 2.10.4, which was
generated by GNU Autoconf 2.67. Invocation command line was
$ ./configure --disable-debug --disable-dependency-tracking --prefix=/usr/local/Cellar/gnutls/2.10.4 --disable-guile
## --------- ##
## Platform. ##