Skip to content

Instantly share code, notes, and snippets.

@moleman
moleman / Makefile
Last active January 25, 2021 07:53
Generate podcast XML feed from a folder and sync it to a remote host
# makefile
#
# Generate podcast XML feed from a folder and sync it to a remote host.
#
## Prerequisites
#
# Install dircaster
#
# 1. Clone dircaster https://github.com/miyagawa/dircaster
# 2. Inside dircaster folder: $ bundle install --path vendor/bundle
@moleman
moleman / com.zoom.autojoin.plist
Last active June 18, 2020 07:51
Auto join Zoom meeting
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>com.zoom.autojoin.plist</string>
<key>ProgramArguments</key>
<array>
<string>/usr/bin/open</string>
@moleman
moleman / Magento1ValetDriver.php
Last active April 17, 2018 08:47 — forked from spinsch/Magento1ValetDriver.php
Laravel Valet Driver for Magento 1
<?php
/*
* Magento 1 Valet Driver
* @author spinsch
* @path ~/.valet/Drivers/Magento1ValetDriver.php
*/
class Magento1ValetDriver extends ValetDriver
{
private $siteSubFolder = 'htdocs';
@moleman
moleman / Mac SSH Autocomplete
Last active April 5, 2017 08:05 — forked from aliang/Mac SSH Autocomplete
Add auto complete to your ssh, put into your .bash_profile
_complete_ssh_hosts ()
{
COMPREPLY=()
cur="${COMP_WORDS[COMP_CWORD]}"
comp_ssh_hosts=`cat ~/.ssh/known_hosts | \
cut -f 1 -d ' ' | \
sed -e s/,.*//g | \
grep -v ^# | \
uniq | \
grep -v "\[" ;
@moleman
moleman / gist:5812710
Created June 19, 2013 08:40
Jenkins - Grovvy Scripts
// Clean all workspaces
def hi = hudson.model.Hudson.instance
hi.getItems(hudson.model.Project).each {project ->
println(project.name)
project.doDoWipeOutWorkspace()
}
$attributeSetName = 'Editorial Product';
// active_from
$entityTypeId = Mage::getModel('eav/entity')
->setType('catalog_product')
->getTypeId();
$setId = $installer->getAttributeSet($entityTypeId, $attributeSetName, 'attribute_set_id');
// Add attribute set if it does not exists
if($setId === null) {