X-Git-Url: http://source.jalview.org/gitweb/?p=jalview.git;a=blobdiff_plain;f=help%2Fhelp%2Fhtml%2Ffeatures%2Fclarguments-argfiles.html;fp=help%2Fhelp%2Fhtml%2Ffeatures%2Fclarguments-argfiles.html;h=5c71d16ee8e707fff514f3e42f623ca764be79be;hp=0000000000000000000000000000000000000000;hb=f680b9a507cc1643c9eead990e15026c1eca4e6e;hpb=265e81c0b3599a09c312f17188e3a892e9d96c4e diff --git a/help/help/html/features/clarguments-argfiles.html b/help/help/html/features/clarguments-argfiles.html new file mode 100644 index 0000000..5c71d16 --- /dev/null +++ b/help/help/html/features/clarguments-argfiles.html @@ -0,0 +1,168 @@ + + +
+ Command Line: introduction
+
+ Command Line: basic usage
+
+ Command Line: advanced usage
+
+ Command Line: argument files
+
+ Command Line: reference
+
+ If you want to save a set of arguments to reuse, you can save them in a text file, say argfile.txt
, and read them into Jalview with
+
+ jalview --argfile=argfile.txt ++ + +
+ The argument file has one argument and value per line, still using the double-dash ('--') before the argument name, and separating the argument and value with an equals sign ('=').
+
+ Because the argument file is read by the application and not read by the shell, you do not need to escape any values -- all spaces will be read as part of the value until the end of the line.
+
+ You can add comments to a line by starting the line with an hash (octothorpe, pound-sign '#').
+
+ e.g.
+
+ File argfile.txt
+ |
+
+ +--nonews +--nosplash +--open=[nowrap,colour=gecos-flower,showannotations]examples/plantfdx.fa +--features=examples/plantfdx.features +--annotations=examples/plantfdx.annotations +--image=images/alignment.png +--scale=2.5 +#--scale=10 +# let's see what's happening +#--headless+ |
+
+ Because --argfiles
takes a filename argument, and multiple --argfiles
can be read on the command line, you can also use file globs to specify multiple --argfile
values. If you produce an argument file for each set of alignment files that you wish to associate then you can act on all of them with, e.g.
+
+ jalview --argfile=*/argfile.txt --headless ++ + +
+ You can even read argument files from within argument files, e.g. +
+ jalview --argfile=argfile*.txt --headless ++
File argfile1.txt |
+--open=file1.fa +--argfile=myfavouriteformattingargfile.txt +--argfile=mysecondfavouriteimageargfile.txt |
File myfavouriteformattingargfile.txt |
+--wrap +--showannotations +--annotations={dirname}/{basename}.annots |
File mysecondfavouriteimageargfile.txt |
+--image=images/{basename}.png +--width=1920 +--height=1080 |
+ If an argument file that has already been read is found in a firther argument file, then Jalview will exit with a warning. This is to avoid loops of argument files. +
+ + +
+ When you use an --argfile
argument, all other non-initialising arguments on the command line will be ignored. Only the initialising arguments and any and all --argfiles
arguments on the command line will be used. You can also set initialising arguments in argument files.
+
+ When adding values that can use substitutions within argument files, there are two additional substitutions that can be made:
+
+ {argfilebasename}
- replaced with the base of the filename of the argument file (i.e. without directory path or file extension).
+
+ {argfiledirname}
- replaced with the path to the filename of the argument file.
+
+ Another substitution you can make in argument files is the {n}
substitution. Combined with an -npp
increment at the start (or end) of the argument file gives the potential to reuse an argument files in the same command but referring to different files, e.g.
+
+
File alignment.argfile |
+--open={argfilebasename}-{n}.fa +--wrap +--output={basename}.stk +--close +--npp |
+ jalview --argfile alignment.argfile --argfile alignment.argfile --headless ++ would be processed the same as +
+ jalview --open=alignment-0.fa --wrap --output=alignment-0.stk --close --open=alignment-1.fa --wrap --output=alignment-1.stk --close --headless ++ + + +