Hacker News new | past | comments | ask | show | jobs | submit login

It seems like Python and Node are not good choices for command line tools. Rust or Go make a lot more sense as your end users won’t have to install any libs or package managers. Single binary distribution ftw.



Except you can bake apps into a single stand-alone binary executable for both Node.JS[1] and Python[2]

[1] https://www.npmjs.com/package/pkg [2] https://github.com/marcelotduarte/cx_Freeze


Can’t you just shebang a python script to make it feel like a normal executable?


Sure but you can't shebang all of the deps... Unless your `normal executable` embeds a Python dependency-manager.



You can do it with Node as well, this works: #!/usr/bin/env node

But similarly to with Python, it still requires you have the runtime installed along with any packages your thing depends on


If you zip a Python package with a __main__.py, it’s executable by the interpreter.



Rust has several interesting TUI libraries too.

Check https://github.com/fdehau/tui-rs for example.


As someone who really only knows Python (I'm not a developer), I was thinking the same thing. I think this would be really useful for me to use for some personal projects. Or for libraries for someone who already uses Python. I guess that's enough for it to be useful, but I wish I could package it up better to let someone who doesn't know a thing about Python use what I made.


It looks like a great library! Definitely useful for internal tools, personal scripts...

As a user I’m just encouraging people not to use an interpreted language to build tools you plan to distribute.


pip is installed by default on mac and linux. For non posix experienced users, pip installing packages is actually easier than figuring out how to put a binary on the path. Not to mention, updates are just a command, you dont have to go find the url, redownload, and replace the binary.


Realistically speaking people will most likely install cli tools with brew on mac. People shouldn’t be pip installing things without virtualenv anyway.


In that case it's irrelevant whether the thing is shipped as a normal python package, a static binary, or anything else, since it just comes from brew anyways.


Pip is not installed by default on macOS, and even python itself will be removed in some future version.


I thought macOS stopped shipping with python


For an internal app, you could give users restricted ssh access, less pain that giving them binaries.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: