home bbs files messages ]

Just a sample of the Echomail archive

Cooperative anarchy at its finest, still active today. Darkrealms is the Zone 1 Hub.

   TUXPOWER      Advocacy for the Linux operating system      1,237 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 17 of 1,237   
   Maurice Kinal to All   
   tuxpower.sh   
   24 Apr 11 17:58:22   
   
   #!/bin/bash   
   ##### A simple TUXPOWER echo area bash script posting thingy using   
   ##### Husky Project's 'hpt post' and coreutils' 'basename'   
      
   # make sure user inputs a script   
      
   if [ ! "$1" ]   
   then   
     echo -e "Usage: 'tuxpower.sh scriptname'\a"   
     exit 1   
   fi   
      
   # ensure the inputted script actually exists   
      
   if [ ! -e "$1" ]   
   then   
     echo -e "No such script as $1\a"   
     exit 10   
   fi   
      
   # set up a temporary file and output the original to it   
      
   temporary_script=`basename $1`   
   cat $1 > /tmp/$temporary_script   
      
   # replace tabs with spaces and tack on a couple lines to the end   
   # to make it look good in the TUXPOWER Fido echo and then post it   
   # The -d switch to 'htp post' will delete the temporary file   
      
   sed -i 's/\t/        /g' /tmp/$temporary_script   
   echo -e "\n# that's all there is to it.\n" >> /tmp/$temporary_script   
      
   hpt post -nt "All" \   
            -s "$temporary_script" \   
            -e "tuxpower" \   
            -z "WeBeBashing with 'hpt post'" \   
            -f loc \   
            -d /tmp/$temporary_script   
      
   # that's all there is to it.   
      
   --- WeBeBashing with 'hpt post'   
    * Origin: Pointy Stick Society (1:261/38.9)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca