Skip to content

Commit

Permalink
Ignore __pycache__ folder and hidden files (#435)
Browse files Browse the repository at this point in the history
  • Loading branch information
LuisGuillen03 authored Oct 17, 2024
1 parent d4542af commit 638106d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions python/hal9/targets/hal9.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,10 @@ def create_deployment(path :str) -> str:
def read_files(path :str, exclude :str = None):
files_dict = {}
for root, dirs, files in os.walk(path):
dirs[:] = [d for d in dirs if not d.startswith('.') and d != '__pycache__']
for file in files:
if exclude and file.startswith(exclude):
if file.startswith('.') or (exclude and file.startswith(exclude)):
continue

relative_path = os.path.relpath(os.path.join(root, file), path)
with open(os.path.join(root, file), 'rb') as f:
encoded_content = base64.b64encode(f.read()).decode('utf-8')
Expand Down
2 changes: 1 addition & 1 deletion python/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "hal9"
version = "2.7.9"
version = "2.7.10"
description = ""
authors = ["Javier Luraschi <[email protected]>"]
readme = "README.md"
Expand Down

0 comments on commit 638106d

Please sign in to comment.