Skip to content

Instantly share code, notes, and snippets.

View robrecord's full-sized avatar

Hello world robrecord

View GitHub Profile
@romkatv
romkatv / migrate-zsh-dotfiles.zsh
Last active April 10, 2024 10:44
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.
() {
@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 | "
<?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
*/
@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
]
@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:
@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
#!/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
@jcanfield
jcanfield / msie-vmwarefusion-osx.bash
Created April 3, 2013 02:56
Download the latest VMWare Fusion images from Modern.IE for Internet Explorer Testing. This bash script is primitive and simple. Anybody who would like to expand on this is more than welcome to.
#!/bin/bash
# Download all VMWare Fusion machines from Modern.IE Website to test your Website/Web Application in Microsoft Internet Explorer on Mac OSX. All VM's and other VM's for Windows and Linux and other Virtual Manager's such as VirtualBox can be found at http://modern.ie/
# Don't have cURL or want to learn more, visit http://curl.haxx.se/.. are you really a Developer? First part of that sentence comes from the MS site.
read -p "--> Downloading Internet Explorer 6-10 on Windows XP/7/8 Appliances for VMWare Fusion. Large downloads ahead. (Press Enter to continue)."
echo "--> Download Internet Explorer 6 on Microsoft Windows XP Appliance for VMWare Fusion."
curl --progress-bar -O "http://virtualization.modern.ie/vhd/IEKitV1_Final/VMWare_Fusion/IE6_XP/IE6.XP.For.MacVMware.sfx"
echo "--> Download Internet Explorer 8 on Microsoft Windows XP Appliance for VMWare Fusion."
@irazasyed
irazasyed / .gitignore_global
Created May 14, 2019 07:34
Global GitIgnore
*~
*.diff
*.err
*.orig
*.rej
*.swo
*.swp
*.vi
# Compiled source #
@rtorr
rtorr / gist:2493270
Created April 25, 2012 20:54
Temporary fix for using symlinks with google drive (gdrive) on mac
Because gdrive will not actually sync symlinks from your computer to gdrive, you should temporarily do the opposite.
For example, I wanted to have a symlink from my ~/Sites directory to automatically sync with gdrive, so i did the simple command:
ln -s ~/Sites/drive ~/Google\ Drive/mSites/
That will not sync at the moment.
So instead I made a directory in gdrive and did a symlink back in my ~/Sites directory