Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Compiling and testing cross-platform software for Linux lately (Ubuntu and similar)... You can't even launch an application or script without CLI. Bad UX, IMO. For these decisions, There are always reasons, a justification, something about security. I don't buy it.


> You can't even launch an application or script without CLI.

Care to elaborate? I'm not sure I understand what you're saying here.


I compile my program using WSL, or Linux native. It won't launch; not an executable. So, into the CLI: chmod +x. Ok. It's a compiled binary program, so semantically I don't see the purpose of this. Probably another use case bleeding into this. (I think there's a GUI way too). Still can't double click it. Nothing to launch from the right-click menu. After doing some research, it appears you used to be able to do it (Ubuntu/Gnome[?]), but it was removed at some point. Can launch from CLI.

I make a .desktop file and shell script to move it to the right place. Double click the shell file. It opens a text editor. Search the right click menu; still no way. To the CLI we go; chmod +x, and launch if from the CLI. Then after adding the Desktop icon, I can launch it.

On windows, you just double click the identified-through-file-extension executable file. This, like most things in Linux, implies the UX is designed for workflows I don't use as a PC user. Likely servers?


This sounds very weird to me. Any sane build toolchain should produce a runnable executable that already has +x. What did you use to compile it?

Removing double-click to run an executable binary certainly sounds like something either Gnome or Ubuntu would do, but thankfully that's not the only option in town. In KDE I believe the same exact Windows workflow would just work.


>Any sane build toolchain should produce a runnable executable that already has +x. What did you use to compile it?`

`cargo build --release`

Good to know KDE doesn't do that!


Even stranger then. Just to make sure I'm not missing something, I just tried this on my Mac:

  $ cargo --version
  cargo 1.86.0

  $ cargo new hello-rs
     Creating binary (application) `hello-rs` package

  $ cd hello-rs && cargo build --release
     Compiling hello-rs v0.1.0 (/Users/int19h/src/hello-rs)
      Finished `release` profile [optimized] target(s) in 0.73s

  $ ls -la target/release/hello-rs
  -rwxr-xr-x@ 1 int19h  staff  468608 May 20 20:16 target/release/hello-rs*

  $ ./target/release/hello-rs
  Hello, world!
Are you sure it's not because the package in question does some kind of weird custom build steps?


Might have got lost in translation when I moved it from WSL to a windows-made zip file. I think that workflow nukes permissions.


Yeah the typical way programs are run is by using a .desktop file that's installed. The reason nobody cares is because running random executable that have a GUI is a pretty rare use case for Linux desktops. We don't have wizards or .msi installers, we just install using the package manager. And then it shows up where it needs to.

If you're on KDE, you can right-click the start menu and add the application. Also, right-click menu should give you a run option.




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

Search: