How to set envrionment variables in cygwin

Posted on 2006-04-05
Last Modified: 2013-12-27
I need that everytime I open cygwin the followin should be set:
set ROOT=/directory1/direcotry 2

Where can I do this? I dont want to type this each time.
Question by:rohgan

    Author Comment

    I have installed cygwin on XP
    LVL 61

    Expert Comment

    On normal UNIX that is done using .profile file in your home directory
    If that does not work - System Properties/Environment ...
    LVL 51

    Accepted Solution

    see in cgwin's home/user directory, there is a .profile, if not create it

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    How your wiki can always stay up-to-date

    Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
    - Increase transparency
    - Onboard new hires faster
    - Access from mobile/offline

    Suggested Solutions

    Attention: This article will no longer be maintained. If you have any questions, please feel free to mail me. Please see for the updated article. It is avail…
    My previous tech tip, Installing the Solaris OS From the Flash Archive On a Tape (, discussed installing the Solaris Operating S…
    Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
    Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:

    760 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    7 Experts available now in Live!

    Get 1:1 Help Now