Sponsored Content
Full Discussion: fun scripts
The Lounge What is on Your Mind? fun scripts Post 302307944 by quirkasaurus on Thursday 16th of April 2009 04:55:29 PM
Old 04-16-2009
sure, i'll bite. here's my version of an Obfuscated Ksh script:
Works on Solaris

Code:
_="$(($$\/$$))";$(`[[ "${#@}" \
!= "${_[*]:-)}" ]];`;)&&\exit \
"$((${?%%,}+${_[@]:=%}))"||$(`\
"${_[@]:+:}">|"${@}".~`:)&&$(`\
\sed \-${!:-e} '/^\(\<.*\>\)$/\
,/^\(\<.*\>\)$/{'"${_[*]:?~}"'\
,$s~^\(\<.**\>\)$~|&|~;}' \-e \
'/[:-)]/,/[%-!]/{$,$y?^?#?;}'<\
+("${@:-)}")>>".//${1##/*/}.~"\
;`;)&&$(>&-;:`${-:+};<&-`;$!);\

It has at least some error checking and returns the correct status
if something goes wrong.

Oh. And notice the variety of smiley faces in there.
 

7 More Discussions You Might Find Interesting

1. News, Links, Events and Announcements

Fun with FreeBSD

Fun With Automounting on FreeBSD Link: Nice tips for FreeBSD Unix. http://ezine.daemonnews.org/200202/automounting.html (2 Replies)
Discussion started by: killerserv
2 Replies

2. UNIX for Dummies Questions & Answers

fun with tar

ok, i've figured out my problem with distributed, in Solaris GUI if you click on a tar file it will untar it for you, using paramiters I don't know. now, I've got a tar file in / called dnetc-solaris26-x86.tar i want to install it to the "/Veitch" directory how exactly do I use the tar... (17 Replies)
Discussion started by: veitcha
17 Replies

3. UNIX for Advanced & Expert Users

like to have fun in terminal

Hai Friends I have installed FreeBSD in my system... I have installed it to work in text mode don't have the GUI. The default text color is Black background with White Foreground. I want it to be with Black background with Green Foreground. How could i do that. Thanks in advance Collins (4 Replies)
Discussion started by: collins
4 Replies

4. Shell Programming and Scripting

Fun with awk

uggc://ra.jvxvcrqvn.bet/jvxv/EBG13 #!/usr/bin/awk -f BEGIN { for (n=0;n<26;n++) { x=sprintf("%c",n+65); y=sprintf("%c",(n+13)%26+65) r=y; r=tolower(y) } } { b = "" for (n=1; x=substr($0,n,1); n++) b = b ((y=r)?y:x) print b } ... (0 Replies)
Discussion started by: colemar
0 Replies

5. Shell Programming and Scripting

More fun with awk

#!/usr/bin/ksh ls -l $@ | awk ' /^-/ { l = 5*log($5) h = sprintf("%7d %-72s",$5,$8) print "\x1B ls command with histogram of file sizes. The histogram scale is logaritmic, to avoid very short bars for smaller files or very long bars for bigger files. Screenshot: (4 Replies)
Discussion started by: colemar
4 Replies

6. What is on Your Mind?

Fun things to put in comments in scripts?

Approaching the end of my portion of some STIG/DOD compliance automation and I was challenged by a co-worker to include a story in my code. There are blocks of code that need to be kept the way they are for GIT/Gerrit and then compliance, but otherwise I changed out all the comments into a... (2 Replies)
Discussion started by: Vryali
2 Replies

7. War Stories

Following Cables for Fun!

Hi Folks, I came accross this picture taken a number of years ago now, I just thought I'd share it with you guys. We were in the process of removing equipment from the Data Centre and had followed the cable through to this area, where one of the old patch areas had been. When we lifted the... (2 Replies)
Discussion started by: gull04
2 Replies
SET_INCLUDE_PATH(3)							 1						       SET_INCLUDE_PATH(3)

set_include_path - Sets the include_path configuration option

SYNOPSIS
string set_include_path (string $new_include_path) DESCRIPTION
Sets the include_path configuration option for the duration of the script. PARAMETERS
o $new_include_path - The new value for the include_path RETURN VALUES
Returns the old include_path on success or FALSE on failure. EXAMPLES
Example #1 set_include_path(3) example <?php // Works as of PHP 4.3.0 set_include_path('/usr/lib/pear'); // Works in all PHP versions ini_set('include_path', '/usr/lib/pear'); ?> Example #2 Adding to the include path Making use of the PATH_SEPARATOR constant, it is possible to extend the include path regardless of the operating system. In this example we add /usr/lib/pear to the end of the existing include_path. <?php $path = '/usr/lib/pear'; set_include_path(get_include_path() . PATH_SEPARATOR . $path); ?> SEE ALSO
ini_set(3), get_include_path(3), restore_include_path(3), include(3). PHP Documentation Group SET_INCLUDE_PATH(3)
All times are GMT -4. The time now is 05:10 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy