Skip to content

Commit

Permalink
[script] Allow user to specify local ELF
Browse files Browse the repository at this point in the history
Signed-off-by: Avimitin <[email protected]>
  • Loading branch information
Avimitin authored and sequencer committed Nov 18, 2024
1 parent fb6ecc7 commit 4c7a2d2
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions script/emu/src/Main.scala
Original file line number Diff line number Diff line change
Expand Up @@ -105,10 +105,6 @@ object Main:
userPath
end prepareOutputDir

// naive case validation
def isValidCaseName(caseName: String): Boolean =
caseName.split("\\.").toSeq.length == 2

def tryRestoreFromCache(key: String, value: Option[String]): Option[String] =
val xdgDir = sys.env.get("XDG_CACHE_HOME")
val homeDir = sys.env.get("HOME")
Expand Down Expand Up @@ -181,7 +177,6 @@ object Main:
): Unit =
if leftOver.value.isEmpty then Logger.fatal("No test case name")
val caseName = leftOver.value.head
if !isValidCaseName(caseName) then Logger.fatal(s"invalid caseName '$caseName', expect 'A.B'")

val finalIp = tryRestoreFromCache("ip", ip)
if finalIp.isEmpty then
Expand Down

0 comments on commit 4c7a2d2

Please sign in to comment.