Skip to content

Instantly share code, notes, and snippets.

View clavery's full-sized avatar

Charles Lavery clavery

View GitHub Profile
@clavery
clavery / routes.jsx
Last active February 15, 2024 18:03 — forked from sandragolden/routes.jsx
Hybrid Override routes.jsx
/*
* Copyright (c) 2021, salesforce.com, inc.
* All rights reserved.
* SPDX-License-Identifier: BSD-3-Clause
* For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause
*/
/* istanbul ignore file */
// NOTE!
// This file is being ignored in the test coverage report for now. It reports `0%` functions
@clavery
clavery / frigate_0.10_notification.yaml
Last active February 16, 2023 20:44 — forked from hunterjm/frigate_0.10_notification.yaml
Frigate 0.10 Notifications (w/ occupancy filter list)
blueprint:
name: Frigate Notification (0.10.0 w/ occupancy filter)
description: |
## Frigate Mobile App Notification
This blueprint will send a notification to your device when a Frigate event for the selected camera is fired. The notification will initially include the thumbnail of the detection, but include an actionable notification allowing you to view the clip and snapshot.
With this blueprint, you may send the notification to multiple devices by leaving "Device" blank and instead use a [notification group][1].
### Software Version Requirements
@clavery
clavery / Vagrantfile
Last active August 29, 2015 14:08 — forked from joehinkle/Vagrantfile
Simple PHP vagrant box for Centos 6
# -*- mode: ruby -*-
# vi: set ft=ruby :
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing!
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.vm.box = "chef/centos-6.6"
config.vm.provision :shell, path: "bootstrap.sh"
config.vm.network "forwarded_port", guest: 80, host: 8080
@clavery
clavery / Vagrantfile
Last active March 1, 2018 20:14 — forked from joehinkle/Vagrantfile
Simple PHP vagrant box for ubuntu trusty 64 w/ Mysql
# -*- mode: ruby -*-
# vi: set ft=ruby :
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing!
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.vm.box = "ubuntu/trusty64"
config.vm.provision :shell, path: "bootstrap.sh"
config.vm.network "forwarded_port", guest: 80, host: 8080
@clavery
clavery / 0_reuse_code.js
Last active August 29, 2015 14:08
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
{% macro form_field(field) -%}
{% set with_label = kwargs.pop('with_label', False) %}
{% set placeholder = '' %}
{% if not with_label %}
{% set placeholder = field.label.text %}
{% endif %}
<div class="control-group {% if field.errors %}error{% endif %}">
{% if with_label %}
<label for="{{ field.id }}" class="control-label">
{{ field.label.text }}{% if field.flags.required %} *{% endif %}:
@clavery
clavery / RPS.js
Last active December 21, 2015 21:39 — forked from joehinkle/RPS.js
// Initializing Variables
var selection = prompt("Do you choose rock, paper or scissors?");
var PLAYS = ['scissors', 'paper', 'rock'];
var mine = PLAYS.indexOf(selection);
if(mine < 0) {
console.log("Bad play!!");
return;
function download_all_checked(frm){
// if we got this far, we should try to download
// all the checked boxes.
for (var i = 0; i < document.frmbook.elements.length; i++) {
var e = document.frmbook.elements[i];
if( e.name == 'allbox' ){
continue;
}