# Easiest way to access nextflow run command from within the pipeline?

**URL:** <https://community.seqera.io/t/easiest-way-to-access-nextflow-run-command-from-within-the-pipeline/1544>\
**Category:** Ask for help\
**Created:** [December 12, 2024, 4:22pm UTC](https://community.seqera.io/t/easiest-way-to-access-nextflow-run-command-from-within-the-pipeline/1544 "2024-12-12T16:22:53Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Isaiah\_Taylor](https://dub1.discourse-cdn.com/flex013/user_avatar/community.seqera.io/isaiah_taylor/32/1106_2.png) [@Isaiah\_Taylor](https://community.seqera.io/u/Isaiah_Taylor)\
**Post date:** [December 12, 2024, 4:22pm UTC](https://community.seqera.io/t/easiest-way-to-access-nextflow-run-command-from-within-the-pipeline/1544/1 "2024-12-12T16:22:53Z")

</div>

For logging purposes I would like to access the command used to kick off the pipeline. I know it’s in nextflow.log. Wondering if it is more directly accessible from within the pipeline?

---

<div class="post-metadata">

**Author:** ![mahesh.binzerpanchal](https://dub1.discourse-cdn.com/flex013/user_avatar/community.seqera.io/mahesh.binzerpanchal/32/253_2.png) [@mahesh.binzerpanchal](https://community.seqera.io/u/mahesh.binzerpanchal)\
**Post date:** [December 12, 2024, 7:53pm UTC](https://community.seqera.io/t/easiest-way-to-access-nextflow-run-command-from-within-the-pipeline/1544/2 "2024-12-12T19:53:54Z")

</div>

You’re looking for the variable `workflow.commandLine`.  
[https://www.nextflow.io/docs/latest/reference/stdlib.html#constants](https://www.nextflow.io/docs/latest/reference/stdlib.html#constants)

---

<div class="post-metadata">

**Author:** ![Isaiah\_Taylor](https://dub1.discourse-cdn.com/flex013/user_avatar/community.seqera.io/isaiah_taylor/32/1106_2.png) [@Isaiah\_Taylor](https://community.seqera.io/u/Isaiah_Taylor)\
**Post date:** [December 23, 2024, 10:44pm UTC](https://community.seqera.io/t/easiest-way-to-access-nextflow-run-command-from-within-the-pipeline/1544/3 "2024-12-23T22:44:06Z")

</div>

Great, those are incredibly useful to know about!

---

<div class="post-metadata">

**Author:** ![system](https://dub1.discourse-cdn.com/flex013/user_avatar/community.seqera.io/system/32/2402_2.png) [@system](https://community.seqera.io/u/system)\
**Post date:** [December 30, 2024, 10:44pm UTC](https://community.seqera.io/t/easiest-way-to-access-nextflow-run-command-from-within-the-pipeline/1544/4 "2024-12-30T22:44:44Z")

</div>

Closed on December 30, 2024, 10:44pm UTC

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.
