nf-core / nf-core/tools

nf-core sync silently deletes ignored files

Open
#2,146 2 comments 0 reactions 0 assignees View on GitHub

A pull request for this has already been merged.

  • #3847 by @tgelafr-pfzr — merged
bug
Dominant language
Python
Stars
322
Forks
255
Avg merge
2d 3h
Merged PRs (30d)
5

Description

Description of the bug

This may not be the biggest issue, but I recently found that running nf-core sync causes ignored files to be deleted.
This is a particular nuisance as it deletes editor config files such as .vscode/.

Currently the delete is performed using a simple iteration over the files in the directory, skipping the .git folder.
It could be possible to leverage the git.Repo object to skip ignored/untracked files too.

Command used and terminal output

No response

System information

nf-core tools 2.7.2

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

The issue points to the nf-core sync deletion iteration and suggests using the git.Repo object; start by reproducing nf-core sync with an ignored .vscode/ file and inspect that deletion path. Done means ignored and untracked files are retained while intended files still sync; check the linked pull request context before starting.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
cli, tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.