Skip to content

Commit 6b7ac85

Browse files
committed
Add -main-script to blog post
1 parent 093cc0e commit 6b7ac85

File tree

1 file changed

+14
-9
lines changed

1 file changed

+14
-9
lines changed

content/blog/2020/cli-docs-release.md

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ For most developers, the command line is synonymous with agility. While tools su
1212
And given Halloween is just around the corner, in this blog post we'll take a look at 5 CLI tricks and examples which will make your life easier in designing, executing and debugging data pipelines. We are also giving away 5 limited-edition Nextflow hoodies and sticker packs so you can code in style this Halloween season!
1313
1414
15-
#### 1: Invoke a remote pipeline execution with the latest revision
15+
### 1. Invoke a remote pipeline execution with the latest revision
1616
1717
Nextflow facilitates easy collaboration and re-use of existing pipelines in multiple ways. One of the simplest ways to do this is to use the URL of the Git repository.
1818
@@ -28,7 +28,7 @@ How can we make sure that we always run the latest code from the remote pipeline
2828
$ nextflow run nextflow-io/hello -latest
2929
```
3030
31-
#### 2: Query work directories for a specific execution
31+
### 2. Query work directories for a specific execution
3232
3333
For every invocation of Nextflow, all the metadata about an execution is stored including task directories, completion status and time etc. We can use the `nextflow log` command to generate a summary of this information for a specific run.
3434
@@ -49,7 +49,7 @@ The hash is the name of the work directory where the process was executed; there
4949
The log command also has other child options including `-before` and `-after` to help with the chronological inspection of logs.
5050
5151
52-
#### 3: Top-level configuration
52+
### 3. Top-level configuration
5353
5454
Nextflow emphasizes customization of pipelines and exposes multiple options to facilitate this. The configuration is applied to multiple Nextflow commands and is therefore a top-level option. In practice, this means specifying configuration options *before* the command.
5555
@@ -71,7 +71,7 @@ Moreover, we can also use the config command to inspect the final inferred confi
7171
$ nextflow config -show-profiles
7272
```
7373
74-
#### 4: Passing in an input parameter file
74+
### 4. Passing in an input parameter file
7575
7676
Nextflow is designed to work across both research and production settings. In production especially, specifying multiple parameters for the pipeline on the command line becomes cumbersome. In these cases, environment variables or config files are commonly used which contain all input files, options and metadata. Love them or hate them, YAML and JSON are the standard formats for human and machines, respectively.
7777
@@ -90,16 +90,21 @@ paired_end : true
9090
penalty : 12
9191
```
9292
93-
#### 5: Specific workflow entry points
93+
### 5. Specific workflow entry points
9494
9595
The recently released [DSL2](https://www.nextflow.io/blog/2020/dsl2-is-here.html) adds powerful modularity to Nextflow and enables scripts to contain multiple workflows. By default, the unnamed workflow is assumed to be the main entry point for the script, however, with numerous named workflows, the entry point can be customized by using the `entry` child-option of the run command.
9696
9797
$ nextflow run main.nf -entry workflow1
9898
9999
This allows users to run a specific sub-workflow or a section of their entire workflow script. For more information, refer to the [implicit workflow](https://www.nextflow.io/docs/latest/dsl2.html#implicit-workflow) section of the documentation.
100100
101+
Also, as for version 20.09.1-edge, you can specify a pipeline script other than `main.nf` using the command line option
102+
`-main-script`.
101103
102-
#### Bonus trick: Web dashboard launched from the CLI
104+
$ nextflow run http://github.com/my/pipeline -main-script my-analysis.nf
105+
106+
107+
### Bonus trick! Web dashboard launched from the CLI
103108
104109
The tricks above highlight the functionality of the Nextflow CLI. However, for long-running workflows, monitoring becomes all the more crucial. With Nextflow Tower, we can invoke any Nextflow pipeline execution from the CLI and use the integrated dashboard to follow the workflow execution wherever we are. Sign-in to [Tower](https://tower.nf) using your GitHub credentials, obtain your token from the Getting Started page and export them into your terminal, `~/.bashrc` or include them in your `nextflow.config`.
105110
@@ -114,17 +119,17 @@ Next simply add the "-with-tower" child-option to any Nextflow run command. A UR
114119
$ nextflow run nextflow-io/hello -with-tower
115120
```
116121
117-
#### Nextflow Giveaway
122+
### Nextflow Giveaway
118123
119124
If you want to look stylish while you put the above tips into practice, or simply like free stuff, we are giving away five of our latest Nextflow hoodie and sticker packs. Retweet or like the Nextflow tweet about this article and we will draw and notify the winners on October 31st!
120125
121126
122-
#### About the Author
127+
### About the Author
123128
124129
[Abhinav Sharma](https://www.linkedin.com/in/abhi18av/) is a Bioinformatics Engineer at [Seqera Labs](https://www.seqera.io) interested in Data Science and Cloud Engineering. He enjoys working on all things Genomics, Bioinformatics and Nextflow.
125130
126131
127-
#### Acknowledgements
132+
### Acknowledgements
128133
129134
Shout out to [Kevin Sayers](https://github.com/KevinSayers) and [Alexander Peltzer](https://github.com/apeltzer) for their earlier efforts in documenting the CLI and which inspired this work.
130135

0 commit comments

Comments
 (0)