Skip to content

Instantly share code, notes, and snippets.

View robrecord's full-sized avatar
💭
I may be slow to respond.

robrecord

💭
I may be slow to respond.
View GitHub Profile
@aserranoni
aserranoni / gist:3ff260f52a61180036e63181fc87cd77
Created October 19, 2023 01:58
A life without yabai window borders
# I've been using a combination of yabai, skhd (with modal keybindings), and sketchybar.
## Recently, with the deprecation of the window border in yabai. I had to find a way to
## keep track of the skhd current mode.
# Add the following lines to sketchybarrc:
sketchybar --add item mode_indicator left
sketchybar --set mode_indicator drawing_method=separator
sketchybar --set mode_indicator label="default-mode | "
@irazasyed
irazasyed / composer-process-issue-solution.md
Created April 18, 2022 01:24
Composer - The process has been signaled with signal "6" - Solution

Composer - The process has been signaled with signal "6" - Solution

If you're on macOS and suddenly composer has started throwing this weird error and you're wondering where the problem is, well, here's the solution and how to debug.

Problem

Error when you run composer global update or any other similar commands.

In Process.php line 441:
@romkatv
romkatv / migrate-zsh-dotfiles.zsh
Last active January 24, 2025 16:35
Migrate zsh dotfiles from the home directory to another directory on the same machine
# This command moves your zsh dotfiles (.zshrc, .zsh_history, etc.)
# from the home directory to ~/.config/zsh. It's been verified to
# work correctly if you are using zsh4humans. With other zsh configs
# your mileage may vary.
#
# How to:
#
# 1. Close all terminals except one.
# 2. Copy-paste this command into the only remaining terminal.
() {
#!/usr/bin/env bash
#from https://gist.github.com/dvishniakov/86c83ef891d200674522c791589d42b3
# Provides stack trace when error occurs or when manually called
# $1 is message
# $2 is command
# ${ContinueOnErrors} controls whether to continue or stop script if error is catched.
# it helps during batch processing. -o errexit/errtrace also affects this
errexit() {
local errno=$? # non-zero when this function is called via trap
@JasonLG1979
JasonLG1979 / asound.conf
Last active September 9, 2022 01:27
/etc/asound.conf
# /etc/asound.conf
###############################################################################
pcm.hqstereo20 {
@args [
SAMPLE_RATE FORMAT BUFFER_PERIODS
BUFFER_PERIOD_TIME VOL_MIN_DB
VOL_MAX_DB VOL_RESOLUTION VOL_NAME
]
@pagegwood
pagegwood / the-events-calendar.php
Created February 20, 2020 19:07
Remove (dequeue) all CSS and Javascript files loaded by the free version of The Events Calendar WordPress plugin by Modern Tribe (created using version 5.0.2 of the plugin)
<?php
// include this in functions.php
add_action( 'wp_enqueue_scripts', function() {
//this is based on using the "skeleton styles" option
$styles = [
'tribe-events-bootstrap-datepicker-css',
'tribe-events-calendar-style',
'tribe-events-custom-jquery-styles',
@irazasyed
irazasyed / .gitignore_global
Created May 14, 2019 07:34
Global GitIgnore
*~
*.diff
*.err
*.orig
*.rej
*.swo
*.swp
*.vi
# Compiled source #
<?php
/*
Plugin Name: Enable/Disable plugins when doing local dev
Plugin URL: https://gist.github.com/pbiron/52bb63042cf220256ece89bc07fb57b0
Description: If the WP_LOCAL_DEV constant is true, enables/disables plugins that you specify
Version: 0.1
License: GPL version 2 or any later version
Author: Paul V. Biron/Sparrow Hawk Computing
Author URI: https://sparrowhawkcomputing.com
*/
@VirtuBox
VirtuBox / php7.1.md
Last active June 14, 2021 19:50
How to install php7.1-fpm with EasyEngine

How to install php7.1-fpm with EasyEngine


Install php7.1-fpm

apt install php7.1-common php7.1-cli php7.1-zip php7.1-opcache php7.1-mysql php7.1-mcrypt php7.1-mbstring php7.1-json php7.1-intl php7.1-gd php7.1-fpm php7.1-curl php7.1-bz2

Copy the php7.1-fpm pool configuration from php7.0-fpm

cp -f /etc/php/7.0/fpm/pool.d/www.conf /etc/php/7.1/fpm/pool.d/www.conf
@ryansechrest
ryansechrest / post-receive.sh
Last active February 12, 2017 12:41
Git post-receive hook to deploy WordPress and plugins as submodules. It can also install Node.js modules with npm and vendor packages with Composer.
#!/bin/bash
# Created on 7/17/13 by Ryan Sechrest
# Deploys pushed branch from the origin repository to the web directory
if [[ (-n $1) && (-n $2) && (-n $3) ]]; then
# Set path to project directory
project_path="/var/www/domains/$2/$3"