From esselfe, 5 Years ago, written in Bash.
This paste is a reply to lmbf.sh / lvu find from esselfe - view diff
Embed
  1. #!/bin/bash
  2. # Script to find Lunar modules by partial name
  3.  
  4. find_module() {
  5.     NSTR="-iname \"*$1*\""
  6.    
  7.     if [ ! -z "$2" ]; then
  8.         shift
  9.         for MODNAME in "$@"; do
  10.             NSTR="$NSTR -o -iname \"*$MODNAME*\""
  11.         done
  12.     fi
  13.  
  14.     cd /var/lib/lunar/moonbase
  15.     bash -c "find * -type d $NSTR"
  16. }
  17.  
  18. find_module "$@"
  19.  

Replies to Re: lmbf.sh / lvu find rss

Title Name Language When
temat Georgemag cil 4 Years ago.
Re: Re: lmbf.sh / lvu find esselfe bash 5 Years ago.