Skip to content

Commit 5d09bfc

Browse files
author
Daniel Bolton
committed
update README, file exts
1 parent 88f1fc3 commit 5d09bfc

File tree

2 files changed

+67
-12
lines changed

2 files changed

+67
-12
lines changed

README.md

Lines changed: 47 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,74 @@
11
# dbbolton's scripts
2-
https://github.com/dbbolton/scripts
2+
<https://github.com/dbbolton/scripts>
33

44
This repository is an eclectic collection of scripts that typically populate
55
my ~/bin. Most are written in Perl, but there are some Shell and Vim scripts
66
in the mix as well (I try to make a point to include file extensions for
77
those who care what they are).
88

9-
* **apin.pl** - avoids pitfalls in running aptitude through **su -c**.
9+
* **apin.pl** avoids pitfalls in running aptitude through **su -c**.
1010

11-
* **apt-carbon.pl** - generates a shell script to duplicate a Debian system
11+
* **apt-carbon.pl** generates a shell script to duplicate a Debian system
1212
easily.
1313

14-
* **cpu-gov.pl** - decides which CPU governor and implements it based on power
14+
* **cpu-gov.pl** decides which CPU governor and implements it based on power
1515
source.
1616

17-
* **dwn-status.pl** - provides several functions for displaying system info
17+
* **dwn-status.pl** provides several functions for displaying system info
1818
in the dwm "status bar"; add this script to your
1919
**~/.xinitrc** before dwm.
2020

21-
* **file-rename.pl** - sensibly renames files with problematic characters.
21+
* **file-rename.pl** sensibly renames files with problematic characters.
2222

23-
* **forkbomb.pl** - is an example of obfuscated perl code. Doesn't work.
23+
* **forkbomb.pl** is an example of obfuscated perl code. Doesn't work.
2424

25-
* **ipad.pl** - shows your interface's IP address and your external address.
25+
* **ipad.pl** shows your interface's IP address and your external address.
2626

27-
* **kernel-deb.sh** - saves typing durning the kernel build process.
27+
* **kernel-deb.sh** saves typing durning the kernel build process.
2828

29-
* **ladj.pl** - helps in generating Wiktionary entries for first declension
29+
* **ladj.pl** helps in generating Wiktionary entries for first declension
3030
Latin adjectives.
3131

32-
* **media-sync.pl** - eases my rsync procedure.
32+
* **media-sync.pl** eases my rsync procedure.
3333

34-
* **nvidia-installer.pl** - offers choice of available versions and automates
34+
* **nvidia-installer.pl** offers choice of available versions and automates
3535
installation of **nvidia** Xorg drivers from the Debian repos; also offers
3636
choice of available Nvidia binary installers and can store default args.
3737

38+
* **pct-err.pl** calculates percent error.
3839

40+
* **perlcalc.pl** acts as a command-line calculator; uses **eval**, and
41+
only includes a really basic safety net.
42+
43+
* **rmrf.pl** is another example of obfuscated Perl. It probably doesn't
44+
work; I haven't tried it.
45+
46+
* **rua.pl** see **apin.pl**.
47+
48+
* **std-dev.pl** calculates standard deviation from user input.
49+
50+
* **systats.pl** provides easy access to system information like active
51+
memory, battery charge, CPU temperature, etc.
52+
53+
* **thunar-edit.pl** is useful as a custom action in Thunar for opening
54+
different types of files in their respective editors based on file
55+
extensions.
56+
57+
* **tidy-diff.vim** is a simple Vim script that runs **perltidy** on the
58+
current file, splits the current window in diff mode, and highlights the
59+
differences between your file and perltidy's output. Run :diffoff to exit
60+
diff mode.
61+
62+
* **tint2theme.pl** is a theme switcher for **tint2**; assumes you have all
63+
theme files is one directory ( easily configurable ).
64+
65+
* **urxvt-icon-updater.sh** is a shell script that replaces URxvt's joke of
66+
an icon with a more recognizable terminal icon from the Oxygen theme ( you
67+
could easily modify this to Gnome/Tango or something else ); requires
68+
**convert** from **imagemagick**.
69+
70+
* **wifi-switch.pl** allows you to switch easily between two frequently used
71+
wireless networks if you configure your connection through **interfaces(5)**.
72+
73+
* **xdeftheme.pl** swaps pre-defined Xdefaults themes.
3974

urxvt-icon-updater.sh

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
#!/bin/bash
2+
3+
pix='/usr/share/pixmaps'
4+
theme='/usr/share/icons/oxygen'
5+
icon='utilities-terminal.png'
6+
7+
mv -v "$pix/urxvt.xpm" "$pix/urxvt.xpm.orig"
8+
convert -resize 32x32 "$theme/32x32/apps/$icon" \
9+
"$pix/urxvt.xpm"
10+
11+
for size in 16 32 48; do
12+
mv -v "$pix/urxvt_${size}x${size}.xpm" \
13+
"$pix/urxvt_${size}x${size}.xpm.orig"
14+
15+
convert -resize ${size}x${size} "$theme/${size}x${size}/apps/$icon" \
16+
"$pix/urxvt_${size}x${size}.xpm"
17+
done
18+
19+
echo
20+
echo "All finished."

0 commit comments

Comments
 (0)