Note: Please go to docs.rightscale.com to access the current RightScale documentation set. Also, feel free to Chat with us!
Home > Guides > Dashboard Users Guide > Design > RightScripts > Actions > Search RightScripts

Search RightScripts

Objective

Search RightScripts for a specific text pattern.

Table of Contents

Overview

The Search action button (Design -> RightScripts) allows you to specify a pattern to match against throughout many RightScripts.  For example, perhaps you are working on your own RightScript and are having difficulties with using "curl" or are considering using "wget" instead.  You can search through all of the imported RightScripts for example usages of the curl utility.  The Steps below use this example to help explain how this feature works.

Steps

Search for

You enter the search criteria in the "Search for" field:

  • Alphanumeric text pattern to match against
  • The search is case-sensitive
  • Wild cards and regular expressions are not supported
  • The content of the RightScripts themselves is searched, not the names of the RightScripts  (use the filter by name feature)

Search in

The "Search in" field allows you to expand or contract the category of RightScripts you search within.  Simply check which of the script types you want to search in (multiple checkboxes are supported).

  • Private (default)
  • Imported

 

screen-SearchRightScript-v1.png

Output

The output of your search is displayed in a separate window.  It is pretty self explanatory, but here are a few more points for clarity sake:

  • A summary of how many scripts and matches found and displayed at the top
Found a total of 11 script(s) containing  "curl"  
Displaying 11 script(s), 11 matching line(s) and 11 occurence(s)
  • The pattern match is highlighted in red
res=`curl -S -s -o - -f https://www.dnsmadeeasy.com/servlet/updateip?username=$DNSMADEEASY_USER\&password=$DNSMADEEASY_PASSWORD\&id=$DNS_ID\&ip=$ipaddr`
  • Although there is no context included in the output (e.g. lines above and/or below the matched line), the line number is included, as well as a hyperlink to view the script itself.
    • Hint:  Right click the script hyperlink and you can open it up in a new window, or a new tab
  • If your pattern is matched many times, not all occurrences will necessarily be displayed.  Once the 10th match is recorded, the search is completed for the current line, and then it moves on looking for matches in the next RightScript.
You must to post a comment.
Last modified
13:55, 19 Aug 2013

Tags

Classifications

This page has no classifications.

Announcements

None


© 2006-2014 RightScale, Inc. All rights reserved.
RightScale is a registered trademark of RightScale, Inc. All other products and services may be trademarks or servicemarks of their respective owners.