Skip to content

Instantly share code, notes, and snippets.

View anoxic's full-sized avatar
🐙
working on it all at once

Bad Sir Brian anoxic

🐙
working on it all at once
View GitHub Profile
@lynt-smitka
lynt-smitka / .htaccess
Last active June 10, 2024 15:48
Block hidden files except .well-known - Apache .htaccess + Nginx
RewriteRule "(^|/)\.(?!well-known\/)" - [F]
diff --git a/src/config.rs b/src/config.rs
index 5142b9b..80fe5a2 100644
--- a/src/config.rs
+++ b/src/config.rs
@@ -369,6 +369,7 @@ impl de::Deserialize for ActionWrapper {
"Paste" => Action::Paste,
"Copy" => Action::Copy,
"PasteSelection" => Action::PasteSelection,
+ "OpenNewWindow" => Action::OpenNewWindow,
"Quit" => Action::Quit,
@comboy
comboy / 1.mars
Last active August 29, 2015 14:11
baby steps
!:
|_ [hid=hide ~]
++ poke-mars-args
|= [ost=bone you=ship *]
:_ +>.$
:- [ost %pass / %g %cide %$]
:- [ost %give %nice ~]
%+ turn (~(tap by sup.hid))
|= [ost=bone *]
=- [ost %give %rush %tang -]
@staltz
staltz / introrx.md
Last active June 13, 2024 19:58
The introduction to Reactive Programming you've been missing
@rummik
rummik / for.di
Last active April 10, 2019 04:44
Random Dimond code examples
#**
* For statement definition
*
* @example
* for { $i=0; $i<20; $i++ } {
* ...
* }
*#
define { Function, Function } 'for' {
@ksafranski
ksafranski / expecting.md
Last active November 11, 2023 23:00
Basic principles of using tcl-expect scripts

Intro

TCL-Expect scripts are an amazingly easy way to script out laborious tasks in the shell when you need to be interactive with the console. Think of them as a "macro" or way to programmaticly step through a process you would run by hand. They are similar to shell scripts but utilize the .tcl extension and a different #! call.

Setup Your Script

The first step, similar to writing a bash script, is to tell the script what it's executing under. For expect we use the following:

#!/usr/bin/expect
@athieriot
athieriot / gist:5532748
Last active June 19, 2021 13:32
Hipchat with IRSSI

If you are adventurous, here the process to have Hipchat working in your favourite IRC client:

@qbit
qbit / gist:5483415
Last active February 25, 2024 13:35
KSH support for git-prompt
# ksh git prompt support
#
# Copyright (C) 2006,2007 Shawn O. Pearce <spearce@spearce.org>
# Distributed under the GNU General Public License, version 2.0.
#
# This script allows you to see repository status in your prompt.
#
# To enable:
#
# 1) Copy this file to somewhere (e.g. ~/.git-prompt.sh).
<?php
// app/start/global.php
/*
|--------------------------------------------------------------------------
| Application Error Logger
|--------------------------------------------------------------------------
|
| Here we will configure the error logger setup for the application which
@Crash--
Crash-- / gist:4204272
Created December 4, 2012 14:08
Optimize ?
public function __get($key)
{
$func = array($this, 'get' . ucwords($key));
if (\is_callable($func)) {
return call_user_func($func);
}
}