Skip to content

Instantly share code, notes, and snippets.

@bradymiller
bradymiller / mirrorOpenEMR_sf_git
Created October 31, 2010 09:18
Script to mirror the SF git repo to github, gitorious, bitbucket, assembla and google code
#!/bin/bash
#
# Copyright (C) 2010 Brady Miller <brady@sparmy.com>
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
#
@spcmky
spcmky / ExampleType.php
Last active April 10, 2019 07:52
Symfony2 Form Type Fieldset Example
<?php
// src/Acme/DemoBundle/Form/ExampleType.php
namespace Acme\DemoBundle\Form;
use Symfony\Component\Form\AbstractType;
use Symfony\Component\Form\FormBuilderInterface;
use Acme\DemoBundle\Form\Type\FieldsetType;
class ExampleType extends AbstractType {
@franz-josef-kaiser
franz-josef-kaiser / pcduino_setup.md
Last active April 23, 2018 22:29
pcDuino v1 setup - incl. XBMC

Handy shortcuts

  • Access main menu: Alt + F1

  • Open Terminal: �Ctrl + Alt + T

  • Fullscreen window toggle: F11

  • Package manager apt-get intro and handy stuff

Step by Step guide

@sparrc
sparrc / phabricator_readme.md
Last active March 25, 2024 05:59
Phabricator Ubuntu Installation Guide

Phabricator Ubuntu Installation Guide

This is a supplement to the official Phabricator Installation Guide, because their guide will leave you with all kinds of permission and config errors and ~15,000 setup issues on startup.

Install bonus packages:

# apt-get install mercurial subversion python-pygments sendmail imagemagick

Create necessary users and add phd-user to sudoers:

@geekman
geekman / jffs2.py
Created October 26, 2015 16:30
JFFS2 scripts
#!/usr/bin/env python
#
# tool to parse JFFS2 images
# and more importantly, guess the erase block size
#
# 2015.10.19 darell tan
#
from struct import unpack
from argparse import ArgumentParser
@jazzycamel
jazzycamel / threads1.py
Last active March 29, 2023 21:49
Simple example of the correct way to use (Py)Qt(5) and QThread
from PyQt5.QtCore import *
from PyQt5.QtWidgets import *
from itertools import count, islice
class Threaded(QObject):
result=pyqtSignal(int)
def __init__(self, parent=None, **kwargs):
super().__init__(parent, **kwargs)
@Fr6jDJF
Fr6jDJF / ddc-ci.py
Created May 23, 2016 10:02 — forked from vdcrim/ddc-ci.py
Python script for adjusting the settings of my monitor, by using DDC/CI
#!/usr/bin/env python3
"""
Show and adjust display parameters on an Iiyama ProLite XB2483HSU-B1 monitor
Requirements:
- mentioned monitor (27' should also work) with DDC/CI setting on
- Windows Vista+
- Python 3
@jonathanelbailey
jonathanelbailey / iso_image_edit.psm1
Last active December 20, 2023 19:28
a powershell module that allows for the modification of ISO images.
# this function grabs the iso image from the user supplied http location.
function get-isoimage{
[CmdletBinding()]
param(
$uri,
$workingfolder
)
begin{
$file_name = $uri -replace "http://[\s\S]+\/([\s\S]+\.iso)$",'$1'
$out_file = Join-Path $workingfolder -ChildPath $file_name
@SMSAgentSoftware
SMSAgentSoftware / New-WPFMessageBox
Last active April 28, 2024 11:24
PowerShell function to display a customizable WPF message box / window
Function New-WPFMessageBox {
# For examples for use, see my blog:
# https://smsagent.wordpress.com/2017/08/24/a-customisable-wpf-messagebox-for-powershell/
# CHANGES
# 2017-09-11 - Added some required assemblies in the dynamic parameters to avoid errors when run from the PS console host.
# Define Parameters
[CmdletBinding()]
/*AGENT_SHEET included by CustomCSSforFx*/
/* Draw a line over selected tab. See https://raw.githubusercontent.com/mozilla/gecko-dev/master/browser/base/content/tabbrowser-tab.js for structure */
/* https://www.reddit.com/r/FirefoxCSS/comments/c5aqyn/my_userchromecss_customizations/ for funky styling */
.tabbrowser-tab:not([usercontextid]) .tab-content[selected="true"],
.tabbrowser-tab[usercontextid] .tab-content[selected="true"] .tab-label-container {
background-image: linear-gradient(to bottom,rgba(255,192,0,0),rgba(255,192,153,32));
}
.tabbrowser-tab[unread] .tab-label {