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
m4/.seedlock : m4/seed.m4 | |
@echo "Generating the macro..." | |
@m4 m4/seed.m4 | |
@touch m4/.seedlock | |
m4/seed.m4 : src/header src/procedure src/footer | |
@echo "Generating seed m4 file..." | |
@bin/template.pl > m4/seed.m4 |
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/env perl | |
# for formality's sake | |
use strict; | |
use warnings; | |
# Handling the options | |
use Getopt::Long; | |
# Default value |
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/env perl | |
# for formality's sake | |
use strict; | |
use warnings; | |
# reading directories | |
opendir(DIR,'.') or die "$!"; | |
my $index = 0; |
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
# foreach(x, (item_1, item_2, ..., item_n), stmt) | |
define(`foreach', `pushdef(`$1', `')_foreach(`$1', `$2', `$3')popdef(`$1')') | |
define(`_arg1', `$1') | |
define(`_foreach', | |
`ifelse(`$2', `()', , | |
`define(`$1', _arg1$2)$3`'_foreach(`$1', (shift$2), `$3')')') |
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
" <statusline> | |
let g:gitCurrentBranch = '' | |
function! CurrentGitBranch() | |
let cwd = getcwd() | |
cd %:p:h | |
let branch = matchlist(system('/usr/bin/env git branch -a --no-color'), '\v\* ([0-9A-Za-z\/]*)\r?\n') | |
execute 'cd ' . cwd | |
if (len(branch)) | |
let g:gitCurrentBranch = '[git:' . branch[1] . ']' | |
else |
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/bash | |
# finding out the shell script directory | |
CURDIR=`dirname $0` | |
# copying the .files as a soft link | |
find $CURDIR -type f -name ".*" -maxdepth 1 -print0 | xargs -0 -J % ln -s % $HOME 2>/dev/null |
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/bash | |
/usr/bin/find . -type d -name .git -prune -p -type d -empty -print -exec touch {}/.gitkeep \; |
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/bash | |
for FILE in `find . -name "*" -maxdepth 1` | |
do | |
case $FILE in | |
*.scm) echo $FILE ;; | |
esac | |
done | |
for FILE in `find . -name "*" -maxdepth 1` |
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/bash | |
# Set the LANG to C | |
LANG=C | |
# Acquiring the IP address | |
echo "[`date '+%Y/%m/%d %H:%M:%S'`] Acquiring the IP address." >> /tmp/static_ip.log | |
IP=`/sbin/ifconfig eth0 | grep 'inet addr' | awk '{print $2;}' | cut -f2 -d':'` |
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/env perl | |
# === Libraries === | |
use strict; | |
use warnings; | |
use Perl6::Say; | |
use utf8; | |
use Encode; |