Skip to content

Commit

Permalink
Merge pull request nf-core#2625 from mashehu/handle-stageAs
Browse files Browse the repository at this point in the history
handle stageAs in input parsing correctly
  • Loading branch information
mashehu authored Jan 4, 2024
2 parents d91a3bf + 9587aab commit 1cd6bb6
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions nf_core/components/nfcore_component.py
Original file line number Diff line number Diff line change
Expand Up @@ -170,9 +170,11 @@ def get_inputs_from_main_nf(self):
matches = re.finditer(regex, input_data, re.MULTILINE)
for _, match in enumerate(matches, start=1):
if match.group(3):
inputs.append(match.group(3))
input_val = match.group(3).split(",")[0] # handle `files, stageAs: "inputs/*"` cases
inputs.append(input_val)
elif match.group(4):
inputs.append(match.group(4))
input_val = match.group(4).split(",")[0] # handle `files, stageAs: "inputs/*"` cases
inputs.append(input_val)
log.info(f"Found {len(inputs)} inputs in {self.main_nf}")
self.inputs = inputs

Expand Down

0 comments on commit 1cd6bb6

Please sign in to comment.