Skip to content

Commit

Permalink
fix path handling
Browse files Browse the repository at this point in the history
  • Loading branch information
geritwagner committed Jul 7, 2022
1 parent 9f263f4 commit 038f3a5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion colrev_core/review_dataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -1703,7 +1703,7 @@ def check_propagated_IDs(self, *, prior_id: str, new_id: str) -> list:

text_formats = [".txt", ".csv", ".md", ".bib", ".yaml"]
notifications = []
for root, dirs, files in os.walk(os.getcwd(), topdown=False):
for root, dirs, files in os.walk(self.REVIEW_MANAGER.path, topdown=False):
for name in files:
if any((x in name) or (x in root) for x in ignore_patterns):
continue
Expand Down
4 changes: 2 additions & 2 deletions colrev_core/search.py
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,7 @@ def add_source(self, *, query: str) -> None:
i += 1
filename = filename[: filename.find("_query") + 6] + f"_{i}.bib"

feed_file_path = Path.cwd() / Path("search") / Path(filename)
feed_file_path = self.REVIEW_MANAGER.path / Path(filename)
assert not feed_file_path.is_file()

# The following must be in line with settings.py/SearchSource
Expand Down Expand Up @@ -348,7 +348,7 @@ def update(self, *, selection_str: str) -> None:
return

for feed_item in feed_sources:
feed_file = Path.cwd() / Path("search") / Path(feed_item.filename)
feed_file = self.REVIEW_MANAGER.path / Path(feed_item.filename)

if feed_item.source_name not in self.search_scripts:
print(
Expand Down

0 comments on commit 038f3a5

Please sign in to comment.