Skip to content

Commit

Permalink
add entry_points to recipe; always use \n line separator; version 0.2…
Browse files Browse the repository at this point in the history
….2 (#75)

* add entry_points to recipe; always use \n line separator; version 0.2.2
  • Loading branch information
dholth authored Nov 29, 2022
1 parent 8a43a39 commit 58fcdb0
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 deletions.
2 changes: 1 addition & 1 deletion conda_index/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
conda index. Create repodata.json for collections of conda packages.
"""

__version__ = "0.2.1"
__version__ = "0.2.2"
12 changes: 10 additions & 2 deletions conda_index/index/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -1169,12 +1169,20 @@ def _maybe_write_output_paths(
mode = "w"
encoding = "utf-8"
newline = "\n"
newline_option = "\n"
else:
mode = "wb"
encoding = None
newline = b"\n"

with open(output_temp_path, mode=mode, encoding=encoding) as fh:
newline_option = None

# always use \n line separator
with open(
output_temp_path,
mode=mode,
encoding=encoding,
newline=newline_option,
) as fh:
fh.write(content)
if write_newline_end:
fh.write(newline)
Expand Down
2 changes: 2 additions & 0 deletions recipe/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ build:
script: {{ PYTHON }} -m pip install --no-build-isolation . -vv
number: 0
noarch: python
entry_points:
- conda-index = conda_index.cli:cli

requirements:
host:
Expand Down

0 comments on commit 58fcdb0

Please sign in to comment.