Sponsored Content
Top Forums Shell Programming and Scripting Bash conditional | getting logic wrong? Post 302780137 by the_gripmaster on Thursday 14th of March 2013 01:48:31 AM
Old 03-14-2013
Is there a way to shorten snippet 2?
 

7 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Bash passes flags to shell wrong

Hi, first post, so hello to all. I have a Bash scripting problem that is driving me a bit nutty. It involves a program called 'convert' which is part of the ImageMagick collection. Normal usage from the commandline is: $ convert -resize 120x120 inputfile.jpg outputfile.jpg This is... (7 Replies)
Discussion started by: andyj
7 Replies

2. Shell Programming and Scripting

what's wrong with my bash script?

hi, please point out what's wrong with my script. im feeding it a list containing fqdn, sit should ssh into each and verify that atleast one of its virtual backup ip resolves into one of its virtual hostnames .. anyway the objective shows in the script... however, im having problems in the ... (4 Replies)
Discussion started by: ikk
4 Replies

3. Shell Programming and Scripting

Please help to fingure out what wrong with my tomcat restarting bash script

Hi, I am a nbee to Unix, I have used following script to check my tomcat is running or not and restart if it down. but actually it restart my tomcat each time running even my tomcat still running fine: Script that can run a check and perform an action if the check fails ... (1 Reply)
Discussion started by: quyennd
1 Replies

4. UNIX for Dummies Questions & Answers

Conditional statement in bash

I want to combine 2 conditional statements by using -o in bash, but it won't work. if ; then echo "The number needs to be between 0 and $nr" fi Each time i execute the file it says: ./selectCitaat: line 10: syntax error near unexpected token `$1' (3 Replies)
Discussion started by: doc.arne
3 Replies

5. UNIX for Advanced & Expert Users

Bash conditional prompt?

Hi, Does anyone know any way of making bash prompt extended with conditional content? Example: export PS1="] && echo '#' || echo '\$'" # This won't work - prompt is not executed # export PS1="\$" # This is an existing but also working equivalent I would like to use more complex... (8 Replies)
Discussion started by: adderek
8 Replies

6. Shell Programming and Scripting

What's wrong with my bash code?

I want to let sleep 3 in the background and echo $i pkglists="a b c d e f g" f() { local i set -- $pkglists && ((i +=2)) && sleep 3 &;echo $i } f (3 Replies)
Discussion started by: yanglei_fage
3 Replies

7. Shell Programming and Scripting

Conditional bash/mysql query help

I think(hope) I've got a simple one - I just need to send an email if a mysql query returns any results (ideally - it will never match). Currently I just pipe the mysql query output to the mail program, but of course that emails regardless of the output( and I check this every 10 minutes from... (5 Replies)
Discussion started by: jcass78
5 Replies
docb_transform(3erl)					     Erlang Module Definition					      docb_transform(3erl)

NAME
docb_transform - Transform XML to HTML DESCRIPTION
docb_transform contains functions for transforming XML documentation source code to HTML. EXPORTS
file(File) -> ok | {error, Reason} file(File, Options) -> ok | {error, Reason} Types File = string() Options = [Opt] Opt -- see below Transforms XML documentation source code to HTML. File is a documentation source file, given with or without the .xml extension as Name.xml or Name . If File contains XML code according to a basic DTD ( chapter , erlref , ...), the resulting HTML file is named Name.html . If File contains XML code according to a compound DTD ( application or part ), several files are created: * A cover page for the application with two frames, Name_frame.html . * The contents of the left frame and a front page, Name.html and Name_first.html . * A bibliography and a glossary, Name_cite.html and Name_term.html . * In the case of an application DTD an index is created, Name.kwc and Name_index.html . * One HTML file for each file included from File . * Also, if there exists a fascicules.xml file where the value of the entry attribute for File is "yes" , the cover page is copied to index.html . OPTIONS
{html_mod, Module}, Module=atom() : A callback module can be used for specifying HTML snippets that should be included in the generated HTML files, see below. {outdir, Dir}, Dir=string() : Destination for generated files. Default is current working directory. {number, Number}, Number=int() : First chapter number when transforming a chapter file. Default is 1. {ptype, unix|windows} : For path elements, the specified file path should be presented. silent : Silent - no warnings, only error information is printed. {top, Index}, Index=string() : Specifies the value of "Top" in the left frame of a front page, which normally should be some kind of top index file for the documenta- tion. {vsn, Vsn}, Vsn=string() : Application version number. Overrides a version number defined in the XML document. Visible in the left frame and on the front page. {term_defs, File}, File=string() : Use the global glossary definitions in File , which should contain a list of tuples {Id, Name, Definition, Owner} . See the section <term>, <termdef> - Glossary in the User's Guide. {cite_defs, File}, File=string() : Use the global bibliography definitions in File , which should contain a list of tuples {Id, Title, Info, Owner} . See the section <cite>, <citedef> - Bibliography in the User's Guide. CALLBACK MODULE
A html_mod callback module can include the functions specified below. Note that there is no check that the resulting HTML code is valid. All functions are optional. EXPORTS
Module:head() -> string() Defines a HTML snippet to be included in the head of a document, after the <HEAD> start tag and <TITLE> tag: <HTML> <HEAD> <TITLE>...</TITLE> - snippet is included here - ... </HEAD> </HTML> Module:top() -> string() Defines a HTML snippet to be included at the top of a document, after the <BODY> start tag. Module:bottom() -> string() Defines a HTML snippet to be included at the bottom of a document, before the </BODY> end tag. Module:seealso(SeeAlso) -> Href Types SeeAlso = Href = string() When referring to another part of the document, or another document, the XML tag <seealso> is used: <seealso marker="File#Marker">...text...</seealso> . By default, this is translated to <A HREF="File.html#Marker>...text...</A> . This function makes it possible to specify an alternative translation Href of the marker attribute value SeeAlso . For example, in OTP this is used to resolve cross references between applications. Ericsson AB docbuilder 0.9.8.9 docb_transform(3erl)
All times are GMT -4. The time now is 11:37 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy