This file contains 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
-- Rename tag | |
-- Reference: http://awesome.naquadah.org/doc/api/modules/awful.prompt.html | |
awful.key({ modkey, "Shift", }, "F2", function () | |
awful.prompt.run({ prompt = "Rename tab: ", text = awful.tag.selected().name, }, | |
mypromptbox[mouse.screen].widget, | |
function (s) | |
awful.tag.selected().name = s | |
end) | |
end), |
This file contains 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
-- Rename tag | |
awful.key({ modkey, "Shift", }, "F2", function () | |
awful.prompt.run({ prompt = "Rename tab: ", text = awful.tag.selected().name, }, | |
mypromptbox[mouse.screen].widget, | |
function (s) | |
awful.tag.selected().name = s | |
end) | |
end), |
This file contains 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 | |
# Experimental: rename a AwesomeWM tag, using Zenity for UI. | |
# | |
# Should be easier. | |
# Query current tag name | |
cur=$(echo 'return require("awful").tag.selected().name' | awesome-client | sed -nE 's/.*?"(.*)"$/\1/p') | |
echo "cur: $cur" | |
# Ask for the new name |
This file contains 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
# Complete words from tmux pane(s) {{{1 | |
# Source: http://blog.plenz.com/2012-01/zsh-complete-words-from-tmux-pane.html | |
# Gist: https://gist.github.com/blueyed/6856354 | |
_tmux_pane_words() { | |
local expl | |
local -a w | |
if [[ -z "$TMUX_PANE" ]]; then | |
_message "not running inside tmux!" | |
return 1 | |
fi |
This file contains 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/bash | |
VZ="$1" | |
RESOURCE="$2" | |
if [ -z $VZ ] || [ -z $RESOURCE ]; then | |
echo "Usage: $0 VZ RESOURCE" | |
exit 1 | |
fi |
This file contains 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
# Setup a PPA repo, where the name is "user/ppaname", e.g. "blueyed/ppa" ("ppa" being the default) | |
define pparepo($apt_key = "", $dist = $ppa_default_name, $supported = ["lucid", "hardy"], $ensure = present, $keyserver = "keyserver.ubuntu.com") { | |
$name_for_file = regsubst($name, '/', '-', 'G') | |
$file = "/etc/apt/sources.list.d/pparepo-${name_for_file}.list" | |
file { "$file": } | |
case $ensure { | |
present: { | |
if ($dist) and ($dist in $supported) { | |
File["$file"] { |
This file contains 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/bash | |
cat .gitignore | egrep -v "^#|^$" | while read line; do | |
if [ -n "$line" ]; then | |
for ignored_file in $( git ls-files "$line" ); do | |
git rm --cached "$ignored_file" | |
done | |
fi | |
done |
This file contains 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
<target name="run"> | |
<exec executable="sh" | |
failifexecutionfails="true" | |
failonerror="true" | |
dir="${testnode.dir}"> | |
<arg value="run.sh"/> | |
<arg value="start"/> | |
</exec> | |
</target> |
NewerOlder