[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

debian newbie "tip-of-the-day" signature script



in ~/.muttrc:

	# pipe randomized 'tip' from perl script--
	send-hook debian- "set signature='~/.signature-debian |'"
	# any email going out to any address containing "debian-"
	# gets the output of ~/.signature-debian as a signature block

and in ~/.signature-debian

	#!/usr/bin/perl
	# by will@serensoft.com

	# slurp blank-line-delimited PARAGRAPHS
	local($/) = '';

	my $txt = '?';
	my $ct = 0;

	while ( <DATA> ) {
		# likelihood of picking any paragraph is 1/total_count
		$txt = $_
			if rand() < 1.0 / ++$ct;
	}

	print <<DEBIAN;
	DEBIAN NEWBIE TIP:
	${txt}...from will\@serensoft.com
	DEBIAN

	__DATA__

	Looking to use your Debian machine as a firewall? No problem!
	Try "apt-get install ipmasq"... After you've got your
	/etc/network/interfaces file set up properly, ipmasq will
	save you lots of work, setting up firewall and routing
	tables automatically.

	Confused about using "apt-get" to keep your Debian up-to-date?
	See http://groups.yahoo.com/group/newbiedoc/files/apt-get-intro.html

	<...etc...>

-- 
DEBIAN NEWBIE TIP:
What's a "manpage"? It's the documentation you get when you enter
"man SOMETHING" such as "man ps" or "man bash" or "man apt-setup".

...from will@serensoft.com



Reply to: