[Swift-devel] Reading environment variables
Tim Armstrong
tim.g.armstrong at gmail.com
Sat Feb 23 15:10:39 CST 2013
FWIW we have this function in Swift/T
(string s) getenv(string key)
On Sat, Feb 23, 2013 at 2:15 PM, David Kelly <davidk at ci.uchicago.edu> wrote:
> Is there a function available for reading environment variables within a
> swift script? I didn't see one mentioned in the userguide, but this seems
> to work for me:
>
> string home=@java("java.lang.System", "getenv", "HOME");
>
> Should we have a function for this? @env("HOME")?
>
>
> _______________________________________________
> Swift-devel mailing list
> Swift-devel at ci.uchicago.edu
> https://lists.ci.uchicago.edu/cgi-bin/mailman/listinfo/swift-devel
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/swift-devel/attachments/20130223/82126301/attachment.html>
More information about the Swift-devel
mailing list