Skip to content

Instantly share code, notes, and snippets.

@miebach
miebach / gist:6942965
Last active December 25, 2015 07:59
sublime text 3 unoficial ppa
From: http://www.webupd8.org/2013/07/sublime-text-3-ubuntu-ppa-now-available.html (with modifications)
Before proceeding, if you've already installed Sublime Text, make sure the application is not running or else there might be some visual glitches (that's because the package in our PPA will replace any already existing Sublime Text deb packages). This only occurs when switching from the Sublime Text 3 debs downloaded from its website to the packages in our PPA.
Also, using the instructions below, the old Sublime Text 2 package (if you've used our Sublime Text 2 PPA) will be replaced with the new Sublime Text 3.
To add the WebUpd8 Sublime Text 3 (beta) PPA and install the application in Ubuntu 13.10, 13.04, 12.10 or 12.04 (and derivatives), use the following commands:
sudo add-apt-repository ppa:webupd8team/sublime-text-3
@miebach
miebach / script-declutter
Created October 11, 2013 18:05
Removes control characters from a typescript created with the linux "script" command.
#!/usr/bin/perl -wp
# clean up control characters and other non-text detritus that shows up
# when you run the "script" command.
# From http://impson.tzo.com/~jdimpson/bin/script-declutter
# Copyright Jeremy Impson - http://impson.tzo.com/~jdimpson/
# Also see http://jdimpson.livejournal.com/7040.html
BEGIN {
@miebach
miebach / gist:6643201
Last active December 23, 2015 13:39
windows command shortcuts
http://support.microsoft.com/kb/192806
english:
Accessibility Options | access.cpl
Add/Remove Programs | appwiz.cpl
Add Hardware Wizard | hdwwiz.cpl
Automatic Updates | wuaucpl.cpl
Bluetooth Properties | bthprops.cpl
Display Properties | desk.cpl
@miebach
miebach / .geo
Last active December 23, 2015 10:29
Set screen geometry for different screens and resolutions
#!/bin/sh
export GEO=1024x570
#export GEO=1024x1000
#export GEO=1024x600
#export GEO=1024x740
#export GEO=1152x844
#export GEO=1280x740
#export GEO=1280x1000
#export GEO=1440x840
@miebach
miebach / CherryPy as a windows service
Last active December 23, 2015 08:29
Cherrypy server logging and running as a service on windows
This will result in 3 log files: the access log, the error log
and another one for the remaining console_output. Even
after configuring the access and the error log still
a lot of output only gos to the console, so it is necessary
to catch it. On windows it could be done like this:
serve.cmd:
---------
cd %~dp0
<!DOCTYPE html>
<html>
<head>
<meta charset=utf-8 />
<title>Hello</title>
<link rel="stylesheet" href="styles.css">
</head>
<body>
Hello World
</body>
#!/usr/bin/perl
use strict;
use warnings;
use VMware::VIRuntime;
# Default Variablen
my $exit_code = 0;
@miebach
miebach / Default.sublime-keymap
Last active December 19, 2015 03:39
Sublime 2 Settings - Menu "Preferences" -> "Settings - User"
[
{
"keys": ["alt+w"],
"command": "toggle_setting",
"args":
{
"setting": "word_wrap"
}
}
]
byobu new-session -d -s name; byobu new-window -t name:1 -n 'window-1-title' 'command-1'; byobu new-window -t name:2 -n 'window-2-title' 'command-2'; byobu select-window -t name:1; byobu -2 attach-session -t name
@miebach
miebach / gist:5677146
Last active December 17, 2015 21:49
Move a dierctory tree with rsync over the network
#!/bin/sh
# Move a directory tree with rsync over the network.
# Will remove each file immedeateley from the source after transfer!
# Run this on the source machine:
SRC=/src/folder-to-move-away
REMOTE=user@ip.local
TARGET=/target/containing-folder/