Register
Login
Resources
Docs Blog Datasets Glossary Case Studies Tutorials & Webinars
Product
Data Engine LLMs Platform Enterprise
Pricing Explore
Connect to our Discord channel

prog_use.sh 756 B

You have to be logged in to leave a comment. Sign In
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
  1. #!/bin/bash
  2. # $Id$
  3. # Returns a count of how many time a GMT program is used in our test scripts
  4. # including doc and examples. Give -l to see which scripts [Default returns the count]
  5. #
  6. . gmt_shell_functions.sh
  7. # Determines in which test and example scripts each GMT module (incl supplement) is used
  8. find . -name '*_func.c' -print | tr '/' ' ' | awk '{print $NF}' | sed -e s/_func.c//g > /tmp/t.lis
  9. while read prog; do
  10. find . -name '*.sh' -exec grep -H $prog {} \; | sed -e 'sB/share/doc/gmtB/docBg' | awk -F: '{print $1}' | sort -u > /tmp/list
  11. n=`gmt_nrecords /tmp/list`
  12. if [ $# -gt 0 ]; then
  13. echo " "
  14. echo "-------------------"
  15. fi
  16. echo "===> $prog [$n]"
  17. if [ $# -gt 0 ]; then
  18. echo "-------------------"
  19. cat /tmp/list
  20. fi
  21. done < /tmp/t.lis
Tip!

Press p or to see the previous file or, n or to see the next file

Comments

Loading...