Skip to content
This repository has been archived by the owner on Jun 10, 2021. It is now read-only.

Windows Support #99

Open
calebmeyer opened this issue Mar 16, 2018 · 0 comments
Open

Windows Support #99

calebmeyer opened this issue Mar 16, 2018 · 0 comments

Comments

@calebmeyer
Copy link

I'm trying to use this package on windows. There's no mention of the dependency on curses and fcntl in the readme or in a requirements.txt/Pipfile.

I was able to get curses installed from here, but there's no fcntl on that page.

Here's the call I'm using that's asking for it:

$ codemod --extensions rb --count '(\s+)(get|delete|put)' ''
Traceback (most recent call last):
  File "C:\Users\CM022291\AppData\Local\Programs\Python\Python36\Scripts\codemod-script.py", line 11, in <module>
    load_entry_point('codemod==1.0.0', 'console_scripts', 'codemod')()
  File "C:\Users\CM022291\AppData\Local\Programs\Python\Python36\lib\site-packages\pkg_resources\__init__.py", line 565, in load_entry_point
    return get_distribution(dist).load_entry_point(group, name)
  File "C:\Users\CM022291\AppData\Local\Programs\Python\Python36\lib\site-packages\pkg_resources\__init__.py", line 2631, in load_entry_point
    return ep.load()
  File "C:\Users\CM022291\AppData\Local\Programs\Python\Python36\lib\site-packages\pkg_resources\__init__.py", line 2291, in load
    return self.resolve()
  File "C:\Users\CM022291\AppData\Local\Programs\Python\Python36\lib\site-packages\pkg_resources\__init__.py", line 2297, in resolve
    module = __import__(self.module_name, fromlist=['__name__'], level=0)
  File "C:\Users\CM022291\AppData\Local\Programs\Python\Python36\lib\site-packages\codemod-1.0.0-py3.6.egg\codemod\__init__.py", line 1, in <module>
    from codemod.base import *  # noqa
  File "C:\Users\CM022291\AppData\Local\Programs\Python\Python36\lib\site-packages\codemod-1.0.0-py3.6.egg\codemod\base.py", line 34, in <module>
    import codemod.terminal_helper as terminal
  File "C:\Users\CM022291\AppData\Local\Programs\Python\Python36\lib\site-packages\codemod-1.0.0-py3.6.egg\codemod\terminal_helper.py", line 11, in <module>
    import fcntl
ModuleNotFoundError: No module named 'fcntl'

Would it be possible to detect windows and use naive terminal handling in that case?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant