Skip to content

Instantly share code, notes, and snippets.

View brod-ie's full-sized avatar

Ryan Brodie brod-ie

View GitHub Profile
@rudotriton
rudotriton / scriptable-calendar-widget.md
Last active August 8, 2023 14:35
Customizable iOS Calendar widget in Scriptable

Scriptable Calendar Widget

scriptable calendar

For ease of maintainability this project has moved from this gist to its own repository. You can go and visit it there.

cp -r /Applications/Xcode-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport/11.0\ \(15A5278f\) /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport/
@steipete
steipete / ios-xcode-device-support.sh
Last active December 12, 2023 03:36
Using iOS 15 devices with Xcode 12.5 (instead of Xcode 13)
# The trick is to link the DeviceSupport folder from the beta to the stable version.
# sudo needed if you run the Mac App Store version. Always download the dmg instead... you'll thank me later :)
# Support iOS 15 devices (Xcode 13.0) with Xcode 12.5:
sudo ln -s /Applications/Xcode-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport/15.0 /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport
# Then restart Xcode and reconnect your devices. You will need to do that for every beta of future iOS versions
# (A similar approach works for older versions too, just change the version number after DeviceSupport)
@mikaelbr
mikaelbr / gulpfile.js
Last active February 8, 2021 00:32 — forked from Sigmus/gulpfile.js
Gulp + Browserify + Reactify + OS Notification
var source = require('vinyl-source-stream');
var gulp = require('gulp');
var gutil = require('gulp-util');
var browserify = require('browserify');
var reactify = require('reactify');
var watchify = require('watchify');
var notify = require("gulp-notify");
var scriptsDir = './scripts';
var buildDir = './build';
@sivel
sivel / better-ssh-authorized-keys-management.md
Last active April 8, 2024 07:53
Better SSH Authorized Keys Management

Better SSH Authorized Keys Management

A seemingly common problem that people encounter is how to handle all of your users authorized_keys file.

People struggle over management, ensuring that users only have specific keys in the authorized_keys file or even a method for expiring keys. A centralized key management system could help provide all of this functionality with a little scripting.

One piece of functionality overlooked in OpenSSH is the AuthorizedKeysCommand configuration keyword. This configuration allows you to specify a command that will run during login to retrieve a users public key file from a remote source and perform validation just as if the authorized_keys file was local.

Here is an example directory structure for a set of users with SSH public keys that can be shared out via a web server:

@asugai
asugai / Install composer on Amazon AMI running on EC2
Last active March 22, 2024 03:37
Install composer on Amazon AMI running on EC2
$ cd ~
$ sudo curl -sS https://getcomposer.org/installer | sudo php
$ sudo mv composer.phar /usr/local/bin/composer
$ sudo ln -s /usr/local/bin/composer /usr/bin/composer
then you can run
$ sudo composer install
@thomsbg
thomsbg / compile_templates.js
Last active December 22, 2015 20:29
Loop through all the view prototype objects in a namespace, transforming their templateId into a template function.
var compileTemplates = function() {
_.each(App.Views, function(View) {
if (View.prototype.templateId) {
// The templateId references the id of a DOM element containing
// the content of the template
var html = jQuery('#' + View.prototype.templateId).html() || '';
View.prototype.template = _.template(html);
}
});
}
@brod-ie
brod-ie / example.sass
Created August 19, 2013 08:45
respond-to() SASS mixin for Bootstrap 3 grid system.
.profile-pic {
float: left;
width: 250px;
@include respond-to(xs) {
width: 100%;
}
@include respond-to(sm) {
width: 125px;
}
@douglasduteil
douglasduteil / .travis.yml
Last active February 22, 2021 13:27 — forked from lukewpatterson/gist:4242707
Here is how I allow Git SSH authentication in Travis CI. I'm using it to connect Travis to my repo organization AngularUI. This trick is a fork. The goal is to encode the RSA private deploy key in the .travis.yml as "-secure: xxxxx.....".
---
language: node_js
node_js:
- '0.10'
branches:
only:
- master
before_script: .travis/before_script.sh
script: echo -e " >>> Do something... \"grunt\" for example\n"
after_success: .travis/after_success.sh