Unable to open file, while using the source function


I got the error while using source function like this? Does any one know what I'm doing wrong?

BTW, I'm sure that the gdsii exist in the same location with the drc script - test.lydrc
Thanks.
Man

Comments

  • edited April 2020

    Hi Man,

    File paths are not automatically resolved relative to the DRC script's path but relative to the current directory. At least not now (but good suggestion).

    To make a file being read relative to your DRC script, use Ruby's __FILE__ constant which represents the path of the currently executed script:

    source(File.join(File.dirname(__FILE__), "test.gds")
    

    Matthias

Sign In or Register to comment.