Find the answer to your Linux question:
Results 1 to 4 of 4
Hello, I am learning linux embeded software. My computer was installed windows xp OS, so I install cygwin and GNU tool to debug my program. but I have to set ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    May 2008
    Posts
    1

    Question shell command to edit linux file in gnu/linux


    Hello,

    I am learning linux embeded software. My computer was installed windows xp OS, so I install cygwin and GNU tool to debug my program. but I have to set the path to the GNU tools location in the Cygwin bash. My question is what command i can use to open and edit the file ".bash_profile " ? I have tried many commands,such as, vi,less, more,pico....,etc, but they all didn't work.
    Thanks for your early answer !

    hdh_happy

  2. #2
    Just Joined!
    Join Date
    May 2008
    Posts
    3
    While installing Cygwin from the setup, you'll have option to install the Allefault or All:Install or All:Reinstall.
    By default Default is selected, change that to Install and try.

  3. #3
    Linux Guru
    Join Date
    Nov 2007
    Location
    Córdoba (Spain)
    Posts
    1,513
    Quote Originally Posted by hdh_happy View Post
    Hello,

    I am learning linux embeded software. My computer was installed windows xp OS, so I install cygwin and GNU tool to debug my program. but I have to set the path to the GNU tools location in the Cygwin bash. My question is what command i can use to open and edit the file ".bash_profile " ? I have tried many commands,such as, vi,less, more,pico....,etc, but they all didn't work.
    Thanks for your early answer !

    hdh_happy
    If you want vi you probably need to install it yourself.

    less and more are only visualizers, not editors. Just like cat.

    You can as well dump stuff into a given file by echoing it like this:

    Code:
    echo "whatever command" >> ~/.bash_profile

  4. #4
    Linux Newbie
    Join Date
    Apr 2007
    Posts
    214
    Outside the X window system, I like "editor" (editor file-to-be-edited.ext), I don't know if it comes by default in many distributions.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •