Open HananxR opened 10 months ago
It looks like you’re using Unix glob syntax with Windows? I don’t have windows, so I’m not sure if that’s expected to work.
Windows does not do shell expansion in the same way that sh does, it expects the program to do the shell expansion.
The best way to handle this input would be to use glob (either from pathlib.Path or glob) to expand the sources before using them.
As a workaround (in powershell), you could run this to expand the glob before passing it to pycco.
pycco -p (maths/*.py | Resolve-Path -Relative)
Or if you wanted to do something like myproject/*/.py, you could do it like this:
pycco -p (Get-ChildItem -Recurse -Path myproject -File -Filter *.py | Resolve-Path -Relative)
run:
pycco files/*.py -p
result error:
OSError: [Errno 22] Invalid argument: 'docs\\maths\\*.html'
The detailed operation logs are as follows:
But I run
pycco maths/add.py
,it's ok. so What is the reason for this?maths
structure is as follows:python version:
3.8.5
operating system:win11