Ask coding questions

← Back to all posts
This Java swing project functioned when I first put it up. Now, it won't start.
NatKuhn (0)

When I try to start it, I get this message.

> bash -c xset q && DISPLAY=MAGIC run-project
q: xset: command not found
exit status 127

It looks like it used to run under Xwindows, but now it's not, maybe.

I get it that Swing is ancient, and it mostly sucked even when it wasn't, but replit is the only place I know where you can host such a thing on the web, so it would be lovely it if it worked.

(And even when it "worked," there were some significant issues... like, uh, the shift key would not work.)

You can find a verbose post about the project here, with a 20-second video at the bottom of what the program looks like when you run it on your own computer in Java.

Many thanks to anyone who can help!
Nat Kuhn

Answered by SixBeeps (5233) [earned 5 cycles]
View Answer
SixBeeps (5233)

They must've changed the way they handle windowing. On the default Swing Repl, the Run button just executes run-project, so try putting that in your .replit file's run command.

NatKuhn (0)

@SixBeeps Thank you so much, that is awesome. It now runs, and the shift key works now, as well! Thanks for the help, and the quick reply.