Skip to ContentSkip to Footer
Start of content
- Community Home
- >
- Servers and Operating Systems
- >
- Operating System - Linux
- >
- General
- >
- Adding a string
General
-
- Forums
-
- Advancing Life & Work
- Advantage EX
- Alliances
- Around the Storage Block
- HPE Ezmeral: Uncut
- OEM Solutions
- Servers & Systems: The Right Compute
- Tech Insights
- The Cloud Experience Everywhere
- HPE Blog, Austria, Germany & Switzerland
- Blog HPE, France
- HPE Blog, Italy
- HPE Blog, Japan
- HPE Blog, Middle East
- HPE Blog, Latin America
- HPE Blog, Russia
- HPE Blog, Saudi Arabia
- HPE Blog, South Africa
- HPE Blog, UK & Ireland
-
Blogs
- Advancing Life & Work
- Advantage EX
- Alliances
- Around the Storage Block
- HPE Blog, Latin America
- HPE Blog, Middle East
- HPE Blog, Saudi Arabia
- HPE Blog, South Africa
- HPE Blog, UK & Ireland
- HPE Ezmeral: Uncut
- OEM Solutions
- Servers & Systems: The Right Compute
- Tech Insights
- The Cloud Experience Everywhere
-
Information
- Community
- Welcome
- Getting Started
- FAQ
- Ranking Overview
- Rules of Participation
- Tips and Tricks
- Resources
- Announcements
- Email us
- Feedback
- Information Libraries
- Integrated Systems
- Networking
- Servers
- Storage
- Other HPE Sites
- Support Center
- Aruba Airheads Community
- Enterprise.nxt
- HPE Dev Community
- Cloud28+ Community
- Marketplace
-
Forums
-
Blogs
-
Information
-
English
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
10-07-2005 05:50 AM
10-07-2005 05:50 AM
Adding a string
Red Hat Enterprise Linux 3.0
I issue this line to append the text to the .bash_profile file.
echo "export ORACLE_DOC=$ORACLE_HOME/doc" >> .bash_profile
But if change the "$ORACLE_HOME" and put the value of this variable, which is nothing in the moment the command executes.
How can I add the text "$ORACLE_HOME" as simple string (not its value)?
I issue this line to append the text to the .bash_profile file.
echo "export ORACLE_DOC=$ORACLE_HOME/doc" >> .bash_profile
But if change the "$ORACLE_HOME" and put the value of this variable, which is nothing in the moment the command executes.
How can I add the text "$ORACLE_HOME" as simple string (not its value)?
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
10-07-2005 06:42 AM
10-07-2005 06:42 AM
Re: Adding a string
No that sure but see if this works...
echo export ORACLE_DOC="$ORACLE_HOME"/doc >> .bash_profile
Regards,
echo export ORACLE_DOC="$ORACLE_HOME"/doc >> .bash_profile
Regards,
You need to know a lot to actually know how little you know
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
10-07-2005 07:14 AM
10-07-2005 07:14 AM
Re: Adding a string
Use simple quotation:
echo 'export ORACLE_DOC=$ORACLE_HOME/doc' >> .bash_profile
echo 'export ORACLE_DOC=$ORACLE_HOME/doc' >> .bash_profile
Por que hacerlo dificil si es posible hacerlo facil? - Why do it the hard way, when you can do it the easy way?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
10-07-2005 11:03 PM
10-07-2005 11:03 PM
Re: Adding a string
try this
echo "export ORACLE_DOC=\$ORACLE_HOME/doc" >> .bash_profile
the backslash makes the $ sign a character instead of the shell variable descriptor.
Hope this helps
echo "export ORACLE_DOC=\$ORACLE_HOME/doc" >> .bash_profile
the backslash makes the $ sign a character instead of the shell variable descriptor.
Hope this helps
________________________________
UNIX because I majored in cryptology...
UNIX because I majored in cryptology...
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
End of content
United States
Hewlett Packard Enterprise International
Communities
- Communities
- HPE Blogs and Forum
© Copyright 2021 Hewlett Packard Enterprise Development LP