mirror of
https://github.com/tinygo-org/tinygo.git
synced 2026-07-26 06:38:42 +00:00
WASI & darwin: support env variables based on libc
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io>
This commit is contained in:
committed by
Ron Evans
parent
c299386906
commit
9841ac4acd
Vendored
+14
@@ -0,0 +1,14 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"os"
|
||||
)
|
||||
|
||||
func main() {
|
||||
println(os.Getenv("ENV1"))
|
||||
v, ok := os.LookupEnv("ENV2")
|
||||
if !ok {
|
||||
panic("ENV2 not found")
|
||||
}
|
||||
println(v)
|
||||
}
|
||||
Vendored
+2
@@ -0,0 +1,2 @@
|
||||
VALUE1
|
||||
VALUE2
|
||||
Reference in New Issue
Block a user