Not able to run the program exit status 2

sh -c javac -classpath .:target/dependency/* -d . $(find . -type f -name '*.java')
error: invalid flag: ./Zeek
Usage: javac <options> <source files>
use --help for a list of possible options
exit status 2

Hi, @BhargavTumati!

Could we have a link to the Repl that is causing problems? It makes it much easier for the community to troubleshoot.

@BhargavTumati , welcome to the forums! Try forking the repl or type kill 1 into the Shell.

https://replit.com/@full-stack-bitlabs/Java-Beginner-BhargavTumati

Didn’t work by typing ‘kill it’
in shell

Its kill 1, not kill it.

Sry typo …kill 1 … But didn’t work

Hmm… try forking the repl.

I feel like this might have something to do with your .replit. However, your Repl link doesn’t seem to work.

The link belongs to teams …only team members can access…

1 Like

Is it possible you could copy the contents of .replit? It may be hidden automatically, so select the three dots and show hidden files.

1 Like

Yes, can be downloaded as zip file…

1 Like
compile = "javac -classpath .:target/dependency/* -d . $(find . -type f -name '*.java')"
run = "bash run_button.sh"

entrypoint = "Main.java"
hidden = ["**/*.class"]

[packager]
language = "java"

[packager.features]
packageSearch = true

[languages.java]
pattern = "**/*.java"

[languages.java.languageServer]
start = ["jdt-language-server"]

[unitTest]
language = "java"

[nix]
channel = "stable-21_11"

[debugger]
support = true

[debugger.compile]
command = "javac -classpath .:/run_dir/junit-4.12.jar:target/dependency/* -g -d . $(find . -type f -name '*.java')"

[debugger.interactive]
transport = "localhost:0"
connectTimeout = 60
startCommand = "java-debug"

[debugger.interactive.initializeMessage]
command = "initialize"
type = "request"

[debugger.interactive.initializeMessage.arguments]
adapterID = "cppdbg"
clientID = "replit"
clientName = "replit.com"
columnsStartAt1 = true
linesStartAt1 = true
locale = "en-us"
pathFormat = "path"
supportsInvalidatedEvent = true
supportsProgressReporting = true
supportsRunInTerminalRequest = true
supportsVariablePaging = true
supportsVariableType = true

[debugger.interactive.launchMessage]
command = "launch"
type = "request"

[debugger.interactive.launchMessage.arguments]
classPaths = ["."]
mainClass = "Main"

please copy the run_button.sh file

1 Like

um delete this cuz it has your login for github

2 Likes

@not-ethan please delete this as it contains very sensitive info.
@BhargavTumati please change your password on GitHub to invalidate this access token.

4 Likes

Please flag in the future so other mods and some Replit staff can see incase I’m not online

2 Likes

I always forget that flagging exists sorry :skull:

1 Like

the problem is due to ‘compile’ in .replit file.

compile = "javac -classpath .:target/dependency/* -d . $(find . -type f -name '*.java')"