This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/sh | |
| VERSION=0.2.2 | |
| wget https://bashrun2.googlecode.com/files/bashrun2-$VERSION.tar.gz | |
| tar -xzvf bashrun2-$VERSION.tar.gz | |
| cd bashrun2-$VERSION/ | |
| dh_make -f ../bashrun2-$VERSION.tar.gz --single --copyright gpl2 | |
| dpkg-buildpackage |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <openbox_menu> | |
| <menu id="date-popup" label="Date & Time" | |
| execute="date +'<openbox_pipe_menu><item label=": %a %B %d, %Y %H:%M:%S"/></openbox_pipe_menu>'" | |
| /> | |
| </openbox_menu> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/sh | |
| # | |
| # to fix: | |
| # xrandr | grep \ connected | cut -f1 -d\ | xargs -I{} xrandr --output {} --rotate normal | |
| times=2 | |
| delay=900 | |
| for y in `seq 1 $times`; do | |
| for x in right inverted left normal; do | |
| sleep $delay | |
| xrandr | grep \ connected | cut -f1 -d\ | xargs -I{} xrandr --output {} --rotate $x |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # produce a colorized path string with the git branch injected at the root of the repository | |
| PS1git='\[\e[94m\]$(git rev-parse --show-toplevel 2>/dev/null)$( \ | |
| ( test -z "$(git status -s 2>/dev/null)" && __git_ps1 "\[\e[32m\](%s)" ) \ | |
| || __git_ps1 "\[\e[91m\]{%s}" \ | |
| )\[\e[94m\]${PWD##$(git rev-parse --show-toplevel 2>/dev/null)}' | |
| # Use where you would use "\w" in your PS1 prompt. e.g.: | |
| PS1='${debian_chroot:+($debian_chroot)}\[\e[1;32m\]\u@\h\[\e[0m\]:'"$PS1git"'\[\e[0m\]\$' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?xml version="1.0" encoding="UTF-8"?> | |
| <openbox_config xmlns="http://openbox.org/3.4/rc" xmlns:xi="http://www.w3.org/2001/XInclude"> | |
| <resistance> | |
| <strength>10</strength> | |
| <screen_edge_strength>20</screen_edge_strength> | |
| </resistance> | |
| <focus> | |
| <focusNew>yes</focusNew> | |
| <followMouse>no</followMouse> | |
| <focusLast>yes</focusLast> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| socket$s,2,1,6;bind$s,pack+snN3,2,8080;listen$s,1;while(accept$c,$s){<$c>=~/\/(\S+)/;open$f,$1;print$c(<$f>);close$c} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/perl | |
| use warnings; | |
| use strict; | |
| my %pl; | |
| open(my $fh, '<', '/proc/locks') or die $!; | |
| for(<$fh>) { | |
| my @f = split /\s+/; | |
| push(@{$pl{$f[5]}}, \@f); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/perl | |
| use warnings; | |
| use strict; | |
| use CGI qw/param escapeHTML/; | |
| use MIME::Base64; | |
| ### Apache2's mod_cgi does not pass the HTTP__AUTHORIZATION header by default. | |
| ### Add this to .htaccess to work around the issue... | |
| # RewriteEngine on | |
| # RewriteCond %{HTTP:Authorization} ^(.*) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| * HTTP POST with authentiction using "basic" method. | |
| * Hybrid of anyauthput.c and postinmemory.c | |
| * Specifically adapted for SOAP use. | |
| * | |
| * Usage: | |
| * cc basicauthsoap.c -lcurl -o basicauthsoap | |
| * ./basicauthsoap | |
| * | |
| */ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| use warnings; | |
| use strict; | |
| use Win32::PingICMP; | |
| use Socket qw/inet_ntoa/; | |
| # The exact error strings as used by ping.exe | |
| my %errors = ( | |
| 'IP_BUF_TOO_SMALL' => 'General failure.', | |
| 'IP_DEST_NET_UNREACHABLE' => 'Destination net unreachable.', | |
| 'IP_DEST_HOST_UNREACHABLE' => 'Destination host unreachable.', |
OlderNewer