Home > Community > Forums > Custom IC Design > ADEXL switch default ocean script editor

Email

* Required Fields

Recipients email * (separate multiple addresses with commas)

Your name *

Your email *

Message *

Contact Us

* Required Fields
First Name *

Last Name *

Email *

Company / Institution *

Comments: *

 ADEXL switch default ocean script editor 

Last post Mon, Nov 26 2012 5:14 AM by Tobben24. 7 replies.
Started by Tobben24 26 Nov 2012 03:17 AM. Topic has 7 replies and 1454 views
Page 1 of 1 (8 items)
Sort Posts:
  • Mon, Nov 26 2012 3:17 AM

    • Tobben24
    • Top 500 Contributor
    • Joined on Mon, Nov 26 2012
    • Posts 32
    • Points 535
    ADEXL switch default ocean script editor Reply

    Hi,

    When I want to edit an oscean script in ADEXL Setup tab(E button), the script is opened in emacs. How can I change this to another program, ie. vim?

    Filed under: , ,
    • Post Points: 20
  • Mon, Nov 26 2012 3:55 AM

    Re: ADEXL switch default ocean script editor Reply

    There is a SKILL variable called editor which is seeded from the UNIX environment variable $EDITOR which sets the editor used.

    Check in the CIW what the value of editor is. Then you can do

    editor="nedit"

    for example. This could go in your .cdsinit.

    Something must be setting either $EDITOR or editor, because emacs is not the default... (vi is - because it is guaranteed to be there, whether you like it or not - I don't want to start an editor war!)

    Regards,

    Andrew.

    • Post Points: 35
  • Mon, Nov 26 2012 3:58 AM

    • Tobben24
    • Top 500 Contributor
    • Joined on Mon, Nov 26 2012
    • Posts 32
    • Points 535
    Re: ADEXL switch default ocean script editor Reply
    Perfect! Thanks for the quick reply:)
    • Post Points: 5
  • Mon, Nov 26 2012 4:16 AM

    • Tobben24
    • Top 500 Contributor
    • Joined on Mon, Nov 26 2012
    • Posts 32
    • Points 535
    Re: ADEXL switch default ocean script editor Reply
    So tried to edit the .cdsinit file, but I found out that this one is shared by many users so I cannot edit this one. Is the some local file I can edit/create which also is read by candence at startup where is can set this editor variable?
    • Post Points: 20
  • Mon, Nov 26 2012 4:21 AM

    Re: ADEXL switch default ocean script editor Reply

    Is $EDITOR set up in your UNIX environment - i.e. is that what is causing it to be set? If so, maybe you can set that environment variable in your personal .cshrc/.login or .bashrc - whichever shell you're using.

    Most companies have something set up in their central .cdsinit file to look for local customization files too, typically in your working directory or home directory. The default behaviour is that virtuoso looks first in the installation in <ICinstDir>/tools/dfII/local, then in working dir, then in home dir. The first that is found is loaded. Alternatively it can use the Cadence Search File mechanism (sometimes known as setup.loc - search in the documentation for more details). However, in all cases, it loads just the first found - and you have to add code into the .cdsinit to look for local files if you want additional places to look.

    So your central file could have:

    when(isFile("~/.cdsinit")
      loadi("~/.cdsinit")
    )

    or similar to look for a personal .cdsinit file.

    Andrew.

    • Post Points: 20
  • Mon, Nov 26 2012 4:36 AM

    • Tobben24
    • Top 500 Contributor
    • Joined on Mon, Nov 26 2012
    • Posts 32
    • Points 535
    Re: ADEXL switch default ocean script editor Reply

    Ok. Added it in .cshrc, and now the editor variable is changed. However, my preferred edit is vim and this editor is runned "inside" a terminal. ADEXL(or vim) gives me a warning when trying to edit a file:

    *WARNING* editFile: Vim: Warning: Output is not to a terminal

    • Post Points: 20
  • Mon, Nov 26 2012 4:59 AM

    Re: ADEXL switch default ocean script editor Reply

    There is some default handling of EDITOR being "vi" - it transforms that automatically to do "xterm -e vi". That doesn't happen if EDITOR is set to "vim" though. So you either need to set EDITOR to "xterm -e vim" or "gvim" (if you have that available) - that is vim in a standalone window.

    Virtuoso doesn't really have any way of knowing whether your editor works in a standalone window (such as emacs, nedit, gvim, gedit), or runs in a terminal (vi, vim, ex, nano etc). So you have to tell it - we just have a default mapping built in to handle EDITOR/editor being "vi".

    Regards,

    Andrew.

    • Post Points: 20
  • Mon, Nov 26 2012 5:14 AM

    • Tobben24
    • Top 500 Contributor
    • Joined on Mon, Nov 26 2012
    • Posts 32
    • Points 535
    Re: ADEXL switch default ocean script editor Reply
    By setting editor to "vi" worked, but I lost some of important features, mouse functionallity amongs others. But entering "xterm -e vim" it worked. Thank you!:)
    • Post Points: 5
Page 1 of 1 (8 items)
Sort Posts:
Started by Tobben24 at 26 Nov 2012 03:17 AM. Topic has 7 replies.